Commit 5cfb5351 authored by muyangli's avatar muyangli
Browse files

Merge branch 'main' into dev

parents 85959824 9912f57e
......@@ -180,7 +180,8 @@ class NunchakuFluxTransformerBlocks(nn.Module):
encoder_hidden_states = encoder_hidden_states.to(original_dtype).to(original_device)
return encoder_hidden_states, hidden_states
def __del__(self):
self.m.reset()
## copied from diffusers 0.30.3
def rope(pos: torch.Tensor, dim: int, theta: int) -> torch.Tensor:
......
......@@ -130,7 +130,8 @@ class NunchakuSanaTransformerBlocks(nn.Module):
.to(original_dtype)
.to(original_device)
)
def __del__(self):
self.m.reset()
class NunchakuSanaTransformer2DModel(SanaTransformer2DModel, NunchakuModelLoaderMixin):
@classmethod
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment