Skip to content

Commit

Permalink
print match rate only on rank 0
Browse files Browse the repository at this point in the history
  • Loading branch information
foin6 committed Jan 15, 2024
1 parent 246da21 commit 20f47c7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion inference/huggingface/text-generation/ds-hf-compare.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,4 +110,4 @@ def string_similarity(str1, str2):
similarity = string_similarity(base_out['generated_text'], ds_out[0]['generated_text'])
if args.print_outputs: print(f"The similarity ratio is: {similarity*100}%")

print(f"Matches: {match_count}\nMismatches: {mismatch_count}")
print_0(f"Matches: {match_count}\nMismatches: {mismatch_count}")

0 comments on commit 20f47c7

Please sign in to comment.