Unverified Commit 8e145357 authored by Yiqin Zhao's avatar Yiqin Zhao Committed by GitHub
Browse files

Fixed YAML loading. (#7579)

parent 0bee4d33
...@@ -1843,6 +1843,8 @@ def download_controlnet_from_original_ckpt( ...@@ -1843,6 +1843,8 @@ def download_controlnet_from_original_ckpt(
while "state_dict" in checkpoint: while "state_dict" in checkpoint:
checkpoint = checkpoint["state_dict"] 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) original_config = yaml.safe_load(original_config_file)
if num_in_channels is not None: if num_in_channels is not None:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment