You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm running it on Fedora linux 39 with Python venv 3.10.13 and Imaginairy 14.1.1. I also don't have a GPU on my machine (I know it's really slow but I have nothing better at the moment and I'm patient).
After running a command like this: imagine --size 1000x500 "any prompt" --steps 5 (I suppose it concerns the specification of size) I got this error.
Traceback (most recent call last):
File "<path>/venv/lib64/python3.10/site-packages/imaginairy/cli/clickshell_mod.py", line 30, in invoke_
command.main(
File "<path>/venv/lib64/python3.10/site-packages/click/core.py", line 1078, in main
rv = self.invoke(ctx)
File "<path>/venv/lib64/python3.10/site-packages/click/core.py", line 1434, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "<path>/venv/lib64/python3.10/site-packages/click/core.py", line 783, in invoke
return __callback(*args, **kwargs)
File "<path>/venv/lib64/python3.10/site-packages/click/decorators.py", line 33, in new_func
return f(get_current_context(), *args, **kwargs)
File "/usr/lib64/python3.10/contextlib.py", line 79, in inner
return func(*args, **kwds)
File "<path>/venv/lib64/python3.10/site-packages/imaginairy/cli/imagine.py", line 187, in imagine_cmd
return _imagine_cmd(
File "<path>/venv/lib64/python3.10/site-packages/imaginairy/cli/shared.py", line 220, in _imagine_cmd
filenames = imagine_image_files(
File "<path>/venv/lib64/python3.10/site-packages/imaginairy/api/generate.py", line 90, in imagine_image_files
for result in imagine(
File "<path>/venv/lib64/python3.10/site-packages/imaginairy/api/generate.py", line 237, in imagine
result = generate_single_image(
File "<path>/venv/lib64/python3.10/site-packages/imaginairy/api/generate_refiners.py", line 236, in generate_single_image
comp_image, comp_img_orig = _generate_composition_image(
File "<path>/venv/lib64/python3.10/site-packages/imaginairy/api/generate_refiners.py", line 599, in _generate_composition_image
img = upscale_image(img, ultrasharp=True)
File "<path>/venv/lib64/python3.10/site-packages/imaginairy/enhancers/upscale_realesrgan.py", line 47, in upscale_image
upsampler_output, img_mode = realesrgan_upsampler(ultrasharp=ultrasharp).enhance(
File "<path>/venv/lib64/python3.10/site-packages/torch/utils/_contextlib.py", line 115, in decorate_context
return func(*args, **kwargs)
File "<path>/venv/lib64/python3.10/site-packages/imaginairy/vendored/realesrgan.py", line 253, in enhance
self.pre_process(img)
File "<path>/venv/lib64/python3.10/site-packages/imaginairy/vendored/realesrgan.py", line 115, in pre_process
self.img = F.pad(self.img, (0, self.pre_pad, 0, self.pre_pad), "reflect")
File "<path>/venv/lib64/python3.10/site-packages/torch/nn/functional.py", line 4495, in pad
return torch._C._nn.pad(input, pad, mode, value)
RuntimeError: "reflection_pad2d" not implemented for 'Half'
After looking around on the internet, I found this issue. Searching through the code I found imaginairy/enhancers/upscale_realesrgan.py.py. Flipping half to False with the creation of a RealESRGANer object seemed to make it work again. Maybe it could check if the user is in cpu mode to flip this to False?
I'm not at all familiar with anything regarding image generation, let alone this specific project, so it might be a bad solution.
The text was updated successfully, but these errors were encountered:
I'm running it on Fedora linux 39 with Python venv 3.10.13 and Imaginairy 14.1.1. I also don't have a GPU on my machine (I know it's really slow but I have nothing better at the moment and I'm patient).
After running a command like this:
imagine --size 1000x500 "any prompt" --steps 5
(I suppose it concerns the specification of size) I got this error.After looking around on the internet, I found this issue. Searching through the code I found imaginairy/enhancers/upscale_realesrgan.py.py. Flipping half to False with the creation of a RealESRGANer object seemed to make it work again. Maybe it could check if the user is in cpu mode to flip this to False?
I'm not at all familiar with anything regarding image generation, let alone this specific project, so it might be a bad solution.
The text was updated successfully, but these errors were encountered: