summaryrefslogtreecommitdiffstats
path: root/pipelines/stable_diffusion
diff options
context:
space:
mode:
authorVolpeon <git@volpeon.ink>2022-10-17 12:27:53 +0200
committerVolpeon <git@volpeon.ink>2022-10-17 12:27:53 +0200
commit633d890e4964e070be9b0a5b299c2f2e51d4b055 (patch)
tree235b33195b041e45bb7a6a24471ea55ad4bd7850 /pipelines/stable_diffusion
parentUpdate (diff)
downloadtextual-inversion-diff-633d890e4964e070be9b0a5b299c2f2e51d4b055.tar.gz
textual-inversion-diff-633d890e4964e070be9b0a5b299c2f2e51d4b055.tar.bz2
textual-inversion-diff-633d890e4964e070be9b0a5b299c2f2e51d4b055.zip
Upstream updates; better handling of textual embedding
Diffstat (limited to 'pipelines/stable_diffusion')
-rw-r--r--pipelines/stable_diffusion/vlpn_stable_diffusion.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/pipelines/stable_diffusion/vlpn_stable_diffusion.py b/pipelines/stable_diffusion/vlpn_stable_diffusion.py
index 2656b28..8b08a6f 100644
--- a/pipelines/stable_diffusion/vlpn_stable_diffusion.py
+++ b/pipelines/stable_diffusion/vlpn_stable_diffusion.py
@@ -301,7 +301,7 @@ class VlpnStableDiffusion(DiffusionPipeline):
301 301
302 # scale and decode the image latents with vae 302 # scale and decode the image latents with vae
303 latents = 1 / 0.18215 * latents 303 latents = 1 / 0.18215 * latents
304 image = self.vae.decode(latents).sample 304 image = self.vae.decode(latents.to(dtype=self.vae.dtype)).sample
305 305
306 image = (image / 2 + 0.5).clamp(0, 1) 306 image = (image / 2 + 0.5).clamp(0, 1)
307 image = image.cpu().permute(0, 2, 3, 1).float().numpy() 307 image = image.cpu().permute(0, 2, 3, 1).float().numpy()