From 93acb648bda4a138dcc3c3187d0355d395ed3c6a Mon Sep 17 00:00:00 2001 From: NanoCode012 Date: Sun, 28 May 2023 02:55:46 +0900 Subject: [PATCH] Fix load error --- scripts/finetune.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/finetune.py b/scripts/finetune.py index 954ce1625..57d2520d3 100644 --- a/scripts/finetune.py +++ b/scripts/finetune.py @@ -131,10 +131,10 @@ def train( # load the config from the yaml file with open(config, "r") as f: - cfg: Dict = Dict(lambda: None, yaml.load(f, Loader=yaml.Loader)) + cfg: Dict = Dict(yaml.load(f, Loader=yaml.Loader)) # if there are any options passed in the cli, if it is something that seems valid from the yaml, # then overwrite the value - cfg_keys = dict(cfg).keys() + cfg_keys = cfg.keys() for k in kwargs: # if not strict, allow writing to cfg even if it's not in the yml already if k in cfg_keys or cfg.strict is False: