zhanghang1989 / ResNeSt

ResNeSt: Split-Attention Networks
https://arxiv.org/abs/2004.08955
Apache License 2.0
3.22k stars 494 forks source link

hub.list and .load functionality lost #141

Closed Zyarra closed 3 years ago

Zyarra commented 3 years ago

Hey! Since a few days I can't load the models from torchhub. Seems like you have from resnest.torch.resnest import resnest50 instead of from resnest.torch import resnest50 in the hubconf.py

import torch
torch.hub.list('zhanghang1989/ResNeSt', force_reload=True)

Downloading: "https://github.com/zhanghang1989/ResNeSt/archive/master.zip" to .../.cache\torch\hub\master.zip

AttributeError: module 'readline' has no attribute 'redisplay'

net = torch.hub.load('zhanghang1989/ResNeSt', 'resnest50', pretrained=True)

File ".../.cache\torch\hub\zhanghang1989_ResNeSt_master\hubconf.py", line 3, in from resnest.torch.resnest import resnest50, resnest101, resnest200, resnest269 ModuleNotFoundError: No module named 'resnest.torch.resnest'

The python package still works.

from resnest.torch import resnest50
net = resnest50(pretrained=True)