Uttar Pradesh, India
Instagram
image

Introduction to OpenCV

OpenCV (Open Source Computer Vision Library) is released under a BSD license and so it’s free for both academic and commercial use. It has various interfaces or bindings for C++, Python and Java for supports multiple operating systems like Windows, Linux, Mac OS, iOS and Android. This section gives OpenCV for python binding. The OpenCV was designed for computational efficiency and with a strong focus on real-time computer vision applications. This library was written in an optimized C/C++ program, so that's why the library mostly takes advantage of multi-core processing. It's widely used for object detection and object tracking.

Installation Process :

Windows:

 Install using pip command

pip install numpy

pip install matplotlib

Linux / Mac:

First, you may need to install pip using this command " apt-get install python3-pip"

pip3 install numpy or apt-get install python3-numpy. 

pip3 install matplotlib or apt-get install python3-matplotlib.

apt-get install python3-OpenCV


Sample Code:
-------------------

First of all import the required libraries at the top

# Library Import 

import cv2
import matplotlib
from matplotlib import pyplot as plt
import numpy

#End of library import

# Read image file from Local....

image = cv2.imread('example.jpg',cv2.IMREAD_GRAYSCALE)


cv2.imshow('show image',image)


#
cv2.waitKey(0)
cv2.destroyAllWindows()


In my upcoming blog post, I will discuss the below topics in more depth.

1-GUI features in OpenCV

2-Image Processing in OpenCV

3-Video analysis

4-Object detection

5-Image processing functions inside OpenCV for Machine Learning

You can access my code on the GitHub repositoryClick here


Comments

Share your thoughts in the comments

Your email address will not be published. Required fields are marked *