save_json_result.py 259 B

1234567
  1. import json
  2. from tts_webui.utils.outputs.path import get_relative_output_path_ext
  3. def save_json_result(result_dict, metadata):
  4. with open(get_relative_output_path_ext(result_dict, ".json"), "w") as outfile:
  5. json.dump(metadata, outfile, indent=2)