mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
use 'auto' slice size
This commit is contained in:
parent
5e7ed964d2
commit
8ed8bf52d0
@ -313,8 +313,7 @@ class StableDiffusionGeneratorPipeline(StableDiffusionPipeline):
|
|||||||
# fix is in https://github.com/kulinseth/pytorch/pull/222 but no idea when it will get merged to pytorch mainline.
|
# fix is in https://github.com/kulinseth/pytorch/pull/222 but no idea when it will get merged to pytorch mainline.
|
||||||
pass
|
pass
|
||||||
else:
|
else:
|
||||||
slice_size = 4 # or 2, or 8. i chose this arbitrarily.
|
self.enable_attention_slicing(slice_size='auto')
|
||||||
self.enable_attention_slicing(slice_size=slice_size)
|
|
||||||
|
|
||||||
|
|
||||||
def image_from_embeddings(self, latents: torch.Tensor, num_inference_steps: int,
|
def image_from_embeddings(self, latents: torch.Tensor, num_inference_steps: int,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user