# Fooling Code
This is the code base used to reproduce the "fooling" images in the paper:
[Nguyen A](http://anhnguyen.me), [Yosinski J](http://yosinski.com/), [Clune J](http://jeffclune.com). ["Deep Neural Networks are Easily Fooled: High Confidence Predictions for Unrecognizable Images"](http://arxiv.org/abs/1412.1897). In Computer Vision and Pattern Recognition (CVPR '15), IEEE, 2015.
**If you use this software in an academic article, please cite:**
@inproceedings{nguyen2015deep,
title={Deep Neural Networks are Easily Fooled: High Confidence Predictions for Unrecognizable Images},
author={Nguyen, Anh and Yosinski, Jason and Clune, Jeff},
booktitle={Computer Vision and Pattern Recognition (CVPR), 2015 IEEE Conference on},
year={2015},
organization={IEEE}
}
For more information regarding the paper, please visit www.evolvingai.org/fooling
## Requirements
This is an installation process that requires two main software packages (included in this package):
1. Caffe: http://caffe.berkeleyvision.org
* Our libraries installed to work with Caffe
* Cuda 6.0
* Boost 1.52
* g++ 4.6
* Use the provided scripts to download the correct version of Caffe for your experiments.
* `./download_caffe_evolutionary_algorithm.sh` Caffe version for EA experiments
* `./download_caffe_gradient_ascent.sh` Caffe version for gradient ascent experiments
2. Sferes: https://github.com/jbmouret/sferes2
* Our libraries installed to work with Sferes
* OpenCV 2.4.10
* Boost 1.52
* g++ 4.9 (a C++ compiler compatible with C++11 standard)
* Use the provided script `./download_sferes.sh` to download the correct version of Sferes.
Note: These are patched versions of the two frameworks with our additional work necessary to produce the images as in the paper. They are not the same as their master branches.
## Installation
Please see the [Installation_Guide](https://github.com/anguyen8/opencv_contrib/blob/master/modules/dnns_easily_fooled/Installation_Guide.pdf) for more details.
## Usage
* An MNIST experiment (Fig. 4, 5 in the paper) can be run directly on a local machine (4-core) within a reasonable amount of time (around ~5 minutes or less for 200 generations).
* An ImageNet experiment needs to be run on a cluster environment. It took us ~4 days x 128 cores to run 5000 generations and produce 1000 images (Fig. 8 in the paper).
* [How to configure an experiment to test the evolutionary framework quickly](https://github.com/Evolving-AI-Lab/fooling/wiki/How-to-test-the-evolutionary-framework-quickly)
* To reproduce the gradient ascent fooling images (Figures 13, S3, S4, S5, S6, and S7 from the paper), see the [documentation in the caffe/ascent directory](https://github.com/anguyen8/opencv_contrib/tree/master/modules/dnns_easily_fooled/caffe/ascent). You'll need to download the correct Caffe version for this experiment using `./download_caffe_gradient_ascent.sh` script.
## Troubleshooting
1. If Sferes (Waf) can't find your CUDA and Caffe dynamic libraries
> Add obj.libpath to the wscript for exp/images to find libcudart and libcaffe or you can use LD_LIBRARY_PATH (for Linux).
2. Is there a way to monitor the progress of the experiments?
> There is a flag for printing out results (fitness + images) every N generations.
You can adjust the dump_period setting [here](https://github.com/Evolving-AI-Lab/fooling/blob/master/sferes/exp/images/dl_map_elites_images.cpp#L159).
3. Where do I get the pre-trained Caffe models?
> For AlexNet, please download on Caffe's Model Zoo.
> For LeNet, you can grab it [here](https://github.com/anguyen8/opencv_contrib/tree/master/modules/dnns_easily_fooled/model/lenet).
4. How do I run the experiments on my local machine without MPI?
> You can enable MPI or non-MPI mode by commenting/uncommenting a line [here](https://github.com/Evolving-AI-Lab/fooling/blob/master/sferes/exp/images/dl_map_elites_images_mnist.cpp#L190-L191). It can be simple eval::Eval (single-core), eval::Mpi (distributed for clusters).
没有合适的资源?快使用搜索试试~ 我知道了~
OpenCV3.4.0 vs2015 win64 + cmake编译生成的带opencv_contrib-3.4.0库文件(含...
共556个文件
hpp:299个
lib:96个
dll:88个
4星 · 超过85%的资源 需积分: 27 73 下载量 26 浏览量
2018-05-23
16:05:07
上传
评论 1
收藏 76.52MB 7Z 举报
温馨提示
1. 作为上一个资源的补充,OpenCV3.4.0 带opencv_contrib-3.4.0库文件(含SFM)相关lib/dll文件,include文件请自行从源码渠道下载。 适用于win7 vs2015 win64 2. 在使用时,请自行配置相关文件的路径。
资源推荐
资源详情
资源评论
收起资源包目录
OpenCV3.4.0 vs2015 win64 + cmake编译生成的带opencv_contrib-3.4.0库文件(含SFM模块) (556个子文件)
mnist_mean.binaryproto 3KB
opencv_imgproc340d.dll 54.92MB
opencv_imgproc340.dll 40.57MB
opencv_core340d.dll 19.68MB
opencv_ffmpeg340_64.dll 16.99MB
opencv_ffmpeg340_64.dll 16.99MB
opencv_sfm340d.dll 12.52MB
opencv_core340.dll 12.46MB
opencv_dnn340d.dll 11.69MB
opencv_imgcodecs340d.dll 5.98MB
opencv_calib3d340d.dll 4.87MB
opencv_xfeatures2d340d.dll 4.39MB
opencv_tracking340d.dll 4.02MB
opencv_dnn340.dll 3.91MB
opencv_ximgproc340d.dll 3.37MB
opencv_xfeatures2d340.dll 2.87MB
opencv_imgcodecs340.dll 2.73MB
opencv_stitching340d.dll 2.68MB
opencv_features2d340d.dll 2.47MB
opencv_rgbd340d.dll 2.32MB
opencv_tracking340.dll 2.18MB
opencv_face340d.dll 2.14MB
opencv_calib3d340.dll 2.08MB
opencv_photo340d.dll 1.98MB
opencv_text340d.dll 1.94MB
opencv_ml340d.dll 1.82MB
opencv_sfm340.dll 1.73MB
opencv_xphoto340d.dll 1.68MB
opencv_objdetect340d.dll 1.68MB
opencv_datasets340d.dll 1.66MB
opencv_ccalib340d.dll 1.65MB
opencv_flann340d.dll 1.55MB
opencv_videostab340d.dll 1.49MB
opencv_optflow340d.dll 1.4MB
opencv_surface_matching340d.dll 1.38MB
opencv_ximgproc340.dll 1.37MB
opencv_aruco340d.dll 1.36MB
opencv_line_descriptor340d.dll 1.1MB
opencv_video340d.dll 1.09MB
opencv_stitching340.dll 1.07MB
opencv_photo340.dll 988KB
opencv_saliency340d.dll 940KB
opencv_features2d340.dll 863KB
opencv_shape340d.dll 860KB
opencv_bgsegm340d.dll 841KB
opencv_face340.dll 813KB
opencv_videoio340d.dll 800KB
opencv_ml340.dll 798KB
opencv_bioinspired340d.dll 783KB
opencv_rgbd340.dll 781KB
opencv_structured_light340d.dll 746KB
opencv_superres340d.dll 745KB
opencv_ccalib340.dll 742KB
opencv_stereo340d.dll 728KB
opencv_xobjdetect340d.dll 728KB
opencv_dpm340d.dll 711KB
opencv_reg340d.dll 679KB
opencv_text340.dll 677KB
opencv_xphoto340.dll 668KB
opencv_datasets340.dll 657KB
opencv_videostab340.dll 643KB
opencv_objdetect340.dll 601KB
opencv_aruco340.dll 559KB
opencv_img_hash340d.dll 554KB
opencv_optflow340.dll 541KB
opencv_highgui340d.dll 527KB
opencv_fuzzy340d.dll 526KB
opencv_flann340.dll 519KB
opencv_phase_unwrapping340d.dll 517KB
opencv_video340.dll 505KB
opencv_surface_matching340.dll 472KB
opencv_plot340d.dll 420KB
opencv_bioinspired340.dll 343KB
opencv_bgsegm340.dll 343KB
opencv_line_descriptor340.dll 336KB
opencv_saliency340.dll 327KB
opencv_shape340.dll 326KB
opencv_stereo340.dll 305KB
opencv_superres340.dll 302KB
opencv_videoio340.dll 281KB
opencv_structured_light340.dll 280KB
opencv_reg340.dll 267KB
opencv_xobjdetect340.dll 233KB
opencv_dpm340.dll 230KB
opencv_fuzzy340.dll 214KB
opencv_img_hash340.dll 209KB
opencv_highgui340.dll 196KB
opencv_phase_unwrapping340.dll 164KB
opencv_plot340.dll 152KB
.gitignore 248B
core_c.h 131KB
types_c.h 61KB
imgproc_c.h 52KB
kmeans_index.h 37KB
videoio_c.h 36KB
dist.h 28KB
hierarchical_clustering_index.h 26KB
autotuned_index.h 21KB
kdtree_single_index.h 20KB
calib3d_c.h 20KB
共 556 条
- 1
- 2
- 3
- 4
- 5
- 6
资源评论
- 交大雨声2018-12-04资源感觉不对,缺少文件
- haolinyu08012018-12-28下载过一次,重新下载
forrest2009
- 粉丝: 14
- 资源: 10
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功