http://contrib.scikit-learn.org/metric-learn/introduction.html
1. What is Metric Learning?
- 두 점 사이의 거리를 측정하는 measure 에는 여러가지가 있다.
- Euclidean, City-Block, Cosine, etc.
- 하지만 문제에 적합한 메트릭을 선택하는 일은 어렵다.
- Metric Learning은 자동으로 문제에 적합한 메트릭을 만들어내는것을 목표로 한다.
1.1. Problem Setting
메트릭 러닝 문제는 두가지 카테고리로 나눌수 있다.
- Supervised learning
- 각 데이터에 class(label)이 정해져 있다.
- classification 문제
- 같은 label에 속하는 점은 가까운 거리로 만들고 다른 label은 먼 거리에 속하도록 학습시킨다.
- Weakly supervised learning
- 튜플 레벨로 데이터가 구성된다.(2개, 3개, 혹은 4개 쌍으로)
- 각 set가 positive인지 negative인지 정한다.
- postive 페어는 거리가 가깝게 negative 페어는 멀어지도록 학습시킨다.
1.2. Mahalanobis Distances
- Mahalanobis distance is a Euclidean distance after a linear transformation of the feature space defined by 𝐿 (taking 𝐿 to be the identity matrix recovers the standard Euclidean distance)