Skip to content

Commit

Permalink
Add indentation for llm_bench json report dumping (#1584)
Browse files Browse the repository at this point in the history
Make report more easily readable

Co-authored-by: guozhong wang <[email protected]>
  • Loading branch information
nikita-savelyevv and wgzintel authored Jan 20, 2025
1 parent d4bb7c1 commit fe6311d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tools/llm_bench/llm_bench_utils/output_json.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ def write_result(report_file, model, framework, device, model_args, iter_data_li
output_result = {'metadata': metadata, "perfdata": {'compile_time': pretrain_time, 'results': result}}

with open(report_file, 'w') as outfile:
json.dump(output_result, outfile)
json.dump(output_result, outfile, indent=4)


def get_timestamp(iter_idx, prompt_idx, iter_timestamp):
Expand Down

0 comments on commit fe6311d

Please sign in to comment.