greatlog / UnpairedSR

This is an offical implementation of the CVPR2022's paper [Learning the Degradation Distribution for Blind Image Super-Resolution](https://arxiv.org/abs/2203.04962)
165 stars 12 forks source link

KeyError: 'netDeg' #8

Closed ZYQii closed 2 years ago

ZYQii commented 2 years ago

作者您好,我在运行Start up里的“python3 inference.py --opt options/test/2020Track2.yml”代码行时,遇到报错: export CUDA_VISIBLE_DEVICES=0 0it [00:00, ?it/s] Traceback (most recent call last): File "inference.py", line 57, in model.test({"src": img_t}, crop_size=512) File "/home/bobo/home/bobo/F/z/UnpairedSR/codes/config/PDM-SR/models/deg_sr_model.py", line 264, in test self.set_network_state(["netDeg", "netSR"], "eval") File "/home/bobo/home/bobo/F/z/UnpairedSR/codes/config/PDM-SR/models/base_model.py", line 184, in set_network_state if isinstance(self.networks[name], nn.Module): KeyError: 'netDeg' 请问如何解决?谢谢

greatlog commented 2 years ago

可更新代码后重试。

qiqi450 commented 2 years ago

作者您好,我在运行Start up里的“python3 inference.py --opt options/test/2020Track2.yml”代码行时,遇到报错: export CUDA_VISIBLE_DEVICES=0 0it [00:00, ?it/s] Traceback (most recent call last): File "inference.py", line 57, in model.test({"src": img_t}, crop_size=512) File "/home/bobo/home/bobo/F/z/UnpairedSR/codes/config/PDM-SR/models/deg_sr_model.py", line 264, in test self.set_network_state(["netDeg", "netSR"], "eval") File "/home/bobo/home/bobo/F/z/UnpairedSR/codes/config/PDM-SR/models/base_model.py", line 184, in set_network_state if isinstance(self.networks[name], nn.Module): KeyError: 'netDeg' 请问如何解决?谢谢

你好,请问解决了吗,我也遇到了同样的问题