Skip to content

Commit 25f4e4b

Browse files
remove guidance_scale
1 parent b007be0 commit 25f4e4b

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

examples/cogview4-control/train_control_cogview4.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1100,7 +1100,7 @@ def load_model_hook(models, input_dir):
11001100
crop_coords=crops_coords_top_left,
11011101
return_dict=False,
11021102
)[0]
1103-
model_pred = noise_pred_uncond + args.guidance_scale * (noise_pred_cond - noise_pred_uncond)
1103+
model_pred = noise_pred_uncond + (noise_pred_cond - noise_pred_uncond)
11041104
# these weighting schemes use a uniform timestep sampling
11051105
# and instead post-weight the loss
11061106
weighting = compute_loss_weighting_for_sd3(weighting_scheme=args.weighting_scheme, sigmas=sigmas)

scripts/convert_cogview4_to_diffusers.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -210,6 +210,7 @@ def main(args):
210210
"norm_num_groups": 32,
211211
"sample_size": 1024,
212212
"scaling_factor": 1.0,
213+
"shift_factor": 0.0,
213214
"force_upcast": True,
214215
"use_quant_conv": False,
215216
"use_post_quant_conv": False,

0 commit comments

Comments
 (0)