레이어 정규화 (Layer Normalization)
Layer Normalization
최신 심층 신경망을 학습시키는 것은 계산 비용이 매우 많이 듭니다. 학습 시간을 단축하는 한 가지 방법은 뉴런의 활성도를 정규화하는 것입니다. 최근 도입된 배치 정규화(Batch Normalization) 기법은 훈련 데이터의 미니 배치 전체에서 뉴런에 들어오는 입력 합의 분포를 이용하여 평균과 분산을 계산하고, 이를 통해 각 훈련 데이터에 대한 해당 뉴런의 입력 합을 정규화합니다. 이는 피드포워드 신경망의 학습 시간을 획기적으로 단축시킵니다. 그러나 배치 정규화의 효과는 미니 배치 크기에 의존적이며, 순환 신경망(RNN)에 이를 적용하는 방법은 명확하지 않습니다. 본 논문에서는 단일 훈련 데이터에 대해 한 층(layer)에 있는 모든 뉴런의 입력 합으로부터 정규화에 필요한 평균과 분산을 계산함으로써, 배치 정규화를 '레이어 정규화(Layer Normalization)'로 변환합니다. 배치 정규화와 마찬가지로 각 뉴런에 고유한 적응형 편향(bias)과 이득(gain)을 부여하며, 이는 정규화 이후 비선형 함수 적용 이전에 적용됩니다. 배치 정규화와 달리 레이어 정규화는 학습 시와 테스트 시에 정확히 동일한 연산을 수행합니다. 또한 각 타임 스텝마다 별도로 정규화 통계량을 계산하므로 순환 신경망에 적용하기도 간단합니다. 레이어 정규화는 순환 신경망의 은닉 상태(hidden state) 역학을 안정화하는 데 매우 효과적입니다. 실험 결과를 통해, 우리는 레이어 정규화가 기존에 발표된 기법들에 비해 학습 시간을 상당히 단축시킬 수 있음을 보입니다.
Training state-of-the-art, deep neural networks is computationally expensive. One way to reduce the training time is to normalize the activities of the neurons. A recently introduced technique called batch normalization uses the distribution of the summed input to a neuron over a mini-batch of training cases to compute a mean and variance which are then used to normalize the summed input to that neuron on each training case. This significantly reduces the training time in feed-forward neural networks. However, the effect of batch normalization is dependent on the mini-batch size and it is not obvious how to apply it to recurrent neural networks. In this paper, we transpose batch normalization into layer normalization by computing the mean and variance used for normalization from all of the summed inputs to the neurons in a layer on a single training case. Like batch normalization, we also give each neuron its own adaptive bias and gain which are applied after the normalization but before the non-linearity. Unlike batch normalization, layer normalization performs exactly the same computation at training and test times. It is also straightforward to apply to recurrent neural networks by computing the normalization statistics separately at each time step. Layer normalization is very effective at stabilizing the hidden state dynamics in recurrent networks. Empirically, we show that layer normalization can substantially reduce the training time compared with previously published techniques.
AI Analysis
Korean Summary
Key Innovations
- 배치 차원이 아닌 레이어 내의 은닉 유닛(Hidden Units) 차원에서 정규화 통계(평균, 분산)를 계산
- 미니 배치 크기에 구애받지 않고 동작 가능 (배치 크기가 1인 온라인 학습에도 적용 가능)
- 순환 신경망(RNN)의 각 타임스텝에 동일한 정규화 방식을 적용하여 히든 스테이트의 역동성을 안정화
- 전체 가중치 행렬의 스케일링 및 개별 데이터 샘플의 스케일링에 대한 불변성(Invariance) 특성 증명
Learning & Inference Impact
학습 과정에서 레이어 정규화는 가중치의 스케일에 영향을 받지 않는 특성 덕분에 학습률(learning rate) 설정에 더 유연하며, RNN과 같은 시퀀스 모델에서 그래디언트 흐름을 안정화시켜 학습 시간을 대폭 단축시킵니다. 추론(Inference) 과정에서의 가장 큰 장점은 배치 정규화와 달리 학습 시와 테스트 시의 계산 방식이 완전히 동일하다는 점입니다. 배치 정규화는 추론 시 훈련 데이터의 이동 평균(running average)을 사용해야 하지만, 레이어 정규화는 입력 데이터 자체의 통계만 사용하므로 복잡한 시퀀스 처리나 실시간 추론 환경에서 구현이 더 단순하고 명확합니다.
Technical Difficulty
Estimated implementation complexity based on methodology.