We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d66abdc commit 0e1a22aCopy full SHA for 0e1a22a
src/diffusers/models/autoencoders/autoencoder_kl_cogvideox.py
@@ -41,7 +41,9 @@ class CogVideoXSafeConv3d(nn.Conv3d):
41
"""
42
43
def forward(self, input: torch.Tensor) -> torch.Tensor:
44
- memory_count = torch.prod(torch.tensor(input.shape)) * 2 / 1024**3
+ memory_count = (
45
+ (input.shape[0] * input.shape[1] * input.shape[2] * input.shape[3] * input.shape[4]) * 2 / 1024**3
46
+ )
47
48
# Set to 2GB, suitable for CuDNN
49
if memory_count > 2:
0 commit comments