You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
John Mount 의 영상 설명 전상혁님 블로그
전상혁님의 PAC learning 글을 5번은 보았던 것 같다. 4년 전에는 까막눈으로 보았었고, 매년 PAC learning 개념이 논문에서 사용될 때마다 보았었는데, 잘 이해가 안 갔었다. 기초가 쌓이기 시작한 이제서야 글이 대에에충 이해가 간다.
높은 확률로 고른 hypothesis (모델) 가 low error 를 갖게 하도록 만들자!
PAC 용 notation
Training data sample 수 $m$
Train error 와 population error 의 gap $\epsilon$.
즉, gap 의 upper bound 는 training data $m$ 과 complexity $|H|$, generalization error $\epsilon$, 그리고 confidence $\delta$ 에 의해 정의된다. $\epsilon$ 은 generalization 과 overfitting 과 직접적인 연관이 있다. $\epsilon$ 이 직접적인 generalization term이고, $\epsilon$ 이 크면 클 수록 더 좋은 대체 모델이 존재할 확률이 커지므로, overfitting 과도 연관이 된다.
PAC Bayesian Generalization Bound (Appendix A.1)
gaussian perturbation 을 줘도 population loss L_D 가 test error 를 감소시키지 않을 것이라는 제한을 두고 theorem 증명일 진행한다.
증명은 못 알아먹겠다. 생략.
Notation
Model ${\huge w \in \mathcal{W} \in \mathbb{R}^d}$
Per-data-point loss function ${\huge l: \mathcal{W} \times \mathcal{X} \times \mathcal{Y} \rightarrow \mathbb{R}_{+}}$
training set loss
population loss
SAM
population loss는 알 수 없으니 training set loss 로 이를 근사하고, optimizing 하는 게 일반적이다. 근데, sub-optimal 로 빠지기 쉽기 때문에 새로운 방식으로 SAM을 제시한다.
시작은 간소화된 PAC Bayesian Generalization Bound 이다.
간소화된 수식에 ${\huge -L_S (w)+ L_S (w)}$ 를 중간 텀에 넣어주면, sharpness 와 train loss, regularization 을 뽑아낼 수 있다.
즉, train loss 에 regularaization 을 더해서 사용하는 일반적인 경우, sharpness 는 신경 안 쓰면서 PAC Learning 을 하고 있는 느낌.
저자들은, Sharpness 와 regularziation term 을 활용하는 방향으로 학습을 진행시킨다.
여기서 $\rho$ 값은 hyperparmeter 인데 (epsilon 의 크기), batch-size 에 민감해서 잘 조정해야 한다.
Norm 차원 p 값은 2 를 사용하였다. (실험적으로 결정했다고 한다. appendix c.5)
아무튼 제시한 방법을 컴퓨터로 풀어내야 하니, 수식을 좀 더 전개를 해보자. ${\huge L_S (w+\epsilon)}$ 을 최대화 하는 ${\huge \epsilon}$ 을 ${\huge \epsilon^*}$ 이라 하자. ${\huge \epsilon}$ 값이 작기 때문에, 테일러 급수를 적용할 수 있고, ${\huge L_S (w)}$ 는 epsilon 에 무관한 값이니까, 제외시킨다.
그러면, dual norm 문제가 하나 툭 튀어 나온다.
깔끔하게 풀어내면, 최종 Loss term 에 hessian term 이 더해진 형태가 나오게 된다.
Hessian 은 빼 버리는게 국룰.
알고리즘을 정리하면 다음과 같다.
그림의 1, 2, 3 순으로
epsilon 만큼 이동 시키고,
이동된 곳에서 loss 를 구하고
현재 weight에 적용.
Results
batch size m 과 rho 값을 적당히 가져가는게 성능에 주요했다.
second order 까지 실험을 했는데, first order 실험결과가 더 좋다. 이유는 저자들도 모르겠다고 한다.
성능. 나쁘지 않다.
augmentation 이 강해져도 효과가 있음을 보였다.
The text was updated successfully, but these errors were encountered:
paper code
Probably Approximately Correct (PAC)
John Mount 의 영상 설명
전상혁님 블로그
전상혁님의 PAC learning 글을 5번은 보았던 것 같다. 4년 전에는 까막눈으로 보았었고, 매년 PAC learning 개념이 논문에서 사용될 때마다 보았었는데, 잘 이해가 안 갔었다. 기초가 쌓이기 시작한 이제서야 글이 대에에충 이해가 간다.
높은 확률로 고른 hypothesis (모델) 가 low error 를 갖게 하도록 만들자!
PAC 용 notation
Training data sample 수$m$ $\epsilon$ .
Train error 와 population error 의 gap
Finite hypothesis space 의 complexity$|H|$ $(1-\delta)$
confidence of the relation : at least
PAC Bound
finite hypothesis space 에 대해 PAC bound 는 다음과 같이 주어진다.
즉, gap 의 upper bound 는 training data$m$ 과 complexity $|H|$ , generalization error $\epsilon$ , 그리고 confidence $\delta$ 에 의해 정의된다.
$\epsilon$ 은 generalization 과 overfitting 과 직접적인 연관이 있다.
$\epsilon$ 이 직접적인 generalization term이고,
$\epsilon$ 이 크면 클 수록 더 좋은 대체 모델이 존재할 확률이 커지므로, overfitting 과도 연관이 된다.
PAC Bayesian Generalization Bound (Appendix A.1)
gaussian perturbation 을 줘도 population loss L_D 가 test error 를 감소시키지 않을 것이라는 제한을 두고 theorem 증명일 진행한다.
![image](https://user-images.githubusercontent.com/16400591/193768422-9fd74d69-ae54-4f40-bf00-11c08ec23e6d.png)
증명은 못 알아먹겠다. 생략.
Notation
Model
Per-data-point loss function
training set loss
![image](https://user-images.githubusercontent.com/16400591/193741794-72b896b8-f716-40bb-89be-b1ec6abf41c1.png)
population loss
![image](https://user-images.githubusercontent.com/16400591/193741878-b77185dd-bd75-4aa5-b8f7-4f2abef648d4.png)
SAM
population loss는 알 수 없으니 training set loss 로 이를 근사하고, optimizing 하는 게 일반적이다. 근데, sub-optimal 로 빠지기 쉽기 때문에 새로운 방식으로 SAM을 제시한다.
시작은 간소화된 PAC Bayesian Generalization Bound 이다.${\huge -L_S (w)+ L_S (w)}$ 를 중간 텀에 넣어주면, sharpness 와 train loss, regularization 을 뽑아낼 수 있다.
![image](https://user-images.githubusercontent.com/16400591/193770232-b4b20202-a8c0-4635-a602-a4dd0dd9ae7a.png)
간소화된 수식에
즉, train loss 에 regularaization 을 더해서 사용하는 일반적인 경우, sharpness 는 신경 안 쓰면서 PAC Learning 을 하고 있는 느낌.$\rho$ 값은 hyperparmeter 인데 (epsilon 의 크기), batch-size 에 민감해서 잘 조정해야 한다.
저자들은, Sharpness 와 regularziation term 을 활용하는 방향으로 학습을 진행시킨다.
여기서
Norm 차원 p 값은 2 를 사용하였다. (실험적으로 결정했다고 한다. appendix c.5)
아무튼 제시한 방법을 컴퓨터로 풀어내야 하니, 수식을 좀 더 전개를 해보자.
${\huge L_S (w+\epsilon)}$ 을 최대화 하는 ${\huge \epsilon}$ 을 ${\huge \epsilon^*}$ 이라 하자.
${\huge \epsilon}$ 값이 작기 때문에, 테일러 급수를 적용할 수 있고, ${\huge L_S (w)}$ 는 epsilon 에 무관한 값이니까, 제외시킨다.
![image](https://user-images.githubusercontent.com/16400591/193771316-44643cf0-b839-4163-a816-d237e9819fcd.png)
그러면, dual norm 문제가 하나 툭 튀어 나온다.
깔끔하게 풀어내면, 최종 Loss term 에 hessian term 이 더해진 형태가 나오게 된다.
Hessian 은 빼 버리는게 국룰.
알고리즘을 정리하면 다음과 같다.
![image](https://user-images.githubusercontent.com/16400591/193772781-f0f99bd1-6e82-410f-8862-9158293356de.png)
그림의 1, 2, 3 순으로
Results
batch size m 과 rho 값을 적당히 가져가는게 성능에 주요했다.
![image](https://user-images.githubusercontent.com/16400591/193773161-c754d263-8dda-493f-8ac4-aaf36b34ad1e.png)
second order 까지 실험을 했는데, first order 실험결과가 더 좋다. 이유는 저자들도 모르겠다고 한다.
![image](https://user-images.githubusercontent.com/16400591/193774467-cc8c6260-9a5a-4cea-8639-e8008966fb4b.png)
성능. 나쁘지 않다.
![image](https://user-images.githubusercontent.com/16400591/193775195-cffeff2b-8880-42e4-8b61-ddaf041ec53f.png)
![image](https://user-images.githubusercontent.com/16400591/193775310-de221a82-e566-4223-a492-f76f6540c17c.png)
augmentation 이 강해져도 효과가 있음을 보였다.
![image](https://user-images.githubusercontent.com/16400591/193775740-6a04c26b-6689-4d50-b227-b15f0093d61e.png)
The text was updated successfully, but these errors were encountered: