AttributeError: 'ResNet' object has no attribute 'module'
See original GitHub issueHi,
Could you please help with the following issue? I am trying to train a CSV dataset using a single GPU with the following packages versions:
- Python = 3.6.0
- Pytorch = 1.2.0
I had some previous error messages that I overcame by passing the environment variable CUDA_VISIBLE_DEVICES=0, I have 2 GPU but aren’t the same generation, and comment out the line retinanet = torch.nn.DataParallel(retinanet).cuda()
.
The error that I am getting now is:
File "/home/User/miniconda3/envs/pytorch-retinanet/lib/python3.6/site-packages/torch/nn/modules/module.py", line 591, in __getattr__ type(self).__name__, name)) AttributeError: 'ResNet' object has no attribute 'module'
Issue Analytics
- State:
- Created 4 years ago
- Comments:8 (4 by maintainers)
Top Results From Across the Web
AttributeError: 'ResNet' object has no attribute 'module' · Issue #1
When I run python HHL.py -s duke -t market --logs-dir logs/duke2market-HHL, It occurs an error: Traceback (most recent call last):
Read more >ResNet object has no attribute 'predict' - Stack Overflow
TLDR: I get an error called ModuleAttributeError that says the 'ResNet' module has no attribute 'predict'.
Read more >AttributeError: 'ResNet' object has no attribute 'get_features'
Hello i defined a method inside a class but i don't know why i'm getting the following error AttributeError: 'ResNet' object has no...
Read more >A brand new website interface for an even better experience!
Getting error "AttributeError: 'module' object has no attribute 'distribute'" when running resnet model in official folder.
Read more >Transfer Learning tutorial - Bikash Santra
In the following, parameter scheduler is an LR scheduler object from ... name, value): AttributeError: 'ResNet' object has no attribute 'to'.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
If you don’t use
retinanet = torch.nn.DataParallel(retinanet).cuda()
you should writeretinanet.freeze_bn()
instead ofretinanet.module.freeze_bn()
. Thus to solve all the issues, make sure that all your call with retinanet don’t usemodule
. There is another.module
that you have to remove in thecsv_eval
file as far as i rememberAny help for this ? facing same issue