I have compiled opencv from source. and used following flag to install install it in anaconda lib path
-DCMAKE_INSTALL_PREFIX=/opt/conda -DCMAKE_BUILD_TYPE=Release (blah blah)
after running make install
the opencv lib gets installed at /opt/conda/python/3.6/cv2.cpython-36m-x86_64-linux-gnu.so
which is a bit strange as I was expecting to be installed in /opt/conda/lib
directory. More importantly when I try to do import cv2
inside python terminal, I get a ModuleNotFoundError
error. OpenCV is also not showing in conda list
. Am I missing something here? Where should OpenCV be installed to get it imported in Ananconda ?
For completeness my LD_LIBRARY_PATH
and PATH
are given below:
LD_LIBRARY_PATH= /opt/conda/lib:/usr/local/nvidia/lib:/usr/local/nvidia/lib64
PATH=/opt/conda/bin:/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin