iMTE

SmoothGrad : removing noise by adding noise 내용 정리 [XAI-5] 본문

Deep learning study/Explainable AI, 설명가능한 AI

SmoothGrad : removing noise by adding noise 내용 정리 [XAI-5]

Wonju Seo 2021. 4. 15. 10:22

논문 제목 : SmoothGrad : removing noise by adding noise

논문 주소 : arxiv.org/abs/1706.03825

 

SmoothGrad: removing noise by adding noise

Explaining the output of a deep network remains a challenge. In the case of an image classifier, one type of explanation is to identify pixels that strongly influence the final decision. A starting point for this strategy is the gradient of the class score

arxiv.org

주요 내용 :

1) SmoothGrad 방법은 class score $S_c$ 의 입력 (이미지)에 대한 gradients를 계산하는 방법에서, 입력에 noise를 추가하는 방법이 핵심 아이디어이다. Noise를 추가하여 생성된 sensitivity map (saliency map, pixel attribution map, sensitivity map 을 지칭하는 말이다.) 을 average하여 최종 sensitivity map을 형성한다.

$$M_c (x) = \frac{\partial S_c (x)}{\partial x}$$

$$\hat M_c (x) = \frac{1}{n}\sum_1^n M_c (x+N(0,\sigma^2))$$

(Average는 smoothing effect가 있어, 입력에 noise를 주어 생성된 여러개의 sensitivity map을 average 하면 당연히 smoothing이 된다. 즉, sensitivity map에서 noise 같아 보이는 부분은 줄어들고, 오히려 주요하게 봐야하는 입력의 pixel은 더 부각이 되는 것이다.)

2) 기존에 gradient-based sensitivity map은 밑의 그림과 같이 눈으로 볼 때 주요 특징점이 부각되지 못하는 한계를 갖고 있다.

이에 대해서 저자는 입력 이미지를 살짝 변형시키고 gradient의 변화를 보았을 때, 눈으로 보거나 모델에서의 예측은 변함이 없었지만, gradient에 큰 변화가 있었다고 보고하였다. 밑의 그림은 왼쪽 이미지 ($x$)에서 오른쪽 이미지 ($x+\epsilon$)로 변화할 때, gradients의 변화를 확인하였다.

3) 결과를 확인해보자. 먼저, noise의 level (percentage = $\sigma/(x_max-x_min)$)에 따른 sensitivity map의 형성을 보면, 밑의 그림과 같다.

percentage가 10~20 %에서 sharp하면서도 smoothed된 sensitivity map을 얻을 수 있다고 저자는 보고하였다. 두번째로 sample size에 대해서 확인해보면, sample의 개수가 늘어날 수록 sensitivity map이 smoothing되는 것을 확인할 수 있다. (sample이 50개 초과인 경우 변화가 별로 없었다.)

4) 다른 sensitivity map 형성 알고리즘 방법과 비교할 때, SmoothGrad는 뛰어난 성능을 보여주었다. 밑의 그림을 확인하자.

Gradient만 볼 때에도 SmoothGrad가 더 좋은 visualization을 보여주었으며, Gradient X Image에서는 Gradient만 사용할 때보다 좀 더 선명한 visualization을 보여주었다.

5) 이후, discriminative한 능력에서도 SmoothGrad가 기존 방법보다 더 좋음을 설명하였고, SmoothGrad는 average를 취해주는 것이 모든 것이기에 다른 알고리즘과 함께 사용할 수 있음을 설명하고 개선된 결과를 보여주었다. 또한, training에 noise를 추가해서 학습시켰을 때, 보다 개선된 sensitivty map을 얻을 수 있었다고 저자는 보고하였다.

Comments