Skip to content

Commit

Permalink
Update performance.py
Browse files Browse the repository at this point in the history
  • Loading branch information
Ousret committed May 11, 2022
1 parent e45957f commit 7f0e4a7
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions bin/performance.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,10 @@ def performance_compare(arguments):

print("------------------------------")
print("--> Charset-Normalizer / Chardet: Performance Сomparison")
print(" --> Avg: " + str(round(((chardet_avg_delay / charset_normalizer_avg_delay - 1) * 100), 2)) + "%")
print(" --> 99th: " + str(round(((chardet_99p / charset_normalizer_99p - 1) * 100), 2)) + "%")
print(" --> 95th: " + str(round(((chardet_95p / charset_normalizer_95p - 1) * 100), 2)) + "%")
print(" --> 50th: " + str(round(((chardet_50p / charset_normalizer_50p - 1) * 100), 2)) + "%")
print(" --> Avg: x" + str(round(chardet_avg_delay / charset_normalizer_avg_delay, 2)))
print(" --> 99th: x" + str(round(chardet_99p / charset_normalizer_99p, 2)))
print(" --> 95th: x" + str(round(chardet_95p / charset_normalizer_95p, 2)))
print(" --> 50th: x" + str(round(chardet_50p / charset_normalizer_50p, 2)))

return 0 if chardet_avg_delay > charset_normalizer_avg_delay and chardet_99p > charset_normalizer_99p else 1

Expand Down

0 comments on commit 7f0e4a7

Please sign in to comment.