The robustness of neural networks has been emphasized since some works discovered that small perturbations could cause misclassification. Various defense methods against adversarial attacks have been proposed, and adversarial training is one of the most effective. Adversarial training generates adversarial examples and learns such data so that models can classify adversarial examples accurately. Multiple steps of forward pass and backpropagation are necessary to generate adversarial examples, and it consumes enormous computation costs and latency. This work accelerates adversarial training by selective computation of features of which gradients are large. This work also proposes a fast gradient top-k method exploiting the distribution of exponents and selectively computes large gradients in FP32. Efficient hardware to support selective computation, exponent approximation, and gradient top-k is designed with a small overhead.
최근 적대적 공격에 대한 인공지능 신경망의 강건성에 대한 연구가 활발하게 진행되고 있다. 적대적 훈련은 현재까지 제시되었던 적대적 공격에 대한 방어방법 중 가장 효과적인 방법으로 알려져 있다. 적대적 훈련은 학습 과정에서 적대적 이미지를 데이터셋에 포함하여 학습을 진행하는 방법이다. 그 과정에서 적대적 이미지를 생성하기 위해서는 순전파와 역전파 연산을 반복하는데 이로 인해서 많은 연산 비용이 소모되고 오랜 시간이 걸리게 된다. 본 연구는 이를 해결하기 위해서 그래디언트의 절댓값이 큰 요소들을 추출하여 선택적으로 연산을 함으로써 연산량을 효과적으로 줄인다. 또한, 그래디언트의 큰 값을 취하기 위해서 부동소수점의 가수 부분을 이용한 효율적인 방법을 제시하고 역전파에서도 선택적인 연산을 적용한다. 이를 위해 선택적인 연산과 가수 부분 계산, 상위값 추출 알고리즘을 지원하는 효율적인 하드웨어를 제안한다.