Setup OpenCV With PyCharm Environment
Introduction:
If you love working on image processing and video analysis using python then you have come to the right place. Python is one of the key languages which is used to process videos and images.
Requirements for OpenCV:
- 32- or a 64-bit computer.
- Windows, macOS or Linux.
- Python 2.7, 3.4, 3.5 or 3.6.
PyCharm
PyCharm is a cross-platform IDE used in computer programming specifically for Python. The platform developed by JetBrains is mainly used in code analysis, graphical debugger etc… It supports web development with Django as well as Data Science with Anaconda.
Official Website: https://www.jetbrains.com/pycharm/
OpenCV
OpenCV (Open Source Computer Vision) is a computer vision library that contains various functions to perform operations on pictures or videos. It was initially built by Intel but later managed by Willow Garag, presently it is managed by Itseez. It is a cross-platform library which available for programming languages apart from python.
Steps to import OpenCV on PyCharm:
1) Go to the terminal option at the bottom of the IDE window.
2) The pip (package manager) can also be used to download and install OpenCV. To install OpenCV, just type the following command:
- Python3
pip install opencv - python |
3) Now simply import OpenCV in your python program in which you want to use image processing functions.
To check if OpenCV is correctly installed, just run the following program in PyCharm to perform a version check:
- Python3
import cv2 print ( "GeeksForGeeks" ) print ( "Your OpenCV version is: " + cv2.__version__) |
Output:
GeeksForGeeks Your OpenCV version is: 4.4.0
Last Updated on March 1, 2022 by admin