From bd81f7581719ee15ce5b240bd776a773c76af92c Mon Sep 17 00:00:00 2001 From: Ivan Malofeev <79824942+Ruhrozz@users.noreply.github.com> Date: Sat, 18 Nov 2023 12:46:53 +0700 Subject: [PATCH] fix: redefinition --- src/diffusers/models/resnet.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/diffusers/models/resnet.py b/src/diffusers/models/resnet.py index 7a48d343a531..23af7d39fd9e 100644 --- a/src/diffusers/models/resnet.py +++ b/src/diffusers/models/resnet.py @@ -752,8 +752,8 @@ def forward( hidden_states = self.norm2(hidden_states) if temb is not None and self.time_embedding_norm == "scale_shift": - scale, shift = torch.chunk(temb, 2, dim=1) - hidden_states = hidden_states * (1 + scale) + shift + _scale, _shift = torch.chunk(temb, 2, dim=1) + hidden_states = hidden_states * (1 + _scale) + _shift hidden_states = self.nonlinearity(hidden_states)