New Spandrel requirement in Realesrgan_model.py #15209
love2stablediff7
started this conversation in
Optimization
Replies: 1 comment
-
it is in the https://github.com/AUTOMATIC1111/stable-diffusion-webui/wiki/Contributing#quirks I think python 3.7 is not supported at this point and so |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
The new code listed in realesrgan_model.py adds this code:
model_descriptor = modelloader.load_spandrel_model(
info.local_data_path,
device=self.device,
prefer_half=(not cmd_opts.no_half and not cmd_opts.upcast_sampling),
expected_architecture="ESRGAN", # "RealESRGAN" isn't a specific thing for Spandrel
)
And on line 150 for modelloader.py, it calls "import spandrel" which if you had loaded it at the start of the file you would have found this exception faster, rather than lazy loading it, only finding this error after you try to upscale.
Notes about Spandrel:
Spandrel requires torch 2.1.2 versus Xformers which wants torch 2.2.0 to work.
Spandrel is not listed under the requirements - so it is not downloaded by default for new installs.
Notes about the code:
line 150 "import spandrel" does not work. According to the script, spandrel module does not exist.
Recommendations: update the requirements to add spandrel & re-examine the code to insure that it works with newer installs. Also, if it isn't going to work with Xformers, you should probably decide to remove xformers from the website, since it is not compatible.
Beta Was this translation helpful? Give feedback.
All reactions