Created
March 23, 2019 09:26
-
-
Save saurabhpal97/686befba7713f0c601cf96088cf3f195 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#import the required libraries | |
import numpy as np | |
import matplotlib.pyplot as plt | |
import cv2 | |
%matplotlib inline | |
image = cv2.imread('index.jpg') | |
#converting image to Gray scale | |
gray_image = cv2.cvtColor(image,cv2.COLOR_BGR2GRAY) | |
#plotting the grayscale image | |
plt.imshow(gray_image) | |
#converting image to HSV format | |
hsv_image = cv2.cvtColor(image,cv2.COLOR_BGR2HSV) | |
#plotting the HSV image | |
plt.imshow(hsv_image) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment