Showing posts with label opencv-python. Show all posts
Showing posts with label opencv-python. Show all posts

opencv: Install opencv CentOS


sudo yum install opencv opencv-python opencv-devel-docs 

#OPTIONAL DEPENDENCIES:
sudo yum install -y python-devel gtk2-devel libdc1394-devel libv4l-devel ffmpeg-devel gstreamer-plugins-base-devel
sudo yum install -y libpng-devel libjpeg-turbo-devel jasper-devel openexr-devel libtiff-devel libwebp-devel
sudo yum install -y gcc  cmake  git gtk2-devel pkgconfig  numpy  ffmpeg

If your using virtual environment, copy the relevant cv files to the virtual environment.

 cp /usr/lib64/python2.7/site-packages/cv* .venv/lib/python2.7/site-packages/

Python contextlib for Timing Python code

If you've ever found yourself needing to measure the execution time of specific portions of your Python code, the `contextlib` module o...