Closed ito1202 closed 6 years ago
I attempted to run python demo.py --dataroot ./facades/nat_new4 --valDataroot ./facades/nat_new4 --netG ./demo_model/netG_epoch_8.pth but error.
python demo.py --dataroot ./facades/nat_new4 --valDataroot ./facades/nat_new4 --netG ./demo_model/netG_epoch_8.pth
Error message is
Traceback (most recent call last): File "demo.py", line 128, in <module> netG = net.dehaze(inputChannelSize, outputChannelSize, ngf) File "/home/ito/src/DCPDN/dehaze22.py", line 537, in __init__ self.tran_est=G(input_nc=3,output_nc=3, nf=64) File "/home/ito/src/DCPDN/dehaze22.py", line 88, in __init__ layer2 = blockUNet(nf, nf*2, name, transposed=False, bn=True, relu=False, dropout=False) File "/home/ito/src/DCPDN/dehaze22.py", line 56, in blockUNet block.add_module('%s.leakyrelu' % name, nn.LeakyReLU(0.2, inplace=True)) File "/home/ito/virtualenv/pytorch/local/lib/python2.7/site-packages/torch/nn/modules/module.py", line 169, in add_module raise KeyError("module name can't contain \".\""). KeyError: 'module name can\'t contain "."'
My torch version is 0.4.0 , and torchvisiion version is 0.2.1.
I think, after version 0.2.1 '.'s are no longer allowed in module keys. Please tell me your torchvision version.
I'm sorry, I solved it. I install torch version 0.3.0 and torchvision version0.2.1.
from where can i install torch version 0.3.0?
I attempted to run
python demo.py --dataroot ./facades/nat_new4 --valDataroot ./facades/nat_new4 --netG ./demo_model/netG_epoch_8.pth
but error.Error message is
Traceback (most recent call last): File "demo.py", line 128, in <module> netG = net.dehaze(inputChannelSize, outputChannelSize, ngf) File "/home/ito/src/DCPDN/dehaze22.py", line 537, in __init__ self.tran_est=G(input_nc=3,output_nc=3, nf=64) File "/home/ito/src/DCPDN/dehaze22.py", line 88, in __init__ layer2 = blockUNet(nf, nf*2, name, transposed=False, bn=True, relu=False, dropout=False) File "/home/ito/src/DCPDN/dehaze22.py", line 56, in blockUNet block.add_module('%s.leakyrelu' % name, nn.LeakyReLU(0.2, inplace=True)) File "/home/ito/virtualenv/pytorch/local/lib/python2.7/site-packages/torch/nn/modules/module.py", line 169, in add_module raise KeyError("module name can't contain \".\""). KeyError: 'module name can\'t contain "."'
My torch version is 0.4.0 , and torchvisiion version is 0.2.1.
I think, after version 0.2.1 '.'s are no longer allowed in module keys. Please tell me your torchvision version.