PyTorch CNN Visualization Library - This is the base library we extended to visualize adversarial inputs. We used roughly 1k lines of this code written in Python, which mainly using the PyTorch library.
PyTorch pretrained AlexNet, VGG16, and ResNet50 - These are the pretrained models we used as a basis for our visualizations.
ImageNet - An image database containing millions of images labeled as one of 1000 classes.
The src
directory contains all the source and executable code for this project. GradientSaliency.ipynb
, LayerwiseRelevance.ipynb
, LayerCAM.ipynb
, ScoreCAM.ipynb
, and SmoothGrad.ipynb
are the files which included the modified library code used to produce each respective visualization.
AdversarialAccuracy.ipynb
contains the code used for assessing the model's ability to handle increasingly perturbed images.
adv_generation_inverted_image.ipynb
contains the code used for generating adversarial images, and producing inverted image visualizations.
img_diff_checker.ipynb
contains some exploratory code relating to analyzing absolute differences in image pixel values to understand where perturbations tend to be added.
[Final report slides]