From 377454be50aa4b5879d70ddedb362a700dcbe572 Mon Sep 17 00:00:00 2001 From: spicysama <122108331+AnyaCoder@users.noreply.github.com> Date: Thu, 30 Nov 2023 19:14:22 +0800 Subject: [PATCH] assure 'configs/config.json' is same (#205) * Create all_process.py * Create asr_transcript.py * Update config.py * Create extract_list.py * Create clean_list.py * Create custom.css * Create compress_model.py * Update all_process.py * Update resample.py * Update resample.py * configs/config.json copy utils * mirror: openi + token bert models optimize * text/__init__.py platform compatibility compress_model.py output * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * default_config.yml fix 'config_path' all_process.py fix 'config_path' * default_config.yml fix 'config_path' all_process.py fix 'config_path' * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> --- all_process.py | 3 +++ default_config.yml | 6 +++--- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/all_process.py b/all_process.py index f5ef07b..4559e28 100644 --- a/all_process.py +++ b/all_process.py @@ -471,6 +471,9 @@ def modify_emo_gen(emo_cfg, emo_nps, emo_device): yml["emo_gen"]["device"] = emo_device write_yaml_data_in_fact(yml) comp_emo_cfg = os.path.join(os.path.abspath(data_path), emo_cfg).replace("\\", "/") + if not os.path.exists(comp_emo_cfg): + os.makedirs(os.path.dirname(comp_emo_cfg), exist_ok=True) + shutil.copy(default_config_path, os.path.dirname(comp_emo_cfg)) msg = f"修改emo配置参数: [配置路径:{comp_emo_cfg}, 处理数:{emo_nps}, 设备:{emo_device}]" logger.info(msg) return gr.Textbox(value=msg), gr.Code(value=load_yaml_data_in_raw()) diff --git a/default_config.yml b/default_config.yml index 8d09506..d1a04a4 100644 --- a/default_config.yml +++ b/default_config.yml @@ -34,7 +34,7 @@ preprocess_text: # 验证集路径 val_path: "filelists/val.list" # 配置文件路径 - config_path: "config.json" + config_path: "configs/config.json" # 每个speaker的验证集条数 val_per_spk: 4 # 验证集最大条数,多于的会被截断并放到训练集中 @@ -47,7 +47,7 @@ preprocess_text: # 注意, “:” 后需要加空格 bert_gen: # 训练数据集配置文件路径 - config_path: "config.json" + config_path: "configs/config.json" # 并行数 num_processes: 2 # 使用设备:可选项 "cuda" 显卡推理,"cpu" cpu推理 @@ -60,7 +60,7 @@ bert_gen: # 注意, “:” 后需要加空格 emo_gen: # 训练数据集配置文件路径 - config_path: "config.json" + config_path: "configs/config.json" # 并行数 num_processes: 2 # 使用设备:可选项 "cuda" 显卡推理,"cpu" cpu推理