Closed eformx closed 1 year ago
OK, you need to modify two places.
1- Change config.py
31 line upscale_factor = 4
to upscale_factor = 2
2- Change model.py
139 line for _ in range(2):
to for _ in range(1):
So, inferernce.py
should use X4 model weights, if you use X2 model weights, maybe it is bad~
I'm talking about the case of using the pretrained model directly ^.^
Tried your suggestion but get: RuntimeError: Error(s) in loading state_dict for Generator: Unexpected key(s) in state_dict: "upsampling.1.upsample_block.0.weight", "upsampling.1.upsample_block.0.bias", "upsampling.1.upsample_block.2.weight".
I am using: model_path = "/results/pretrained_models/SRResNet_x4-ImageNet-2096ee7f.pth.tar"
This library gives X4 times the model, which cannot be directly used for X2 inference, you can try to load some model weights
Will this work or is there a better one: Discriminator_x2-DFO2K-e37ff529.pth.tar
I changed upscale_factor = 2 in config.py I run inferernce.py and results are upscaled by 4. How can I pass in an upscale_factor of 2 in inference.py?