Skip to content

Instantly share code, notes, and snippets.

@JohnDeJesus22
Created July 18, 2020 23:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save JohnDeJesus22/93d02daa8cae578b654dafbec4540107 to your computer and use it in GitHub Desktop.
Save JohnDeJesus22/93d02daa8cae578b654dafbec4540107 to your computer and use it in GitHub Desktop.
f1score
precision = cm[1,1]/(cm[1,1] + cm[0,1])
recall = cm[1,1]/(cm[1,1] + cm[1,0])
numerator = precision*recall
denominator = precision + recall
f1_score = 2* numerator/denominator
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment