0

I'm new to deep learning, so maybe this is a silly question...

Do any adjustments need to be made for applying Grad-CAM on CNNs that use a Global Average Pooling (GAP) layer right before fully connected ones?

I understand that the GAP layer aggregates the activations of an intermediate layer in order to produce a compact representation of the image, removing information regarding the features location. Is this an obstacle to grad-cam backpropagation?

I imagine that for a CNN that uses, for example, a Max Pooling layer followed by a Flatten layer, o Grad-CAM is capable of retriving the exact location of the relevant features.

I'm sorry if it is a silly doubt, but I couldn't find the answer for it anywhere.

Thanks in advance!

  • Why do you think a global max pooling layer would retrieve the exact location of relevant features? Also, max pooling layers could be made differentiable so backpropagation isn't a problem – Shubham Panchal Feb 06 '23 at 15:37
  • Actually, I was trying to say that I don't think that GAP can retrieve the feature location. Thus, would it be necessary to make some kind adjustment to apply Grad-CAM?

    I'm asking that because I have the impression that Grad-CAM, sometimes, highlights areas which are larger than necessary. I thought the GAP could be a reason

    Also, thanks for the "max pooling link", really interesting!

    – The New Guy Feb 08 '23 at 00:01

0 Answers0