[**中文**](./README_CN.md)
![](preview.png)
# InterpretDL: Interpretation of Deep Learning Models based on PaddlePaddle
InterpretDL, short for *interpretations of deep learning models*, is a model interpretation toolkit for [PaddlePaddle](https://github.com/PaddlePaddle/Paddle) models. This toolkit contains inplementations of many interpratation algorithms, including LIME, Grad-CAM, Integrated Gradients and more. Some SOTA and new interpretation algorithms are also implemented.
*InterpretDL is under active construction and all contributions are welcome!*
# Why InterpretDL
The increasingly complicated deep learning models make it impossible for people to understand their internal workings. Interpretability of black-box models has become the research focus of many talented researchers. InterpretDL provides a collection of both classical and new algorithms for interpreting models.
By utilizing these helpful methods, people can better understand why models work and why they don't, thus contributing to the model development process.
For researchers working on designing new interpretation algorithms, InterpretDL gives an easy access to existing methods that they can compare their work with.
# Demo
Interpretation algorithms give a hint of why a black-box model makes its decision.
The following table gives visualizations of several interpretation algorithms applied to the original image to tell us why the model predicts "bull_mastiff."
Original Image | Integrated Gradients | SmoothGrad | LIME | Grad-CAM
:--------------:|:-----------:|:-----------:|:-----------:|:-----------:
![](imgs/catdog.jpg)|![](imgs/catdog_ig.jpg)|![](imgs/catdog_sg.jpg)|![](imgs/catdog_lime.jpg)|![](imgs/catdog_gradcam.jpg)
For sentiment classfication task, the reason why a model gives positive/negative predictions can be visualized as follows.
![](imgs/sentiment.jpg)
# Contents
* [Why InterpretDL](#Why-InterpretDL)
* [Demo](#demo)
* [Installation](#Installation)
* [Pip installation](#pip-installation)
* [Developer installation](#developer-installation)
* [Documentation](#Documentation)
* [Usage Guideline](#Usage-Guideline)
* [Contribution](#Contribution)
* [Roadmap](#Roadmap)
* [Algorithms](#Algorithms)
* [Tutorials](#Tutorials)
* [Copyright and License](#Copyright-and-License)
# Installation
It requires the deep learning framework [paddlepaddle](https://www.paddlepaddle.org.cn/install/quick), versions with CUDA support are recommended.
## Pip installation
```bash
pip install interpretdl
# or with baidu mirror
pip install interpretdl -i https://mirror.baidu.com/pypi/simple
```
## Developer installation
```bash
git clone https://github.com/PaddlePaddle/InterpretDL.git
# ... fix bugs or add new features
python setup.py install
# welcome to propose pull request and contribute
```
# Documentation
Online link: [interpretdl.readthedocs.io](https://interpretdl.readthedocs.io/en/latest/interpretdl.html).
Or generate the docs locally:
```bash
git clone https://github.com/PaddlePaddle/InterpretDL.git
cd docs
make html
open _build/html/index.html
```
# Usage Guideline
All interpreters inherit the abstract class [`Interpreter`](https://github.com/PaddlePaddle/InterpretDL/blob/4f7444160981e99478c26e2a52f8e40bd06bf644/interpretdl/interpreter/abc_interpreter.py), of which `interpret(**kwargs)` is the function to call.
```python
# an example of SmoothGradient Interpreter.
import interpretdl as it
def paddle_model(data):
class_num = 1000
model = ResNet50()
logits = model.net(input=data, class_dim=class_num)
probs = fluid.layers.softmax(logits, axis=-1)
return probs
img_path = 'assets/deer.png'
sg = it.SmoothGradInterpreter(paddle_model, "assets/ResNet50_pretrained")
gradients = sg.interpret(img_path, visual=True, save_path='sg_test.jpg')
```
Details of the usage can be found under [tutorials](https://github.com/PaddlePaddle/InterpretDL/tree/master/tutorials) folder.
# Roadmap
We are planning to create a useful toolkit for offering the model interpretation.
## Algorithms
We are planning to implement the algorithms below (categorized into sensitivity interpreters and algorithmic interpreters):
- [x] LIME
- [x] FastNormLIME
- [x] NormLIME
- [x] LIMEPrior
- [x] SmoothGrad
- [x] Occlusion
- [ ] DeepLIFT
- [x] GradientSHAP
- [x] GradCAM
- [x] IntegratedGradients
- [ ] InfluenceFunction
- [x] ForgettingEvent
- [ ] SGDNoise
- [ ] More ...
## Tutorials
We plan to provide at least one example for each interpretation algorithm, and hopefully cover applications for both CV and NLP.
Current tutorials can be accessed under [tutorials](https://github.com/PaddlePaddle/InterpretDL/tree/master/tutorials) folder.
## References of Algorithms
* `IntegratedGraients`: [Axiomatic Attribution for Deep Networks, Mukund Sundararajan et al. 2017](https://arxiv.org/abs/1703.01365)
* `GradCAM`: [Grad-CAM: Visual Explanations from Deep Networks via Gradient-based Localization, Ramprasaath R. Selvaraju et al. 2017](https://arxiv.org/abs/1610.02391.pdf)
* `SmoothGrad`: [SmoothGrad: removing noise by adding noise, Daniel Smilkov et al. 2017](https://arxiv.org/abs/1706.03825)
* `GradientShap`: [A Unified Approach to Interpreting Model Predictions, Scott M. Lundberg et al. 2017](http://papers.nips.cc/paper/7062-a-unified-approach-to-interpreting-model-predictions)
* `Occlusion`: [Visualizing and Understanding Convolutional Networks, Matthew D Zeiler and Rob Fergus 2013](https://arxiv.org/abs/1311.2901)
* `Lime`: ["Why Should I Trust You?": Explaining the Predictions of Any Classifier, Marco Tulio Ribeiro et al. 2016](https://arxiv.org/abs/1602.04938)
* `NormLime`: [NormLime: A New Feature Importance Metric for Explaining Deep Neural Networks, Isaac Ahern et al. 2019](https://arxiv.org/abs/1909.04200)
* `ScoreCAM`: [Score-CAM: Score-Weighted Visual Explanations for Convolutional Neural Networks, Haofan Wang et al. 2020](https://arxiv.org/abs/1910.01279)
* `ForgettingEvents`: [An Empirical Study of Example Forgetting during Deep Neural Network Learning, Mariya Toneva et al. 2019](http://arxiv.org/abs/1812.05159)
# Copyright and License
InterpretDL is provided under the [Apache-2.0 license](https://github.com/PaddlePaddle/InterpretDL/blob/master/LICENSE).
没有合适的资源?快使用搜索试试~ 我知道了~
基于PaddleFL框架的联邦学习医疗影像识别系统源码+GUI界面(高分项目).zip
共132个文件
py:42个
less:14个
ipynb:14个
1.该资源内容由用户上传,如若侵权请联系客服进行举报
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
版权申诉
0 下载量 145 浏览量
2024-04-16
16:21:59
上传
评论
收藏 4.38MB ZIP 举报
温馨提示
基于PaddleFL框架的联邦学习医疗影像识别系统源码+GUI界面(高分项目).zip本资源中的源码都是经过本地编译过可运行的,资源项目的难度比较适中,内容都是经过助教老师审定过的能够满足学习、使用需求,如果有需要的话可以放心下载使用。 基于PaddleFL框架的联邦学习医疗影像识别系统源码+GUI界面(高分项目).zip本资源中的源码都是经过本地编译过可运行的,资源项目的难度比较适中,内容都是经过助教老师审定过的能够满足学习、使用需求,如果有需要的话可以放心下载使用。 基于PaddleFL框架的联邦学习医疗影像识别系统源码+GUI界面(高分项目).zip本资源中的源码都是经过本地编译过可运行的,资源项目的难度比较适中,内容都是经过助教老师审定过的能够满足学习、使用需求,如果有需要的话可以放心下载使用。 基于PaddleFL框架的联邦学习医疗影像识别系统源码+GUI界面(高分项目).zip本资源中的源码都是经过本地编译过可运行的,资源项目的难度比较适中,内容都是经过助教老师审定过的能够满足学习、使用需求,如果有需要的话可以放心下载使用。基于PaddleFL框架的联邦学习医疗影
资源推荐
资源详情
资源评论
收起资源包目录
基于PaddleFL框架的联邦学习医疗影像识别系统源码+GUI界面(高分项目).zip (132个子文件)
make.bat 795B
font-awesome.css 37KB
font-awesome.min.css 30KB
fontawesome-webfont.eot 162KB
.gitignore 307B
.gitignore 283B
report.html 3KB
report.html 2KB
lime_gp_tutorial_cv.ipynb 569KB
smooth_grad_tutorial_cv.ipynb 530KB
lime_tutorial_cv.ipynb 276KB
score_cam_tutorial_cv.ipynb 263KB
grad_cam_tutorial_cv.ipynb 262KB
grad_shap_tutorial_cv.ipynb 255KB
normlime_tutorial_cv.ipynb 237KB
int_grad_tutorial_cv.ipynb 208KB
forgetting_events_tutorial_cv.ipynb 131KB
occlusion_tutorial_cv.ipynb 55KB
normlime_tutorial_nlp.ipynb 21KB
lime_tutorial_nlp.ipynb 15KB
grad_shap_tutorial_nlp.ipynb 15KB
int_grad_tutorial_nlp.ipynb 15KB
0_with_bbox.jpg 7KB
0_with_bbox.jpg 7KB
1_with_bbox.jpg 6KB
1_with_bbox.jpg 6KB
0.jpg 5KB
0.jpg 5KB
1.jpg 5KB
1.jpg 5KB
icons.less 49KB
variables.less 22KB
mixins.less 2KB
path.less 771B
animated.less 713B
rotated-flipped.less 622B
bordered-pulled.less 585B
font-awesome.less 495B
stacked.less 476B
core.less 452B
list.less 377B
larger.less 370B
fixed-width.less 119B
screen-reader.less 118B
LICENSE 11KB
Makefile 634B
README.md 6KB
index.md 1KB
FontAwesome.otf 132KB
ChestCTFinding.png 546KB
report.png 539KB
20210210125944.png 124KB
20210210125138.png 116KB
serverControlFrame.png 40KB
serverFrame.png 38KB
clientFrame.png 34KB
testFrame.png 19KB
_normlime_base.py 18KB
gradient_shap.py 18KB
integrated_gradients.py 17KB
lime.py 17KB
serverControlFrame.py 16KB
testFrame.py 15KB
style.py 15KB
_lime_base.py 14KB
forgetting_events.py 13KB
testInterpreter.py 11KB
occlusion.py 11KB
clientFrame.py 10KB
model.py 8KB
serverFrame.py 8KB
resnet.py 8KB
gradient_cam.py 7KB
smooth_grad.py 7KB
readers.py 7KB
lime_prior.py 7KB
score_cam.py 7KB
paddle_utils.py 7KB
visualizer.py 6KB
MyFLUtils.py 6KB
file_utils.py 5KB
bilstm.py 4KB
_global_prior_base.py 4KB
client.py 3KB
abc_interpreter.py 3KB
reader.py 3KB
test_ct.py 3KB
server.py 2KB
conf.py 2KB
setup.py 2KB
test_client.py 1KB
__init__.py 1KB
test_server.py 473B
test_rt.py 345B
__init__.py 28B
train_local.py 0B
__init__.py 0B
__init__.py 0B
__init__.py 0B
qt_zh_CN(1).qm 115KB
共 132 条
- 1
- 2
资源评论
盈梓的博客
- 粉丝: 9298
- 资源: 2203
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- (源码)基于Spring Boot和Vue的高性能售票系统.zip
- (源码)基于Windows API的USB设备通信系统.zip
- (源码)基于Spring Boot框架的进销存管理系统.zip
- (源码)基于Java和JavaFX的学生管理系统.zip
- (源码)基于C语言和Easyx库的内存分配模拟系统.zip
- (源码)基于WPF和EdgeTTS的桌宠插件系统.zip
- (源码)基于PonyText的文本排版与预处理系统.zip
- joi_240913_8.8.0_73327_share-2EM46K.apk
- Library-rl78g15-fpb-1.2.1.zip
- llvm-17.0.1.202406-rl78-elf.zip
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功