Closed holyYodu closed 4 years ago
hello! I meet the same problem. so how do you solve it?
hello! I meet the same problem. so how do you solve it?
replace "inplanes" with "in_planes" in "class ResNeXtBottleneck(Bottleneck):" from models/resnext.py
thanks, i try that, and it was killed by system. Maybe out of memory.
File "main.py", line 431, in
main_worker(-1, opt)
File "main.py", line 337, in main_worker
model = generate_model(opt)
File "/home/mhy/Documents/3D-ResNets-PyTorch/model.py", line 76, in generate_model
no_max_pool=opt.no_max_pool)
File "/home/mhy/Documents/3D-ResNets-PyTorch/models/resnext.py", line 67, in generate_model
**kwargs)
File "/home/mhy/Documents/3D-ResNets-PyTorch/models/resnext.py", line 54, in init
shortcut_type, n_classes)
File "/home/mhy/Documents/3D-ResNets-PyTorch/models/resnet.py", line 132, in init
shortcut_type)
File "/home/mhy/Documents/3D-ResNets-PyTorch/models/resnet.py", line 189, in _make_layer
downsample=downsample))
TypeError: init() got an unexpected keyword argument 'in_planes'
when build the resnext model , the block in super().init() is 'ResNeXtBottleneck' while in resnet.py make_layer code is
the
in_planes
is a wrong argument for ResNeXtBottleneck