Skip to content

Commit dfb8cf3

Browse files
committed
set encoding for writing a file
1 parent 4216ec4 commit dfb8cf3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tools/llm_bench/llm_bench_utils/output_file.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ def save_text_to_file(input_text, text_file_name, args):
1313
else:
1414
out_path = '.'
1515
save_path = out_path + os.sep + text_file_name
16-
input_text_file = open(save_path, 'w')
16+
input_text_file = open(save_path, 'w', encoding='utf-8')
1717
input_text_file.write(input_text)
1818
input_text_file.close()
1919

0 commit comments

Comments
 (0)