update_param module
参数映射更新工具 从 Excel 参数文件生成 Python 参数映射模块
- class update_param.ParamUpdater(config: AppConfig)[源代码]
基类:
object参数映射更新器
- collect_validation_data(param_file: Path, varient_file: Path = None) Dict[str, List[str]][源代码]
收集所有验证数据(基础参数 + 差分参数)
- 参数:
param_file -- 基础参数文件路径
varient_file -- 差分参数文件路径(可选)
- 返回:
参数名 -> 参数值列表
- 返回类型:
Dict[str, List[str]]
- generate_mappings_file(mappings: Dict[str, Dict[str, str]], output_file: Path)[源代码]
生成参数映射 Python 文件
- 参数:
mappings -- 参数映射字典
output_file -- 输出文件路径
- get_all_validate_params() Dict[str, List[str]][源代码]
获取所有句子生成器的参数翻译类型
- 返回:
去重后的数据验证参数类型列表
- 返回类型:
Dict[str, Dict[str, list[str]]]