joeyballentine / ESRGAN

A modified version of the original ESRGAN test.py script with added features
Apache License 2.0
189 stars 38 forks source link

Not sure what the error is. This is my first time using it. #18

Open hopelesscase opened 2 years ago

hopelesscase commented 2 years ago

Things of note:

Here's the command I used: python3 upscale.py --cpu "1x_ReFocus_V3_140000_G.pth>2xBS_Wolly_36000.pth"

I also tried: python3 upscale.py -c "1x_ReFocus_V3_140000_G.pth>2xBS_Wolly_36000.pth"

Traceback (most recent call last): File "/Users/*/ESRGAN-master/upscale.py", line 571, in <module> app() File "/opt/homebrew/lib/python3.10/site-packages/typer/main.py", line 214, in __call__ return get_command(self)(*args, **kwargs) File "/opt/homebrew/lib/python3.10/site-packages/click/core.py", line 1130, in __call__ return self.main(*args, **kwargs) File "/opt/homebrew/lib/python3.10/site-packages/click/core.py", line 1055, in main rv = self.invoke(ctx) File "/opt/homebrew/lib/python3.10/site-packages/click/core.py", line 1404, in invoke return ctx.invoke(self.callback, **ctx.params) File "/opt/homebrew/lib/python3.10/site-packages/click/core.py", line 760, in invoke return __callback(*args, **kwargs) File "/opt/homebrew/lib/python3.10/site-packages/typer/main.py", line 500, in wrapper return callback(**use_params) # type: ignore File "/Users/*/ESRGAN-master/upscale.py", line 567, in main upscale.run() File "/Users/*/ESRGAN-master/upscale.py", line 220, in run self.load_model(model_path) File "/Users/*/ESRGAN-master/upscale.py", line 306, in load_model state_dict = torch.load(model_path) File "/opt/homebrew/lib/python3.10/site-packages/torch/serialization.py", line 713, in load return _legacy_load(opened_file, map_location, pickle_module, **pickle_load_args) File "/opt/homebrew/lib/python3.10/site-packages/torch/serialization.py", line 920, in _legacy_load magic_number = pickle_module.load(f, **pic

I've also encountered "killed" despite trying several models that previously worked before. No other info; just the word "killed".

Like this: 'python3 upscale.py --cpu 4x-UltraSharp.pth Model: "models/4x-UltraSharp.pth" Upscaling ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 0% -:--:--zsh: killed python3 upscale.py --cpu 4x-UltraSharp.pth'

Is it something with the image I'm using? The model? Something I am overlooking? I've really no idea where to even start.

joeyballentine commented 2 years ago

I'm honestly not sure what could have caused this, it appears to be an error with pythons pickler rather than with my code. Did you change anything between when it last worked and when it started breaking? (Sorry for the late response btw)

Splendide-Imaginarius commented 1 year ago

I've also encountered "killed" despite trying several models that previously worked before. No other info; just the word "killed".

Like this: 'python3 upscale.py --cpu 4x-UltraSharp.pth Model: "models/4x-UltraSharp.pth" Upscaling ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 0% -:--:--zsh: killed python3 upscale.py --cpu 4x-UltraSharp.pth'

@hopelesscase I suspect that's a different issue than the first issue you described, possibly https://github.com/joeyballentine/ESRGAN/issues/22