Safety Verification of Deep Neural Networks
Switch branches/tags
Nothing to show
Clone or download
Pull request Compare This branch is 95 commits ahead of xiaoweih:master.
Failed to load latest commit information.
Documents update Nov 12, 2017
MCTS update Nov 18, 2017
basics fix import numpy in basics/ Nov 15, 2017
configuration update Nov 18, 2017
data Add ImageNet Experimental Results (Original and Modified) Feb 5, 2018
networks update Nov 13, 2017
safety_check updage Nov 11, 2017 update Nov 14, 2017
LICENSE Initial commit Oct 16, 2016 update package versions in Feb 5, 2018
index.html test webpage Nov 4, 2016


NB: the software is currently under active development. Please feel free to contact the developer by email:

Together with the software, there are two documents in Documents/ directory, one is the theory paper and the other is an user manual. The user manual will be updated from time to time. Please refer to the documents for more details about the software.

(1) Installation:

To run the program, one needs to install the following packages:

       Python 2.7 
       conda install opencv numpy=1.13 scikit-image cvxopt  (need to install Anaconda first, see
       pip install stopit
       pip install keras==1.2.2 (Note: the software currently does not work well with Keras 2.x because of image dimension ordering problems, please use a previous 1.x version)
       pip install pySMT z3
       Note: there is some comparability problem on OpenCV. Please use version 2.4.*. 
       The z3 pacakge needs to be properly installed. You can follow the instruction:, or run the following commands (tested on Mac OS): 
       git clone
       cd z3
       python scripts/ --python
       cd build
       sudo make install

(2) Check the backend of Keras:

The backend of Keras needs to be changed by editing the ~/.keras/keras.json file :

"backend": "theano",
"image_dim_ordering": "th"

(3) Download dataset and network paramters.

   If you want to train a network for GTSRB, Please download the dataset file X.h5 file from to networks/ directory. For details on download networks and datasets for imageNet, please refer to the document.

(4) Usage:

Use the following command to call the program:


Please use the file '''' to set the parameters for the system to run.

Xiaowei Huang