microsoft / Bringing-Old-Photos-Back-to-Life

Bringing Old Photo Back to Life (CVPR 2020 oral)
https://arxiv.org/abs/2004.09484
MIT License
15.14k stars 2k forks source link

"Restore the photos with scratches" section fails with **"FileNotFoundError: [Errno 2] No such file or directory: '/content/photo_restoration/Global/checkpoints/detection/FT_Epoch_latest.pt'"** #295

Open jareilly opened 7 months ago

jareilly commented 7 months ago

I am trying to run on Google Colab, using a Connected T4 hosted runtime.

The "Restore the photos with scratches" section fails with "FileNotFoundError: [Errno 2] No such file or directory: '/content/photo_restoration/Global/checkpoints/detection/FT_Epoch_latest.pt'"

1) Colab runs this: !rm -rf /content/photo_restoration/output/* !python run.py --input_folder /content/photo_restoration/test_images/old_w_scratch/ --output_folder /content/photo_restoration/output/ --GPU 0 --with_scratch

2) Output is this: Running Stage 1: Overall restoration initializing the dataloader Traceback (most recent call last): File "/content/photo_restoration/Global/detection.py", line 178, in main(config) File "/content/photo_restoration/Global/detection.py", line 92, in main checkpoint = torch.load(checkpoint_path, map_location="cpu") File "/usr/local/lib/python3.10/dist-packages/torch/serialization.py", line 998, in load with _open_file_like(f, 'rb') as opened_file: File "/usr/local/lib/python3.10/dist-packages/torch/serialization.py", line 445, in _open_file_like return _open_file(name_or_buffer, mode) File "/usr/local/lib/python3.10/dist-packages/torch/serialization.py", line 426, in init super().init(open(name, mode)) FileNotFoundError: [Errno 2] No such file or directory: '/content/photo_restoration/Global/checkpoints/detection/FT_Epoch_latest.pt' You are using NL + Res ./checkpoints/restoration/VAE_A_quality/latest_net_G.pth not exists yet! ./checkpoints/restoration/VAE_B_scratch/latest_net_G.pth not exists yet! ./checkpoints/restoration/mapping_scratch/latest_net_mapping_net.pth not exists yet! Traceback (most recent call last): File "/content/photo_restoration/Global/test.py", line 114, in input_loader = os.listdir(opt.test_input) FileNotFoundError: [Errno 2] No such file or directory: '/content/photo_restoration/output/stage_1_restore_output/masks/input'

Xadoy commented 6 months ago

It's likely caused by the same issue of #252