Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in Python by (50.2k points)

I know that there are 3 types of opencv:

opencv (the library from the OpenCV),

cv (the old library from the OpenCV) and

pyopencv with its predecessor ctypes-opencv.

What are the main differentiation and which one should I apply?

1 Answer

0 votes
by (108k points)

Please be informed that OpenCV has released two types of Python interfaces, one is the cv, and the other is cv2.

cv: In this type, all OpenCV data types are stored as such. For example, if you input any image, they are of format cvMat, same as in C++. For array, there are many methods like cvSet2D, cvGet2D in cv.

cv2: And this one is the latest version. In this, everything is delivered as NumPy objects like an array and native Python objects like lists, tuples, dictionary, etc. So due to this NumPy support, you can do any numpy procedure here. NumPy is a constant and fast array processing package. For example, if you input any image, a ndarray will get returned. 

Related questions

0 votes
1 answer
asked Mar 21, 2021 in Python by laddulakshana (12.7k points)
0 votes
1 answer
0 votes
2 answers

Browse Categories

...