Unverified Commit 3be44cbf authored by Edna's avatar Edna Committed by GitHub
Browse files

add reset on delete

parent 56728d20
...@@ -179,7 +179,8 @@ class NunchakuFluxTransformerBlocks(nn.Module): ...@@ -179,7 +179,8 @@ class NunchakuFluxTransformerBlocks(nn.Module):
encoder_hidden_states = encoder_hidden_states.to(original_dtype).to(original_device) encoder_hidden_states = encoder_hidden_states.to(original_dtype).to(original_device)
return encoder_hidden_states, hidden_states return encoder_hidden_states, hidden_states
def __del__(self):
self.m.reset()
## copied from diffusers 0.30.3 ## copied from diffusers 0.30.3
def rope(pos: torch.Tensor, dim: int, theta: int) -> torch.Tensor: def rope(pos: torch.Tensor, dim: int, theta: int) -> torch.Tensor:
......
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