Skip to content

Commit

Permalink
Fixed YAML loading. (#7579)
Browse files Browse the repository at this point in the history
  • Loading branch information
YiqinZhao authored Apr 11, 2024
1 parent 0bee4d3 commit 8e14535
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/diffusers/pipelines/stable_diffusion/convert_from_ckpt.py
Original file line number Diff line number Diff line change
Expand Up @@ -1843,6 +1843,8 @@ def download_controlnet_from_original_ckpt(
while "state_dict" in checkpoint:
checkpoint = checkpoint["state_dict"]

with open(original_config_file, "r") as f:
original_config_file = f.read()
original_config = yaml.safe_load(original_config_file)

if num_in_channels is not None:
Expand Down

0 comments on commit 8e14535

Please sign in to comment.