All Projects → pikahhh → pytorch-smoothgrad

pikahhh / pytorch-smoothgrad

Licence: MIT license
SmoothGrad implementation in PyTorch

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to pytorch-smoothgrad

DINet
A dilated inception network for visual saliency prediction (TMM 2019)
Stars: ✭ 25 (-81.48%)
Mutual labels:  saliency-map
Stellargraph
StellarGraph - Machine Learning on Graphs
Stars: ✭ 2,235 (+1555.56%)
Mutual labels:  saliency-map
Deepgaze
Computer Vision library for human-computer interaction. It implements Head Pose and Gaze Direction Estimation Using Convolutional Neural Networks, Skin Detection through Backprojection, Motion Detection and Tracking, Saliency Map.
Stars: ✭ 1,552 (+1049.63%)
Mutual labels:  saliency-map
U-2-Net-Demo
Demonstration using Google Colab to show how U-2-NET can be used for Background Removal, Changing Backgrounds, Bounding Box Creation, Salient Feature Highlighting and Salient Object Cropping.
Stars: ✭ 132 (-2.22%)
Mutual labels:  saliency-map
CP-360-Weakly-Supervised-Saliency
CP-360-Weakly-Supervised-Saliency
Stars: ✭ 20 (-85.19%)
Mutual labels:  saliency-map
WhiteBox-Part1
In this part, I've introduced and experimented with ways to interpret and evaluate models in the field of image. (Pytorch)
Stars: ✭ 34 (-74.81%)
Mutual labels:  saliency-map
CS231n
My solutions for Assignments of CS231n: Convolutional Neural Networks for Visual Recognition
Stars: ✭ 30 (-77.78%)
Mutual labels:  saliency-map

SmoothGrad implementation in PyTorch

PyTorch implementation of SmoothGrad: removing noise by adding noise.

Vanilla Gradients SmoothGrad Guided backpropagation Guided SmoothGrad

And other techniques such as the following are implemented.

Download

git clone https://github.com/pkdn/pytorch-smoothgrad

Usage

Save the saliency maps using VanillaGrad, GuidedBackpropGrad, SmoothGrad, GuidedBackpropSmoothGrad.

python saliency.py --img <image-path>

Save the Grad-CAM image.

python grad_cam.py --img <image-path>

If you do not specify an image path, read the raccoon's data (scipy.misc.face()).

Requirements

  • PyTorch
  • torch-vision
  • numpy
  • scipy
  • OpenCV

Environment under Python 3.5.2 is tested.

Acknowledgments

This code is insipired by pytorch-grad-cam.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].