-
Notifications
You must be signed in to change notification settings - Fork 6.5k
add enable sequential cpu offloading to other stable diffusion pipelines #1085
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
The documentation is not available anymore as the PR was closed or merged. |
|
@patrickvonplaten the tests that are not passing seem to be related to the Same happened with #1010 btw. Edit: nevermind you fixed it lightning fast. |
…load is enabled with fp16 Co-authored-by: Pedro Gengo <[email protected]>
|
@patrickvonplaten I've added @pedrogengo to d6fcb91 because he found the bug that this commit solves and helped me find the solution. |
|
@piEsposito After line 402 of inpaint pipeline file you should add:
To make sure that all tensors are on the same device. Unfortunately, I could not comment direct on the file. |
|
@patrickvonplaten thank you for the kindness of addreessing your review. |
|
Thanks a lot the PR :-) |
* make some paths windows friendly (huggingface#1066) * add csv output to builder script and reduce number of models tested
…nes (huggingface#1085) * add enable sequential cpu offloading to other stable diffusion pipelines * trigger ci * fix styling * interpolate before converting to device to avoid breking when cpu_offload is enabled with fp16 Co-authored-by: Pedro Gengo <[email protected]> * style again I need to stop forgething this thing * fix inpainting bug that could cause device misalignment Co-authored-by: Pedro Gengo <[email protected]> * Apply suggestions from code review Co-authored-by: Pedro Gengo <[email protected]> Co-authored-by: Patrick von Platen <[email protected]>
Follow up of #1024
Adds
enable_sequential_cpu_offloadmethod toStableDiffusionInpaintPipelineandStableDiffusionImg2ImgPipelinealongs with proper tests.Also renames the test on
StableDiffusionPipeline.enable_sequential_cpu_offloadtotest_stable_diffusion_pipeline_with_sequential_cpu_offloadingfor clarity.@patrickvonplaten here I'm just adding the
enable_sequential_cpu_offloadmethod to the img2img and inpainting pipelines for Stable Diffusion.