hyperparameter가 하는 일
Hyperparameter는 학습 알고리즘이 데이터에서 안 배우는 손잡이 — regularization 강도, tree depth, learning rate, estimator 수. 용량과 bias-variance trade-off를 control. 튜닝은 CV score 최대화하려고 configuration space를 search 하는 거.
세 search 전략
- Grid search — 작은 grid 위 exhaustive. 추론 쉬움, grid 커지면 비싸짐.
- Random search — distribution에서 sample. 소수 hyperparameter만 중요할 때 unit budget 당 더 넓게 cover.
- Bayesian / Optuna — objective 모델링하고 promising config 제안. 비싼 evaluation에 best.
search 인플레이션 trap
같은 validation set 위 100 trial 튜닝하면, 그 set에 한 번도 train 안 해도 overfit 하고 있어. nested CV 쓰거나 별도 test set untouched 유지. search budget도 free resource가 아니라 네가 고르는 hyperparameter야.