Skip to content

Commit

Permalink
change hardcoded config
Browse files Browse the repository at this point in the history
  • Loading branch information
ErwannMillon committed Aug 28, 2024
1 parent 31d060c commit 6325493
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/diffusers/models/transformers/transformer_flux.py
Original file line number Diff line number Diff line change
Expand Up @@ -515,7 +515,7 @@ def custom_forward(*inputs):

for index_block, block in enumerate(self.single_transformer_blocks):
if global_gradient_checkpointing:
if index_block % 2 == 0 or index_block > len(self.single_transformer_blocks) - 2:
if index_block % 4 == 0 or index_block > len(self.single_transformer_blocks) - 2:
self.gradient_checkpointing = True
else:
# print("Force disabling grad checkpointing singlestream")
Expand Down

0 comments on commit 6325493

Please sign in to comment.