Closed haoshuai714 closed 2 years ago
To obtain the gradcam for a sentence, we simply average the gradcams across all text tokens
Thanks!
Hi! Have you considered or empirically tested if the CLS token works as well for whole sentence visualization?
How to get the Visualize GradCam for Whole sentence?
Hi,Could you tell me how to get the Visualize GradCam for Whole sentence?
Hello! I want to produce Grad-CAM visualizations for Whole sentence. I have change ---->Compute GradCAM as follow: with torch.no_grad():
mask = text_input.attention_mask.view(text_input.attention_mask.size(0),1,-1,1,1)
How to get the Visualize GradCam for Whole sentence? Could you give me full code of Visualize GradCam for Whole sentence? (I do not similar to GradCam)