Skip to content

Commit

Permalink
Fix to work DOP with bock swap
Browse files Browse the repository at this point in the history
  • Loading branch information
kohya-ss committed Nov 17, 2024
1 parent 0047bb1 commit 2a188f0
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions flux_train_network.py
Original file line number Diff line number Diff line change
Expand Up @@ -445,6 +445,7 @@ def call_dit(img, img_ids, t5_out, txt_ids, l_pooled, timesteps, guidance_vec, t

if len(diff_output_pr_indices) > 0:
network.set_multiplier(0.0)
unet.prepare_block_swap_before_forward()
with torch.no_grad():
model_pred_prior = call_dit(
img=packed_noisy_model_input[diff_output_pr_indices],
Expand Down

0 comments on commit 2a188f0

Please sign in to comment.