xinntao / Real-ESRGAN

Real-ESRGAN aims at developing Practical Algorithms for General Image/Video Restoration.
BSD 3-Clause "New" or "Revised" License
27.13k stars 3.41k forks source link

UnboundLocalError: local variable 'file_url' referenced before assignment #628

Open Pokemanuel opened 1 year ago

Pokemanuel commented 1 year ago

Help with the error please File "C:\Users\user\Real-ESRGAN\inference_realesrgan.py", line 166, in main() File "C:\Users\user\Real-ESRGAN\inference_realesrgan.py", line 94, in main for url in file_url: UnboundLocalError: local variable 'file_url' referenced before assignment

I just found out that it only happens if I don't use the default models, any way to make the other models work?

Amazomic commented 8 months ago

Most likely you are entering a model name that is not defined in the inference_realesrgan file. you can go to the files and find there the correct names for the model! I had this happen when I specified the model realesr-general-wdn-x4v3 instead of realesr-general-x4v3.