티스토리 뷰
Paper/Representation
[Paper 리뷰] Wav2Vec: Unsupervised Pre-Training for Speech Recognition
feVeRin 2025. 3. 22. 09:07반응형
Wav2Vec: Unsupervised Pre-Training for Speech Recognition
- Raw audio representation을 학습하여 speech recognition에 unsupervised pre-training을 도입할 수 있음
- Wav2Vec
- Unlabled audio data를 기반으로 training 하고, resulting representation을 acoustic model training을 개선하는 데 사용
- Noise contrastive binary classification을 통해 simple multi-layer convolutional neural network를 optimize
- 논문 (INTERSPEECH 2019) : Paper Link
1. Introduction
- Speech recognition model은 large transcribed audio data를 요구함
- 한편으로 pre-training을 활용하면 labled data가 scarce 한 경우 general representation을 학습해 downstream task의 성능을 개선할 수 있음
- 특히 speech processing에서 pre-training은 emotion recognition, speaker identification, phoneme discrimination 등에 사용됨
- BUT, supervised speech recognition task에 대해서는 unsupervised representation이 사용되지 않음
- 한편으로 pre-training을 활용하면 labled data가 scarce 한 경우 general representation을 학습해 downstream task의 성능을 개선할 수 있음
-> 그래서 unsupervised pre-training을 활용해 speech recognition task를 개선한 Wav2Vec을 제안
- Wav2Vec
- Raw audio를 input으로 하여 speech recognition system에 input 되는 general representation을 compute 하는 convolutional neural network
- True future audio sample과 negatives를 distinguish 하는 contrastive loss를 활용
- Frame-wise phoneme classification을 뛰어넘는 learned representation을 적용하여 speech recognition system을 개선
- Raw audio를 input으로 하여 speech recognition system에 input 되는 general representation을 compute 하는 convolutional neural network
< Overall of Wav2Vec >
- Fully convolutional architecture와 unsupervised pre-training method에 기반하여 speech recognition을 개선
- 결과적으로 기존보다 뛰어난 recognition 성능을 달성
2. Method
- Input으로 audio signal이 주어지면 Wav2Vec은 주어진 signal context로부터 future sample을 predict 함
- 이를 위해서는 data distribution
를 accurately modeling 해야 함p(x) - 따라서 논문은 raw speech sample
를 lower temporal frequency에서 feature representationx 로 encoding 한 다음, density ratioz 를 implicitly modeling 함p(zi+k|zi...zi−r)/p(zi+k)
- 이를 위해서는 data distribution
- Model
- Wav2Vec은 raw audio signal을 input으로 사용하는 2개의 network를 활용함
- Encoder network는 audio signal을 latent space에 embed 하고 context network는 encoder의 multiple time step을 combine 하여 contextualized representation을 얻음
- 먼저 raw audio sample
가 주어지면, 5-layer convolutional network로 parameterize 된 encoder networkxi∈X 를 적용함f:X↦Z - 여기서 encoder layer는
의 kernel size와(10,8,4,4,4) 의 stride를 가짐(5,4,2,2,2) - Encoder output은 low frequency feature representation
로써, 16kHz audio의 30ms를 encode 하고 striding result는 10ms마다 representationzi∈Z 를 생성함zi
- 여기서 encoder layer는
- 다음으로 context network
를 encoder network output에 적용하여 multiple latent representationg:Z↦C 를 receptive field sizezi...zi−v 에 대한 single contextualized tensorv 로 mix 함ci=g(zi...zi−v)
- Context network는 kernel size 3, stride 1의 9-layer로 구성되고, total receptive field는 210ms - Encoder/Context network layer는 512 channel의 causal convolution, group normalization layer, ReLU nonlinearity로 구성됨
- 이때 각 sample에 대해 feature/temporal dimension을 모두 normalize 하고, input scaling과 offset에 invariant 한 normalization scheme을 선택해야 generalized representation을 얻을 수 있음 - 추가적으로 larger dataset training을 위해 12-layer로 구성된 larger context network를 사용하는 Wav2Vec-large model을 고려할 수 있음
- 이 경우 aggregator에 skip connection을 도입하여 사용하고, total receptive field는 810ms를 가짐

- Objective
- 논문은 propsal distribution
에서 추출한 distractor samplepn 와˜z -step future의 samplek 를 distinguish 하기 위해 model을 training 함zi+k - 즉, 각 step
에 대한 contrastive loss를 minimize 함:k=1,...,K
(Eq. 1)Lk=−∑T−ki=1(logσ(z⊤i+khk(ci))+λE˜z∼pn[logσ(−˜z⊤hk(ci))])
- : sigmoid function,σ(x)=1/(1+exp(−x)) : negatives 수λ
- :σ(z⊤i+khk(ci)) 가 true sample이 될 probabilityzi+k - 여기서 각 step
에 대해k 에 적용되는 step-specific affine transformationci 을 고려할 수 있음hk(ci)=Wkci+bk - 결과적으로 논문은 loss
를 optimize 하여 서로 다른 step size에 걸쳐 (Eq. 1)을 summation 함L=∑Kk=1Lk - 이때 각 audio sequence에서 distractor를 uniformly choosing 하여 10-negative examples를 sampling 한 다음, expectation을 approximate 함
- 즉,
를 sequence length라고 할 때,T pn(z)=1T
- Training 이후 log-mel filterbank 대신 context network에서 생성된 representation
를 acoustic model에 input 함ci
- 즉, 각 step
- Decoding
- Acoustic model output을 decoding 하기 위해 WSJ dataset에서만 train 된 language model을 고려할 수 있음
- 이를 위해 논문은 beam search decoder를 채택하여 (Eq. 2)를 maximize 하는 방식으로 context network
나 log-mel filter bank output으로부터 word sequence를 decode 함:c
(Eq. 2)maxyfAM(y|c)+αlogpLM(y)+β|y|−γ∑Ti=1[πi='|']
- : acoustic model,fAM : language modelpLM
- :π=π1,...,πL 의 charactery
- : 각각 language model weights, word penality, silence penaltyα,β,γ - WSJ를 decoding 하기 위해 hyperparameter를 tuning 하고 random search를 적용함
- Word-based language model의 경우 4000 beam size, 250 score threshold를 사용하고, character-based language model의 경우 1500 beam size, 40 score threshold를 사용함
- 이를 위해 논문은 beam search decoder를 채택하여 (Eq. 2)를 maximize 하는 방식으로 context network
3. Experiments
- Settings
- Dataset : TIMIT, WSJ
- Comparisons : DeepSpeech2
- Results
- Pre-Training for the WSJ Benchmark
- 전체적으로 Wav2Vec이 가장 우수한 성능을 보임

- 특히 더 많은 data에 대해 pre-training 하는 경우 더 나은 성능을 얻을 수 있음

- Pre-Training for TIMIT
- TIMIT dataset에 대해서도 Wav2Vec의 성능이 가장 우수함

- Ablations
- Negative sample 수는 최대 10 sample까지만 유용하고 그 이상은 성능 향상에 큰 영향을 주지 못함

frame의 crop size를 사용할 때 최적의 성능을 달성함150k

- 최대 12-step을 predicting ahead 하는 경우 최적의 성능을 달성할 수 있음

반응형