Update 'README.md'

This commit is contained in:
H.T. Kruitbosch 2018-01-18 08:59:57 +00:00
parent 71cafe7842
commit 6d4c981cf9

View File

@ -1,5 +1,26 @@
# GPU / CPU Benchmarks for tensorflow and keras # GPU / CPU Benchmarks for tensorflow and keras
The benchmarks run on all the devices that tensorflow finds. If that should include a GPU, make sure to install the python egg `tensorflow-gpu`, also make sure the nvidia kernel module has the version supported by your cuda installation, in my case I needed the ubuntu-package `nvidia-384==384.111-0ubuntu1` (the 111-part also has to match). You'll see an error message in the **console** (not the notebook) when importing tensorflow and the versions mismatch. Also make sure cuda is in your `LD_LIBRARY_PATH`, in my case `/usr/local/cuda-8.0/targets/x86_64-linux/lib/` for the ubuntu package `cuda-8.0`, the folder should contain object files like `libcudnn.so` ('updatedb' and `locate libcuda.so` to find such a folder on your linux system).
The first benchmark tests matrix multiplication in tensorflow
[Matrix multiplication benchmark](01.%20Matrix%20Multiplication.ipynb) Run the benchmarks preferrably in a virtualenv with `python>=3.4,<4`
virtualenv --python=/usr/bin/python3 gpubenchmark
source gpubenchmark/bin/activate
pip3 install numpy scipy tensorflow-gpu keras jupyter
jupyter-notebook # starts a http-server
instead of running `jupyter-notebook`, you can also make python-scripts.
## Experiments
Benchmark for matrix multiplication in tensorflow
[Matrix multiplication benchmark](01.%20Matrix%20multiplication.ipynb)
Benchmark for training and predicting on a 5-layer neural network in keras+tensorflow
[4-layer Dense Neural Network](02.%20Simple%20Neural%20Network%20training%20+%20evaluation.ipynb)
Benchmarks for predictions using ResNet50, Inception v3, VGG16 and VGG19
[Popular deep learning models](03.%20Popular%20image%20classification%20models.ipynb)