boostcampaitech2 / klue-level2-nlp-06

KLUE-RE - Relation Extraction
5 stars 2 forks source link

[ADD] Added Focal Loss #26

Closed BaekTree closed 2 years ago

BaekTree commented 2 years ago

Added Focal Loss -added option in config.json

Added alpha and gamma optoins in config seting

Modified the code

wlsl8135 commented 2 years ago

focal loss 정의된 파일이 있을까요?

BaekTree commented 2 years ago

@wlsl8135 train.py의 RE_Trainer안에 compute_loss 함수에 정의되어 있어요! 오픈소스 참고해서 우리 레이블에 맞게 수정했습니다!

wlsl8135 commented 2 years ago

답변감사합니다! 혹시 from focal_loss 부분에서 별도로 설치하신건 없을까요?

BaekTree commented 2 years ago

@wlsl8135 음슴당!

BaekTree commented 2 years ago

어...? 아 잠시만요 ㅋㅋㅋㅋ

BaekTree commented 2 years ago

아이고... 한진님 말씀이 맞았습니다 ㅜㅜ 파일에 구현을 해뒀었네요 제가 ㅜㅜ

BaekTree commented 2 years ago

@wlsl8135