boostcampaitech3 / level2-data-annotation_cv-level2-cv-15

level2-data-annotation_cv-level2-cv-15 created by GitHub Classroom
6 stars 1 forks source link

[Experiment] Optimizer #28

Open leehyeonjin99 opened 2 years ago

leehyeonjin99 commented 2 years ago

실험

실험 목표

동기

환경 및 과정

📎 성능 평가 지표

  • Mean Loss = epoch_loss / num_batches
    • epoch_loss : 각 epoch마다 모든 batch의 loss를 합한 값

📎 optimizer 적용 방법

from importlib import import_module
import madgrad
import adamp

if optimizer in dir(torch.optim):
    opt_module = getattr(import_module('torch.optim'), optimizer)
    optimizer = opt_module(model.parameters(), lr=learning_rate)
elif optimizer == 'MADGRAD':
    optimizer = madgrad.MADGRAD(model.parameters(), lr=learning_rate)
elif optimizer == 'AdamP':
    optimizer = adamp.AdamP(model.parameters(), lr=learning_rate)

결과

image