f1-score 종류와 의미 (macro, weighted, micro)
scikit-learn 의 classification_report 는 분류 모델의 예측 성능을 평가하기 위해 널리 활용된다. 이진 분류일 때는 주로 소수의 클래스에 해당하는 precision, recall, f1-score 를 중요하게 본다. 그래서 함께 표시되는 macro avg, weighted avg 값들에 크게 관심을 가지지 않았고, 특히 다중 분류의 경우 f1-score 가 정확히 어떻게 계산되는지 모르고 있었기에 이번 글에서 f1-score 의 종류와 의미에 대해 정리해보고자 한다. 1. f1-score 종류와 의미sklearn 공식 문서에 따르면, f1-score 의 종류에는 크게 3가지가 있으며 정의는 다음과 같다.1. macro average: averaging the unweighted..
2022.10.27