demo

## Project description

<script type="text/javascript" src="http://cdn.mathjax.org/mathjax/latest/MathJax.js?config=default"></script>

# Pytorch iAlgebra

Document|Paper|References

Pytorch iAlgebra is an interactive interpretation library for deep learning on Pytorch.

Pytorch iAlgebra provides an interactive frame for interpreting a group of deep leanring models using a set of interpretation methods.

## iAlgebra Operations

Operators

Identity

$$[\phi(x)]{i}=\frac{1}{d} \sum{k=0}^{d-1} \mathbb{E}{I{k}}\left[f\left(x_{I_{k} \cup{i}}\right)-f\left(x_{I_{k}}\right)\right]$$

Projection

$$\left[\Pi_{w}(x)\right]{i}=\left{\begin{array}{cc}{\frac{1}{|w|} \sum{k=0}^{|w|-1} \mathbb{E}{I{k}}\left[f\left(x_{I_{k} \cup{i}}\right)-f\left(x_{I_{k}}\right)\right]} & {i \in w} \ {0} & {i \notin w}\end{array}\right.$$

Selection $$\left[\sigma_{l}(x)\right]{i}=\left[\phi\left(x ; \bar{x}, f{l}\right)\right]_{i}$$

Join

$$\left[x \bowtie x^{\prime}\right]{i}=\frac{1}{2}\left([\phi(x ; \bar{x}, f)]{i}+\left[\phi\left(x^{\prime} ; \bar{x}, f\right)\right]_{i}\right)$$

Anti-Join

$$\left[x \diamond x^{\prime}\right]{i}=\left(\left[\phi\left(x ; x^{\prime}, f\right)\right]{i},\left[\phi\left(x^{\prime} ; x, f\right)\right]_{i}\right)$$

## Supportive DNN and Interpretation Models

DNN Models

Model Performance on dataset Mnist

Dataset Models
Mnist LeNet-L1 LeNet-L2
Accuracy 98.866% 99.020%

Model Performance on dataset Cifar10

Dataset Models
Cifar10 Vgg19 -L1 Vgg19-L2
Accuracy 98.866% 99.020%

Interpretation Methods

In detail, we implement the following interpretation methods as the identity in Pytorch-iAlgebra.

## Installation

Library dependencies for the Pytorch-iAlgebra. Before installation, you need to install these with

$pip install -r requirements.txt  Then Pytorch-iAlgebra can be installed by: $ pip install pytorch-ialgebra


## Project details

Uploaded py2 py3