Closed TimZhang001 closed 2 years ago
Hi! Did you get it to work?
Hi! Did you get it to work?
yes, thanks.
当我测试它时,报告了以下错误,你能告诉我原因吗?
没有名为“models.archs”的模块。文件“C:\Program Files\Python3\Lib\importlibinit.py”,第 127 行,import_module返回_bootstrap。_gcd_import(name[level:], package, level) File “D:\virtualenv\pytorch19\code\defocus\IFAN-main\models\trainers\trainer.py”, 行 39, in init lib = importlib.import_module('models.archs.{}'.format(config.network)) 文件 “D:\virtualenv\pytorch19\code\defocus\IFAN-main\modelsinit.py”,第 5 行,在 create_model model = lib 中。模型(config) 文件 “D:\virtualenv\pytorch19\code\defocus\IFAN-main\eval.py”,第 44 行,在 init model = create_model(config) 文件 “D:\virtualenv\pytorch19\code\defocus\IFAN-main\eval.py”,第 75 行,在 eval_quan_qual input_c_file_path_list、input_l_file_path_list、input_r_file_path_list、gt_file_path_list = init(config, mode) 文件 “D:\virtualenv\pytorch19\code\defocus\IFAN-main\eval.py”, 第 187 行,在 eval eval_quan_qual(config) 文件中 “D:\virtualenv\pytorch19\code\defocus\IFAN-main\run.py”中,第 338 行,在 eval(config) 文件中 文件 “C:\Program Files\Python3\Lib\runpy.py”,第 85 行,在 _run_code exec(code, run_globals) 文件中 “C:\Program Files\Python3\Lib\runpy.py”,第 96 行,在 _run_module_code mod_name, mod_spec, pkg_name, script_name) 文件 “C:\Program Files\Python3\Lib\runpy.py”,第 263 行,在 run_path 中 pkg_name=pkg_name, script_name=fname) 文件 “C:\Program Files\Python3\Lib\runpy.py”,第 85 行,在 exec(code, run_globals) _run_code exec(code, ) 文件 “C:\Program Files\Python3\Lib\runpy.py”,第 193 行,_run_module_as_main (当前帧)“main”,mod_spec)
HI,How did you solve it?
when I test it, the following error has been reported, can you tell me the reason?
No module named 'models.archs.' File "C:\Program Files\Python3\Lib\importlib__init.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "D:\virtualenv\pytorch19\code\defocus\IFAN-main\models\trainers\trainer.py", line 39, in init__ lib = importlib.import_module('models.archs.{}'.format(config.network)) File "D:\virtualenv\pytorch19\code\defocus\IFAN-main\models__init.py", line 5, in create_model model = lib.Model(config) File "D:\virtualenv\pytorch19\code\defocus\IFAN-main\eval.py", line 44, in init model = create_model(config) File "D:\virtualenv\pytorch19\code\defocus\IFAN-main\eval.py", line 75, in eval_quan_qual input_c_file_path_list, input_l_file_path_list, input_r_file_path_list, gt_file_path_list = init(config, mode) File "D:\virtualenv\pytorch19\code\defocus\IFAN-main\eval.py", line 187, in eval eval_quan_qual(config) File "D:\virtualenv\pytorch19\code\defocus\IFAN-main\run.py", line 338, in
eval(config)
File "C:\Program Files\Python3\Lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\Program Files\Python3\Lib\runpy.py", line 96, in _run_module_code
mod_name, mod_spec, pkg_name, script_name)
File "C:\Program Files\Python3\Lib\runpy.py", line 263, in run_path
pkg_name=pkg_name, script_name=fname)
File "C:\Program Files\Python3\Lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\Program Files\Python3\Lib\runpy.py", line 193, in _run_module_as_main (Current frame)
" main__", mod_spec)