Instantly share code, notes, and snippets.

View compiling tensorflow c++ with opencv
cd path_tensorflow/tensorflow
# dependencies
bazel build --config=cuda --config=opt --config=monlithic
#without --config=monlithic may cause error lettting cv2::imread() return empty image.
View tensorflow compilation
1. can't find numpy header, tho can be imported from python2/3, fixed by sudo apt-get install python3-numpy
2. no mudule named enum(tracebacks from python), fixed by sudo apt-get install python-enum34 python-enum enum
3. no module named keras_applications/keras_preprocessing, fixed by pip/pip3 install --user keras_applications --no-deps
4. pip install keras_applications/preprocessing got error: no permission to create folder in .local/lib/python2.7, root cause, python2.7
owned by root, while python3.5 owned by myself(also root), fixed by changing ownership of python2.7 to myself, then pip install.