nagadomi / nunif

Misc; latest version of waifu2x; 2D video to stereo 3D video conversion
MIT License
1.58k stars 142 forks source link

FileNotFoundError: [Errno 2] No such file or directory: 'F:\\nunif\\waifu2x\\pretrained_models\\swin_unet\\art\\scale2x.pth' #10

Closed My12123 closed 1 year ago

My12123 commented 1 year ago

2023-03-26_16-17-13

nagadomi commented 1 year ago

You need to download the pre-trained models with the following command.

python -m waifu2x.download_models

This command is missing from the installation documentation. I have fixed it internally and will push in a few days.

My12123 commented 1 year ago

shutil.ReadError: C:\Users*\AppData\Local\Temp\nunif-w1slxtp9 is not a zip file (nunif) F:\nunif>python -m waifu2x.download_models Waifu2x Models: 100%|███████████████████████| 278M/278M [00:44<00:00, 6.24MiB/s] Traceback (most recent call last): File "F:\1\envs\nunif\lib\runpy.py", line 196, in _run_module_as_main return _run_code(code, main_globals, None, File "F:\1\envs\nunif\lib\runpy.py", line 86, in _run_code exec(code, run_globals) File "F:\nunif\waifu2x\download_models.py", line 18, in downloder.run() File "F:\nunif\nunif\utils\downloader.py", line 42, in run shutil.unpack_archive(filename=tmp.name, extract_dir=tmp_dir, options) File "F:\1\envs\nunif\lib\shutil.py", line 1298, in unpack_archive func(filename, extract_dir, dict(format_info[2])) File "F:\1\envs\nunif\lib\shutil.py", line 1201, in _unpack_zipfile raise ReadError("%s is not a zip file" % filename) shutil.ReadError: C:\Users*\AppData\Local\Temp\nunif-w1slxtp9 is not a zip fil

nagadomi commented 1 year ago

This is also a problem that occurs only on Windows.

I have fixed all the issues you reported, including this one, but I have 100+ changes in the private repository and I am still working on the photo model, so the release will be at the end of the month.

EDIT: workaround, manually download the zip file from https://github.com/nagadomi/nunif/releases/download/0.0.0/waifu2x_pretrained_models_20230202.zip and unzip to ./waifu2x/pretrained_models

nagadomi commented 1 year ago

Fixed by https://github.com/nagadomi/nunif/commit/f8f9151a1a40f5bca81dff4721f5d17aecfb7fd7 Also I have updated waifu2x/pretrained_models so re-download it.