Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

key error #1

Open
yjg123456 opened this issue Jul 5, 2021 · 1 comment
Open

key error #1

yjg123456 opened this issue Jul 5, 2021 · 1 comment

Comments

@yjg123456
Copy link

作者 你好 ,我在运行程序时出现了一下错误
Traceback (most recent call last):
File "main.py", line 21, in
solver.run()
File "/home/gfzx/yjg/image_enhance_Algorithm/MIP-main/solver/solver.py", line 142, in run
self.save_img(self.sr[0].cpu().data, self.file_name[0])
File "/home/gfzx/yjg/image_enhance_Algorithm/MIP-main/solver/solver.py", line 90, in save_img
save_dir=os.path.join('results/',self.cfg['test']['type'])
KeyError: 'test'

我不太清楚代码中的 save_dir=os.path.join('results/',self.cfg['test']['type'])self.cfg中是什么意思,可以讲解一下吗

@jiaming-wang
Copy link
Owner

这个self.cfg是读取的option.yml里面的参数,这个yml中保存的是训练超参数啥的,具体代码可以参考config.py和basesolver.py的代码。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants