EfficientUnet-PyTorch
EfficientUnet-PyTorch copied to clipboard
cannot import name 'load_state_dict_from_url'
requires pytorch >1.0.0, my version is 1.0.1, i found v1.0.1 not support 'load_state_dict_from_url' but >=1.1.0
Just FYI, I applied work-around with local change borrowing: https://github.com/pytorch/vision/blob/master/torchvision/models/utils.py
try:
from torch.hub import load_state_dict_from_url
except ImportError:
from torch.utils.model_zoo import load_url as load_state_dict_from_url
(Just dunno if applying this change is better or not in the future, I'm making local change.)
Just FYI, I applied work-around with local change borrowing: https://github.com/pytorch/vision/blob/master/torchvision/models/utils.py
try: from torch.hub import load_state_dict_from_url except ImportError: from torch.utils.model_zoo import load_url as load_state_dict_from_url
(Just dunno if applying this change is better or not in the future, I'm making local change.)
great ! it works
Just FYI, I applied work-around with local change borrowing: https://github.com/pytorch/vision/blob/master/torchvision/models/utils.py
try: from torch.hub import load_state_dict_from_url except ImportError: from torch.utils.model_zoo import load_url as load_state_dict_from_url
(Just dunno if applying this change is better or not in the future, I'm making local change.)
Worked perfectly.
Just FYI, I applied work-around with local change borrowing: https://github.com/pytorch/vision/blob/master/torchvision/models/utils.py
try: from torch.hub import load_state_dict_from_url except ImportError: from torch.utils.model_zoo import load_url as load_state_dict_from_url
(Just dunno if applying this change is better or not in the future, I'm making local change.)
Solved perfectly! thanks!