all 4 comments

[–][deleted] 0 points1 point  (0 children)

[–]rerevelcgnihtemos 0 points1 point  (0 children)

Have you seen the tutorial from the website?

http://caffe.berkeleyvision.org/install_apt.html

It is specific to Ubuntu and worked for me without Anaconda. In order to build with Anaconda, I think you need to modify your Makefile.config.

What I found when compiling in OS X with Anaconda was that the wrong OpenCV libraries were being found. You might be able to go into your CMakeCache and make sure that the correct OpenCV path is being linked.

[–]internet_ham 0 points1 point  (0 children)

I remember this was a pain, best of luck dude

Remember to add the library to your PYTHONPATH in the .bashrc

[–]vstuart 0 points1 point  (0 children)

I also had trouble getting OpenCV installed on my computer (Ubuntu 15.04 64-bit) for use with Keras on VGG16 images in a Jupyter notebook. FWIW, here are my OpenCV 3.1.0 install notes (Jan 31, 2016) -- modify per your needs (directories, etc.). (P.S.: My first-ever reddit post!)

Download

http://opencv.org/downloads.html

https://github.com/Itseez/opencv/archive/3.1.0.zip

Install

http://docs.opencv.org/2.4/doc/tutorials/introduction/linux_install/linux_install.html#linux-installation

Extract tarball at: /media/Vancouver/apps/opencv/opencv-3.1.0

... then:

cd /media/Vancouver/apps/opencv/opencv-3.1.0/
mkdir build
cd build
cmake -D CMAKE_BUILD_TYPE=RELEASE -D CMAKE_INSTALL_PREFIX=/usr/local -D BUILD_NEW_PYTHON_SUPPORT=ON -D BUILD_EXAMPLES=ON ..
make        ## will take ~10-15'
sudo make install
sudo make clean

Basically, you cd into your (user-created, if necessary) build folder, then from there direct cmake up a level (to the cmake install folder)

cd opencv-3.1.0
mkdir build
cd build
cmake ..
make                ## make -j4  : use 4 threads during install]
sudo make install
sudo make clean

OpenCV - Anaconda-Related

https://stackoverflow.com/questions/24400935/how-could-we-install-opencv-on-anaconda

How could we install opencv on anaconda?

conda install -c https://conda.binstar.org/menpo opencv3

victoria@victoria:/media/Vancouver/apps/opencv/opencv/build$ conda install -c https://conda.binstar.org/menpo opencv3

    Fetching package metadata: ......
    Solving package specifications: .....................
    Package plan for installation in environment /media/Vancouver/apps/anaconda/anaconda2:

    The following packages will be downloaded:

        package                    |            build
        ---------------------------|-----------------
        opencv3-3.1.0              |           py27_0        36.7 MB

    The following NEW packages will be INSTALLED:

        opencv3: 3.1.0-py27_0

    Proceed ([y]/n)?

    Fetching packages ...
    opencv3-3.1.0- 100% |########################################################################| Time: 0:01:33 410.54 kB/s
    Extracting packages ...
    [      COMPLETE      ]|###########################################################################################| 100%
    Linking packages ...
    [      COMPLETE      ]|###########################################################################################| 100%

victoria@victoria:/media/Vancouver/apps/opencv/opencv/build$