Skip to content

Implementing algorithms based on the analysis of the gradients in NN computational graphs to provide nice insights for Explainable AI

License

Notifications You must be signed in to change notification settings

Engrima18/ExaplainNET

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ExaplainNET

The main purpose of this study is the implementation of various explainable AI techniques. An attempt will then be made to replicate via code the analyses reported in the suggested scientific papers.

To do so, I will use of a data set from Kaggle consisting of color (RGB) microscope images of pollen grains, specifically divided into 23 classes and the main task of the neural network will be to correctly classify these images.

sample_images

Instructions

Open the notebook in colab and follow the instructions you will find in the markdown cells at the beginning Open In Colab .

In the jupyter file are defined all the functions for the proper obtaining of the results and the deep learning models needed for the image classification task. In this case I opted for a simple CNN achieving the following performances:

nn_performances

Please, for a more complete understanding of the results, read the colab notebook or the report.ipynb file in this repository.

Main findings

In practice, the used techniques will consist of assigning a certain weight to the features (in this case pixels) of an example in our data set based on some manipulation of the gradients in the computational graph of the network.

The first technique is the Saliency Map and its capped version for a better visualization.

saliency_map_analysis

Then I reported the more interesting Smooth gradient technique. I started from the selection of best combination of hyperparameters.

noise_vs_samples

Finally I got better results compared to the Saliency map method.

smooth_grad_analysis

Finally the Integrated gradients technique seems to overperfrom all the other algorithms.

integrated_grad_analysis

Used technologies

Python TensorFlow NumPy Plotly Jupyter Notebook

About

Implementing algorithms based on the analysis of the gradients in NN computational graphs to provide nice insights for Explainable AI

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published