diff --git a/modules/processing_vae.py b/modules/processing_vae.py index e2c78b15c..bb0a11cb5 100644 --- a/modules/processing_vae.py +++ b/modules/processing_vae.py @@ -44,8 +44,8 @@ def full_vae_decode(latents, model): upcast = (model.vae.dtype == torch.float16) and getattr(model.vae.config, 'force_upcast', False) and hasattr(model, 'upcast_vae') if upcast: # this is done by diffusers automatically if output_type != 'latent' model.upcast_vae() - latents = latents.to(next(iter(model.vae.post_quant_conv.parameters())).dtype) + latents = latents.to(next(iter(model.vae.post_quant_conv.parameters())).dtype) decoded = model.vae.decode(latents / model.vae.config.scaling_factor, return_dict=False)[0] # Delete PyTorch VAE after OpenVINO compile