facebookresearch / pycls

Codebase for Image Classification Research, written in PyTorch.
MIT License
2.14k stars 237 forks source link

AttributeError: module 'pycls.core' has no attribute 'builders' #127

Open varunnrao opened 3 years ago

varunnrao commented 3 years ago

Traceback (most recent call last):
  File "tools/train_net.py", line 12, in <module>
    import pycls.core.trainer as trainer
  File "/pycls/pycls/core/trainer.py", line 11, in <module>
    import pycls.core.builders as builders
  File "/pycls/pycls/core/builders.py", line 12, in <module>
    from pycls.models.anynet import AnyNet
  File "/pycls/pycls/models/__init__.py", line 10, in <module>
    from pycls.models.model_zoo import effnet, regnetx, regnety, resnet, resnext
  File "/pycls/pycls/models/model_zoo.py", line 12, in <module>
    import pycls.core.builders as builders
AttributeError: module 'pycls.core' has no attribute 'builders'```

Is there something wrong with the directory structure I'm executing from?
leonxu1 commented 3 years ago

113 suggests commenting out the import in /pycls/pycls/models/__init__.py.

Frag17 commented 2 years ago

try import pycls.core.builders not using “as“ you will find no problem and I don't know why.