SlideShare a Scribd company logo
1 of 21
Download to read offline
Early Stopping as Nonparametric
Variational Inference
Duvenaud et al., in Proc. AISTATS, 2016
펀더멘털 팀: 김동희, 김창연, 이재윤
발표자: 송헌 (songheony@gmail.com)
요약00
• Stochastic Gradient Descent (SGD)를 Variational Bayesian Inference의 관점에서 해석
• 그 해석에 기반하여 validation data를 사용하지 않고 early stopping하는 방법을 제안
• overfitting에 강인한 최적화 알고리즘을 제안
Early stopping01
• 뉴럴넷은 overparameterized되어 있기 때문에 학습 데이터에 overfitting하기 쉬움
• 따라서 여러가지 기법들을 필요로 하는데, 학습을 도중에 그만두는 early stopping이 자주 사용됨
• Early stopping을 사용하기 위해서는 validation data를 이용하는게 일반적
Validation data에 대한 에러
Training data에 대한 에러
Early stopping
그림:
https://www.kaggle.com/fengdanye/m
achine-learning-2-regularized-lm-early-
stopping
Bayesian 해석01
• 여러 유명한 방법들은 베이지안 관점에서 해석되어 왔음
• Regularization = MAP inference
• Limiting model capacity = Bayesian Occam’s razor
• Cross-validation = Estimating marginal likelihood
• Dropout = Integrating out spike-and-slab
• Ensemble = Bayes model averaging
• 하지만 early stopping은 아직 베이지안 관점에서 해석되지 않았음
목표01
• Early stopping을 베이지안 관점에서 해석하고 싶음
• Validation data없이 early stopping을 하고 싶음
SGD의 해석01
• SGD는 뉴럴넷의 파라미터 𝜃를 학습 데이터 𝑥를 이용하여 업데이트를 진행
• 학습이 진행됨에 따라 점차 손실이 작아지는 방향으로 파라미터가 업데이트 되어짐
파라미터 공간에서
손실의 등고선
Loss
Loss
Loss
그림: Li et al, in Proc. NIPS, 2018.
SGD의 해석01
• SGD는 뉴럴넷의 파라미터 𝜃를 학습 데이터 𝑥를 이용하여 업데이트를 진행
• 학습이 진행됨에 따라 점차 손실이 작아지는 방향으로 파라미터가 업데이트 되어짐
랜덤한 초기값 150에폭 이후 300에폭 이후
시도 2시도 1
SGD의 해석01
• 저자는 SGD를 다음과 같은 방법으로 해석함
“학습 데이터가 제공됨에 따라 변하는 뉴럴넷의 사후분포 𝑝 𝜃 𝑥 로부터 파라미터 𝜃를 샘플링”
학습이 진행될수록
분포의 분산이 작아짐
랜덤한 초기값 150에폭 이후 300에폭 이후
Q & A
Variational Inference02
• 뉴럴넷은 너무 복잡하기 때문에 사후분포 𝑝 𝜃 𝑥 를 바로 계산하기는 쉽지 않음
𝑝 𝜃 𝑥 =
𝑝 𝑥 𝜃 𝑝 𝜃
𝑝 𝑥
• 이를 위해 더 간단한 분포 𝑞 𝜃 를 가정하고 두 분포의 KL divergence가 작아지도록 근사함
KL 𝑞 𝜃 ||𝑝 𝜃 𝑥 = Ε! log
𝑞 𝜃
𝑝 𝜃 𝑥
• 위 식을 정리하면 다음과 같은 관계를 얻게 됨
log 𝑝 𝑥 ≥ Ε! − log 𝑞 𝜃 − Ε! − log 𝑝 𝜃, 𝑥 = ELBO
• ELBO의 최대화는 KL divergence의 최소화와 같음
Entropy 𝑆[𝑞] Energy 𝐸[𝑞]Marginal likelihood
Variational Inference02
log 𝑝 𝑥 ≥ Ε! − log 𝑞 𝜃 − Ε! − log 𝑝 𝜃, 𝑥 = ELBO
• 결국 우리는 ELBO를 최대화 해야함
• 그러기 위해서는 높은 Entropy와 낮은 Energy를 얻어야 함
• Entropy가 낮으면 근사된 파라미터 분포 𝑞 𝜃 의 분산이 작음을 의미
반대로 높으면 근사된 파라미터 분포 𝒒 𝜽 의 분산이 큼을 의미
• Energy가 낮으면 뉴럴넷이 학습 데이터를 제대로 설명하지 못함을 의미
반대로 높으면 뉴럴넷이 학습 데이터를 잘 설명함을 의미
• 따라서 ELBO는 뉴럴넷의 underfitting과 overfitting의 tradeoff 관계를 나타냄
Entropy 𝑆[𝑞] Energy 𝐸[𝑞]
Entropy02
• 파라미터의 초기분포 𝑞" 𝜃 로부터 초기 파라미터 𝜃"가 샘플링 되며,
Transition operation 𝑇로 인해 iteration t에서는 파라미터 𝜃#가 되었다고 함
• Energy는 Ε!!
− log 𝑝 𝜃, 𝑥 ≈ − log 𝑝 𝜃#, 𝑥 가 되어
Negative Log Likelihood (NLL) 손실과 같아지므로 직접적으로 계산 가능
• Entropy는 직접적으로 계산이 불가능하지만, transition operation 𝑇의 Jacobian 𝐽 𝜃 로부터
초기분포의 Entropy 𝑆 𝑞" 를 알고 있다면 엔트로피의 차이로부터 계산 가능
𝑆 𝑞#$% = 𝑆 𝑞# + Ε!!
log 𝐽 𝜃#
• 따라서 iteration t에서의 ELBO는 다음과 같이 추론할 수 있음
ELBO 𝑞# ≈ :
&'"
#(%
log 𝐽 𝜃& + 𝑆 𝑞" + log 𝑝 𝜃#, 𝑥
SGD의 ELBO02
• 손실함수 𝐿 𝜃 을 사용하는 뉴럴넷의 SGD는 다음과 같이 나타남
𝜃# = 𝜃#(% − 𝛼∇𝐿 𝜃#
• 따라서 𝐿 𝜃 의 Hessian 𝐻 𝜃 을 이용하여 ELBO는 다음과 같이 나타남
ELBO 𝑞# ≈ :
&'"
#(%
log 𝐻 𝜃& + 𝑆 𝑞" + log 𝑝 𝜃#, 𝑥
• 이러한 ELBO를 관측하는 것으로 overfitting을 막을 수 있도록
early stopping을 하는 것이 가능해짐
• 비록 위의 ELBO는 매 에폭마다 동일한 순서로 학습 데이터가 주어져야 한다는 조건이 있지만,
다른 순서로 학습 데이터가 주어지더라도 marginal likelihood estimation로써 사용 가능
log 𝑝 𝑥 ≳ :
&'"
#(%
log 𝐻 𝜃& + 𝑆 𝑞" + log 𝑝 𝜃, 𝑥
NLL이 손실함수라면
𝐿 𝜃! = − log 𝑝 𝜃!, 𝑥
로 사용 가능
Entropy-friendly03
• SGD는 NLL 손실을 최소화 하는 것에만 초점이 맞춰져 있기 때문에,
학습이 진행될수록 Entropy는 결국 0에 가까워지게 됨
• 원하고자 하는 바는 marginal likelihood estimation을 최대화 하는 것
• 저자는 손실함수의 기울기가 작을 때는 아주 조금만 파라미터를 업데이트 해주는 방식을 제안
∇𝐿 𝜃#
) = ∇𝐿 𝜃# − 𝑔" tanh
∇𝐿 𝜃#
𝑔"
𝐻 𝜃#
) = 1 − cosh(*
∇𝐿 𝜃#
𝑔"
𝐻 𝜃#
• 즉 기울기 ∇𝐿 𝜃# 가 gradient threshold 𝑔"보다 충분히 작다면 ∇𝐿 𝜃#
) ≈ 𝐻 𝜃#
) ≈ 0이 됨
Entropy-friendly03
• 설계한 대로 충분히 학습이 진행되어도 일정 수준 이상의 엔트로피를 갖고 있으면서
어느정도 학습이 진행된 것을 알 수 있음
SGD Entropy-friendly SGD
Q & A
실험04
• 100개의 히든 유닛을 갖고 있는 한층의 히든 레이어 MLP를 사용함
• marginal likelihood estimation이 early stopping에 사용가능한지 확인하기 위하여
모델을 Boston housing dataset에 학습시킴
• SGD와 Entropy-friendly SGD의 차이를 확인하기 위하여
모델을 MNIST dataset에 학습시킴
• 어디까지나 아이디어가 실제로 사용 가능한지 확인하기 위한 간단한 실험을 진행
Early stopping04
• 테스트 데이터에 대한 에러가 커져가는 시점, 즉 overfitting이 일어나기 조금 전에
marginal likelihood의 lower bound가 최고점에 도달했음
• 이로부터 marginal likelihood estimation을 이용하면 validation data없이도
early stopping할 수 있을 것이라 예상됨
0 100 200 300 400 500
5
6
7
8
9
10
11
506E
7rain errRr
7est errRr
0 100 200 300 400 500
7raining iteratiRn
−28.6
−28.4
−28.2
−28.0
−27.8
−27.6
0arginallikelihRRd
0arg. likelihRRd estimate
Entropy-friendly04
• Gradient threshold를 바꿔가며 Entropy-friendly SGD을 이용하여 실험
• Entropy-friendly SGD는 SGD(gradient threshold = 0)에 비해서 성능 자체는 좋지 못했음
• 하지만 SGD에 비해서 더 높은 marginal likelihood estimation이 얻어졌음
0 1 3 10 30 100 300 1000
−0.8
−0.7
−0.6
−0.5
−0.4
−0.3
−0.2
7estLikelihood
7raining likelihood
7est likelihood
0 1 3 10 30 100 300 1000
Gradient threshold
−0.85
−0.80
−0.75
−0.70
−0.65
−0.60
0arginallikelihood
0arginal likelihood estimate
SGD
Limitation05
• 오직 하나의 샘플만으로 파라미터 분포를 근사하는 것은 높은 분산을 초래할 수 있음
→ 여러 초기값을 앙상블 하는 방법을 이용하면 해결 가능할 것이라 예상됨
• 학습이 진행됨에 따라 Entropy는 계속하여 작아질 것이고
따라서 marginal likelihood estimation도 계속하여 작아질 수 있음.
그렇다면, marginal likelihood estimation이 어떠한 값일때 early stopping 해야하는지 모름
→ 제안한 Entropy-friendly SGD와 같은 방법을 이용하여 Entropy가 너무 작아지지 않도록 보정
• 여러 정규화 항이나 모멘텀 같은 방법론들의 적용이 힘듦
Q & A

More Related Content

More from taeseon ryu

OpineSum Entailment-based self-training for abstractive opinion summarization...
OpineSum Entailment-based self-training for abstractive opinion summarization...OpineSum Entailment-based self-training for abstractive opinion summarization...
OpineSum Entailment-based self-training for abstractive opinion summarization...taeseon ryu
 
3D Gaussian Splatting
3D Gaussian Splatting3D Gaussian Splatting
3D Gaussian Splattingtaeseon ryu
 
Hyperbolic Image Embedding.pptx
Hyperbolic  Image Embedding.pptxHyperbolic  Image Embedding.pptx
Hyperbolic Image Embedding.pptxtaeseon ryu
 
MCSE_Multimodal Contrastive Learning of Sentence Embeddings_변현정
MCSE_Multimodal Contrastive Learning of Sentence Embeddings_변현정MCSE_Multimodal Contrastive Learning of Sentence Embeddings_변현정
MCSE_Multimodal Contrastive Learning of Sentence Embeddings_변현정taeseon ryu
 
LLaMA Open and Efficient Foundation Language Models - 230528.pdf
LLaMA Open and Efficient Foundation Language Models - 230528.pdfLLaMA Open and Efficient Foundation Language Models - 230528.pdf
LLaMA Open and Efficient Foundation Language Models - 230528.pdftaeseon ryu
 
Dataset Distillation by Matching Training Trajectories
Dataset Distillation by Matching Training Trajectories Dataset Distillation by Matching Training Trajectories
Dataset Distillation by Matching Training Trajectories taeseon ryu
 
Packed Levitated Marker for Entity and Relation Extraction
Packed Levitated Marker for Entity and Relation ExtractionPacked Levitated Marker for Entity and Relation Extraction
Packed Levitated Marker for Entity and Relation Extractiontaeseon ryu
 
MOReL: Model-Based Offline Reinforcement Learning
MOReL: Model-Based Offline Reinforcement LearningMOReL: Model-Based Offline Reinforcement Learning
MOReL: Model-Based Offline Reinforcement Learningtaeseon ryu
 
Scaling Instruction-Finetuned Language Models
Scaling Instruction-Finetuned Language ModelsScaling Instruction-Finetuned Language Models
Scaling Instruction-Finetuned Language Modelstaeseon ryu
 
Visual prompt tuning
Visual prompt tuningVisual prompt tuning
Visual prompt tuningtaeseon ryu
 
variBAD, A Very Good Method for Bayes-Adaptive Deep RL via Meta-Learning.pdf
variBAD, A Very Good Method for Bayes-Adaptive Deep RL via Meta-Learning.pdfvariBAD, A Very Good Method for Bayes-Adaptive Deep RL via Meta-Learning.pdf
variBAD, A Very Good Method for Bayes-Adaptive Deep RL via Meta-Learning.pdftaeseon ryu
 
Reinforced Genetic Algorithm Learning For Optimizing Computation Graphs.pdf
Reinforced Genetic Algorithm Learning For Optimizing Computation Graphs.pdfReinforced Genetic Algorithm Learning For Optimizing Computation Graphs.pdf
Reinforced Genetic Algorithm Learning For Optimizing Computation Graphs.pdftaeseon ryu
 
The Forward-Forward Algorithm
The Forward-Forward AlgorithmThe Forward-Forward Algorithm
The Forward-Forward Algorithmtaeseon ryu
 
Towards Robust and Reproducible Active Learning using Neural Networks
Towards Robust and Reproducible Active Learning using Neural NetworksTowards Robust and Reproducible Active Learning using Neural Networks
Towards Robust and Reproducible Active Learning using Neural Networkstaeseon ryu
 
BRIO: Bringing Order to Abstractive Summarization
BRIO: Bringing Order to Abstractive SummarizationBRIO: Bringing Order to Abstractive Summarization
BRIO: Bringing Order to Abstractive Summarizationtaeseon ryu
 

More from taeseon ryu (20)

VoxelNet
VoxelNetVoxelNet
VoxelNet
 
OpineSum Entailment-based self-training for abstractive opinion summarization...
OpineSum Entailment-based self-training for abstractive opinion summarization...OpineSum Entailment-based self-training for abstractive opinion summarization...
OpineSum Entailment-based self-training for abstractive opinion summarization...
 
3D Gaussian Splatting
3D Gaussian Splatting3D Gaussian Splatting
3D Gaussian Splatting
 
JetsonTX2 Python
 JetsonTX2 Python  JetsonTX2 Python
JetsonTX2 Python
 
Hyperbolic Image Embedding.pptx
Hyperbolic  Image Embedding.pptxHyperbolic  Image Embedding.pptx
Hyperbolic Image Embedding.pptx
 
MCSE_Multimodal Contrastive Learning of Sentence Embeddings_변현정
MCSE_Multimodal Contrastive Learning of Sentence Embeddings_변현정MCSE_Multimodal Contrastive Learning of Sentence Embeddings_변현정
MCSE_Multimodal Contrastive Learning of Sentence Embeddings_변현정
 
LLaMA Open and Efficient Foundation Language Models - 230528.pdf
LLaMA Open and Efficient Foundation Language Models - 230528.pdfLLaMA Open and Efficient Foundation Language Models - 230528.pdf
LLaMA Open and Efficient Foundation Language Models - 230528.pdf
 
YOLO V6
YOLO V6YOLO V6
YOLO V6
 
Dataset Distillation by Matching Training Trajectories
Dataset Distillation by Matching Training Trajectories Dataset Distillation by Matching Training Trajectories
Dataset Distillation by Matching Training Trajectories
 
RL_UpsideDown
RL_UpsideDownRL_UpsideDown
RL_UpsideDown
 
Packed Levitated Marker for Entity and Relation Extraction
Packed Levitated Marker for Entity and Relation ExtractionPacked Levitated Marker for Entity and Relation Extraction
Packed Levitated Marker for Entity and Relation Extraction
 
MOReL: Model-Based Offline Reinforcement Learning
MOReL: Model-Based Offline Reinforcement LearningMOReL: Model-Based Offline Reinforcement Learning
MOReL: Model-Based Offline Reinforcement Learning
 
Scaling Instruction-Finetuned Language Models
Scaling Instruction-Finetuned Language ModelsScaling Instruction-Finetuned Language Models
Scaling Instruction-Finetuned Language Models
 
Visual prompt tuning
Visual prompt tuningVisual prompt tuning
Visual prompt tuning
 
mPLUG
mPLUGmPLUG
mPLUG
 
variBAD, A Very Good Method for Bayes-Adaptive Deep RL via Meta-Learning.pdf
variBAD, A Very Good Method for Bayes-Adaptive Deep RL via Meta-Learning.pdfvariBAD, A Very Good Method for Bayes-Adaptive Deep RL via Meta-Learning.pdf
variBAD, A Very Good Method for Bayes-Adaptive Deep RL via Meta-Learning.pdf
 
Reinforced Genetic Algorithm Learning For Optimizing Computation Graphs.pdf
Reinforced Genetic Algorithm Learning For Optimizing Computation Graphs.pdfReinforced Genetic Algorithm Learning For Optimizing Computation Graphs.pdf
Reinforced Genetic Algorithm Learning For Optimizing Computation Graphs.pdf
 
The Forward-Forward Algorithm
The Forward-Forward AlgorithmThe Forward-Forward Algorithm
The Forward-Forward Algorithm
 
Towards Robust and Reproducible Active Learning using Neural Networks
Towards Robust and Reproducible Active Learning using Neural NetworksTowards Robust and Reproducible Active Learning using Neural Networks
Towards Robust and Reproducible Active Learning using Neural Networks
 
BRIO: Bringing Order to Abstractive Summarization
BRIO: Bringing Order to Abstractive SummarizationBRIO: Bringing Order to Abstractive Summarization
BRIO: Bringing Order to Abstractive Summarization
 

Early stopping as nonparametric variational inference

  • 1. Early Stopping as Nonparametric Variational Inference Duvenaud et al., in Proc. AISTATS, 2016 펀더멘털 팀: 김동희, 김창연, 이재윤 발표자: 송헌 (songheony@gmail.com)
  • 2. 요약00 • Stochastic Gradient Descent (SGD)를 Variational Bayesian Inference의 관점에서 해석 • 그 해석에 기반하여 validation data를 사용하지 않고 early stopping하는 방법을 제안 • overfitting에 강인한 최적화 알고리즘을 제안
  • 3. Early stopping01 • 뉴럴넷은 overparameterized되어 있기 때문에 학습 데이터에 overfitting하기 쉬움 • 따라서 여러가지 기법들을 필요로 하는데, 학습을 도중에 그만두는 early stopping이 자주 사용됨 • Early stopping을 사용하기 위해서는 validation data를 이용하는게 일반적 Validation data에 대한 에러 Training data에 대한 에러 Early stopping 그림: https://www.kaggle.com/fengdanye/m achine-learning-2-regularized-lm-early- stopping
  • 4. Bayesian 해석01 • 여러 유명한 방법들은 베이지안 관점에서 해석되어 왔음 • Regularization = MAP inference • Limiting model capacity = Bayesian Occam’s razor • Cross-validation = Estimating marginal likelihood • Dropout = Integrating out spike-and-slab • Ensemble = Bayes model averaging • 하지만 early stopping은 아직 베이지안 관점에서 해석되지 않았음
  • 5. 목표01 • Early stopping을 베이지안 관점에서 해석하고 싶음 • Validation data없이 early stopping을 하고 싶음
  • 6. SGD의 해석01 • SGD는 뉴럴넷의 파라미터 𝜃를 학습 데이터 𝑥를 이용하여 업데이트를 진행 • 학습이 진행됨에 따라 점차 손실이 작아지는 방향으로 파라미터가 업데이트 되어짐 파라미터 공간에서 손실의 등고선 Loss Loss Loss 그림: Li et al, in Proc. NIPS, 2018.
  • 7. SGD의 해석01 • SGD는 뉴럴넷의 파라미터 𝜃를 학습 데이터 𝑥를 이용하여 업데이트를 진행 • 학습이 진행됨에 따라 점차 손실이 작아지는 방향으로 파라미터가 업데이트 되어짐 랜덤한 초기값 150에폭 이후 300에폭 이후 시도 2시도 1
  • 8. SGD의 해석01 • 저자는 SGD를 다음과 같은 방법으로 해석함 “학습 데이터가 제공됨에 따라 변하는 뉴럴넷의 사후분포 𝑝 𝜃 𝑥 로부터 파라미터 𝜃를 샘플링” 학습이 진행될수록 분포의 분산이 작아짐 랜덤한 초기값 150에폭 이후 300에폭 이후
  • 10. Variational Inference02 • 뉴럴넷은 너무 복잡하기 때문에 사후분포 𝑝 𝜃 𝑥 를 바로 계산하기는 쉽지 않음 𝑝 𝜃 𝑥 = 𝑝 𝑥 𝜃 𝑝 𝜃 𝑝 𝑥 • 이를 위해 더 간단한 분포 𝑞 𝜃 를 가정하고 두 분포의 KL divergence가 작아지도록 근사함 KL 𝑞 𝜃 ||𝑝 𝜃 𝑥 = Ε! log 𝑞 𝜃 𝑝 𝜃 𝑥 • 위 식을 정리하면 다음과 같은 관계를 얻게 됨 log 𝑝 𝑥 ≥ Ε! − log 𝑞 𝜃 − Ε! − log 𝑝 𝜃, 𝑥 = ELBO • ELBO의 최대화는 KL divergence의 최소화와 같음 Entropy 𝑆[𝑞] Energy 𝐸[𝑞]Marginal likelihood
  • 11. Variational Inference02 log 𝑝 𝑥 ≥ Ε! − log 𝑞 𝜃 − Ε! − log 𝑝 𝜃, 𝑥 = ELBO • 결국 우리는 ELBO를 최대화 해야함 • 그러기 위해서는 높은 Entropy와 낮은 Energy를 얻어야 함 • Entropy가 낮으면 근사된 파라미터 분포 𝑞 𝜃 의 분산이 작음을 의미 반대로 높으면 근사된 파라미터 분포 𝒒 𝜽 의 분산이 큼을 의미 • Energy가 낮으면 뉴럴넷이 학습 데이터를 제대로 설명하지 못함을 의미 반대로 높으면 뉴럴넷이 학습 데이터를 잘 설명함을 의미 • 따라서 ELBO는 뉴럴넷의 underfitting과 overfitting의 tradeoff 관계를 나타냄 Entropy 𝑆[𝑞] Energy 𝐸[𝑞]
  • 12. Entropy02 • 파라미터의 초기분포 𝑞" 𝜃 로부터 초기 파라미터 𝜃"가 샘플링 되며, Transition operation 𝑇로 인해 iteration t에서는 파라미터 𝜃#가 되었다고 함 • Energy는 Ε!! − log 𝑝 𝜃, 𝑥 ≈ − log 𝑝 𝜃#, 𝑥 가 되어 Negative Log Likelihood (NLL) 손실과 같아지므로 직접적으로 계산 가능 • Entropy는 직접적으로 계산이 불가능하지만, transition operation 𝑇의 Jacobian 𝐽 𝜃 로부터 초기분포의 Entropy 𝑆 𝑞" 를 알고 있다면 엔트로피의 차이로부터 계산 가능 𝑆 𝑞#$% = 𝑆 𝑞# + Ε!! log 𝐽 𝜃# • 따라서 iteration t에서의 ELBO는 다음과 같이 추론할 수 있음 ELBO 𝑞# ≈ : &'" #(% log 𝐽 𝜃& + 𝑆 𝑞" + log 𝑝 𝜃#, 𝑥
  • 13. SGD의 ELBO02 • 손실함수 𝐿 𝜃 을 사용하는 뉴럴넷의 SGD는 다음과 같이 나타남 𝜃# = 𝜃#(% − 𝛼∇𝐿 𝜃# • 따라서 𝐿 𝜃 의 Hessian 𝐻 𝜃 을 이용하여 ELBO는 다음과 같이 나타남 ELBO 𝑞# ≈ : &'" #(% log 𝐻 𝜃& + 𝑆 𝑞" + log 𝑝 𝜃#, 𝑥 • 이러한 ELBO를 관측하는 것으로 overfitting을 막을 수 있도록 early stopping을 하는 것이 가능해짐 • 비록 위의 ELBO는 매 에폭마다 동일한 순서로 학습 데이터가 주어져야 한다는 조건이 있지만, 다른 순서로 학습 데이터가 주어지더라도 marginal likelihood estimation로써 사용 가능 log 𝑝 𝑥 ≳ : &'" #(% log 𝐻 𝜃& + 𝑆 𝑞" + log 𝑝 𝜃, 𝑥 NLL이 손실함수라면 𝐿 𝜃! = − log 𝑝 𝜃!, 𝑥 로 사용 가능
  • 14. Entropy-friendly03 • SGD는 NLL 손실을 최소화 하는 것에만 초점이 맞춰져 있기 때문에, 학습이 진행될수록 Entropy는 결국 0에 가까워지게 됨 • 원하고자 하는 바는 marginal likelihood estimation을 최대화 하는 것 • 저자는 손실함수의 기울기가 작을 때는 아주 조금만 파라미터를 업데이트 해주는 방식을 제안 ∇𝐿 𝜃# ) = ∇𝐿 𝜃# − 𝑔" tanh ∇𝐿 𝜃# 𝑔" 𝐻 𝜃# ) = 1 − cosh(* ∇𝐿 𝜃# 𝑔" 𝐻 𝜃# • 즉 기울기 ∇𝐿 𝜃# 가 gradient threshold 𝑔"보다 충분히 작다면 ∇𝐿 𝜃# ) ≈ 𝐻 𝜃# ) ≈ 0이 됨
  • 15. Entropy-friendly03 • 설계한 대로 충분히 학습이 진행되어도 일정 수준 이상의 엔트로피를 갖고 있으면서 어느정도 학습이 진행된 것을 알 수 있음 SGD Entropy-friendly SGD
  • 16. Q & A
  • 17. 실험04 • 100개의 히든 유닛을 갖고 있는 한층의 히든 레이어 MLP를 사용함 • marginal likelihood estimation이 early stopping에 사용가능한지 확인하기 위하여 모델을 Boston housing dataset에 학습시킴 • SGD와 Entropy-friendly SGD의 차이를 확인하기 위하여 모델을 MNIST dataset에 학습시킴 • 어디까지나 아이디어가 실제로 사용 가능한지 확인하기 위한 간단한 실험을 진행
  • 18. Early stopping04 • 테스트 데이터에 대한 에러가 커져가는 시점, 즉 overfitting이 일어나기 조금 전에 marginal likelihood의 lower bound가 최고점에 도달했음 • 이로부터 marginal likelihood estimation을 이용하면 validation data없이도 early stopping할 수 있을 것이라 예상됨 0 100 200 300 400 500 5 6 7 8 9 10 11 506E 7rain errRr 7est errRr 0 100 200 300 400 500 7raining iteratiRn −28.6 −28.4 −28.2 −28.0 −27.8 −27.6 0arginallikelihRRd 0arg. likelihRRd estimate
  • 19. Entropy-friendly04 • Gradient threshold를 바꿔가며 Entropy-friendly SGD을 이용하여 실험 • Entropy-friendly SGD는 SGD(gradient threshold = 0)에 비해서 성능 자체는 좋지 못했음 • 하지만 SGD에 비해서 더 높은 marginal likelihood estimation이 얻어졌음 0 1 3 10 30 100 300 1000 −0.8 −0.7 −0.6 −0.5 −0.4 −0.3 −0.2 7estLikelihood 7raining likelihood 7est likelihood 0 1 3 10 30 100 300 1000 Gradient threshold −0.85 −0.80 −0.75 −0.70 −0.65 −0.60 0arginallikelihood 0arginal likelihood estimate SGD
  • 20. Limitation05 • 오직 하나의 샘플만으로 파라미터 분포를 근사하는 것은 높은 분산을 초래할 수 있음 → 여러 초기값을 앙상블 하는 방법을 이용하면 해결 가능할 것이라 예상됨 • 학습이 진행됨에 따라 Entropy는 계속하여 작아질 것이고 따라서 marginal likelihood estimation도 계속하여 작아질 수 있음. 그렇다면, marginal likelihood estimation이 어떠한 값일때 early stopping 해야하는지 모름 → 제안한 Entropy-friendly SGD와 같은 방법을 이용하여 Entropy가 너무 작아지지 않도록 보정 • 여러 정규화 항이나 모멘텀 같은 방법론들의 적용이 힘듦
  • 21. Q & A