sanghyun-son / EDSR-PyTorch

PyTorch version of the paper 'Enhanced Deep Residual Networks for Single Image Super-Resolution' (CVPRW 2017)
MIT License
2.43k stars 669 forks source link

an error about test model #255

Open coco1549134149 opened 4 years ago

coco1549134149 commented 4 years ago

when i test the model, if i add the args --save_results, it comes the problem.

(tf2) C:\selfile\selfile\project\EDSR-PyTorch-master\src>python main.py --data_test DIV2K --scale 2 --pre_train C:\selfile\selfile\project\EDSR-PyTorch-master\experiment\edsr_baseline_x2\model\model_best.pt --test_only --self_ensemble --data_range 861-864 --save_results Traceback (most recent call last): File "main.py", line 33, in main() File "main.py", line 26, in main while not t.terminate(): File "C:\selfile\selfile\project\EDSR-PyTorch-master\src\trainer.py", line 151, in terminate self.test() File "C:\selfile\selfile\project\EDSR-PyTorch-master\src\trainer.py", line 86, in test self.ckp.begin_background() File "C:\selfile\selfile\project\EDSR-PyTorch-master\src\utility.py", line 144, in begin_background p.start() File "C:\Users\15491\AppData\Local\conda\conda\envs\tf2\lib\multiprocessing\process.py", line 105, in start self._popen = self._Popen(self) File "C:\Users\15491\AppData\Local\conda\conda\envs\tf2\lib\multiprocessing\context.py", line 223, in _Popen return _default_context.get_context().Process._Popen(process_obj) File "C:\Users\15491\AppData\Local\conda\conda\envs\tf2\lib\multiprocessing\context.py", line 322, in _Popen return Popen(process_obj) File "C:\Users\15491\AppData\Local\conda\conda\envs\tf2\lib\multiprocessing\popen_spawn_win32.py", line 65, in init reduction.dump(process_obj, to_child) File "C:\Users\15491\AppData\Local\conda\conda\envs\tf2\lib\multiprocessing\reduction.py", line 60, in dump ForkingPickler(file, protocol).dump(obj) _AttributeError: Can't pickle local object 'checkpoint.begin_background..bgtarget'

(tf2) C:\selfile\selfile\project\EDSR-PyTorch-master\src>Traceback (most recent call last): File "", line 1, in File "C:\Users\15491\AppData\Local\conda\conda\envs\tf2\lib\multiprocessing\spawn.py", line 105, in spawn_main exitcode = _main(fd) File "C:\Users\15491\AppData\Local\conda\conda\envs\tf2\lib\multiprocessing\spawn.py", line 115, in _main self = reduction.pickle.load(from_parent) EOFError: Ran out of input

coco1549134149 commented 4 years ago

my environment is python3.6 pytorch 1.2

coco1549134149 commented 4 years ago

i have solved the problem by#105

MukeshA1 commented 4 years ago

Hi, I am also facing the same issue. Can you please let me know the resolution for this problem. Thanks!

dynamiterdx commented 3 years ago

Hi @coco1549134149 and @MukeshA1 . I am facing the same problem. Could you please tell me how you resolved it? Would be great help.

YDDDDG commented 3 years ago

Hi It seems to be blamed on the Windows OS. Someone has already submitted the same issue, you guys can search it, and in that issue, there is the solution @coco1549134149 and @MukeshA1 and @dynamiterdx