Ensure ascii false for json dump, and fix bug

This commit is contained in:
litagin02
2024-01-02 22:58:17 +09:00
parent 98ee6f4c69
commit 1546bd4ec5
4 changed files with 18 additions and 18 deletions

View File

@@ -12,7 +12,7 @@ def set_style_config(json_path, output_path):
json_dict["data"]["num_styles"] = 1
json_dict["data"]["style2id"] = {DEFAULT_STYLE: 0}
with open(output_path, "w", encoding="utf-8") as f:
json.dump(json_dict, f, indent=2)
json.dump(json_dict, f, indent=2, ensure_ascii=False)
logger.info(f"Save style config (only {DEFAULT_STYLE}) to {output_path}")