Computer Vision

How to check OpenCV version

How to check OpenCV version

You can easily check the version of OpenCV with the following code. First, import the OpenCV library as cv2. I highly recommend you get the “Computer Vision: Models, Learning, and Inference Book” to learn Computer Vision.

How to convert pil image to NumPy array

How to convert PIL image to NumPy array

You can convert the PIL image to a NumPy array with the following code. If you want to learn Python, I highly recommend reading This Book. Output: <class ‘PIL.JpegImagePlugin.JpegImageFile’> <class ‘numpy.ndarray’> Free Learning Resources