Closed tanmay2298 closed 4 years ago
It is because of the URL dictionary. You have used r16f256x2
but there is no entry with such name in URL dictionary. Check the initial lines of edsr.py
Either change --n_resblocks to 32
or comment out the URL section in the code so that it could avoid it.
Hi,
I'm unable to vary the residual blocks.
Here is the command I tested in demo.sh file
python main.py --model EDSR --scale 2 --save edsr_x2 --n_resblocks 16 --n_feats 256 --res_scale 0.1 --reset --ext sep --batch_size 16 --epoch 600 --patch_size 96 --n_GPUs 2 --chop --optimizer ADAM
The output was as follows -
File "main.py", line 33, in <module> main() File "main.py", line 23, in main _model = model.Model(args, checkpoint) File "/home/t2gulati/Super-Resolution-using-Deep-Learning/Code/EDSR/EDSR-PyTorch/src/model/__init__.py", line 26, in __init__ self.model = module.make_model(args).to(self.device) File "/home/t2gulati/Super-Resolution-using-Deep-Learning/Code/EDSR/EDSR-PyTorch/src/model/edsr.py", line 15, in make_model return EDSR(args) File "/home/t2gulati/Super-Resolution-using-Deep-Learning/Code/EDSR/EDSR-PyTorch/src/model/edsr.py", line 26, in __init__ self.url = url['r{}f{}x{}'.format(n_resblocks, n_feats, scale)] KeyError: 'r16f256x2'
Please let me know how I should I go about resolving this
Thank you!