Created
March 17, 2016 22:11
-
-
Save RyanParsley/4e6a36c5d885e460a354 to your computer and use it in GitHub Desktop.
make an image black and white and draw a line on it. I'm not really sure why
This file contains hidden or 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 cv2 | |
| import numpy as np | |
| from matplotlib import pyplot as plt | |
| img = cv2.imread('watch.jpg',cv2.IMREAD_GRAYSCALE) | |
| plt.imshow(img, cmap = 'gray', interpolation = 'bicubic') | |
| plt.xticks([]), plt.yticks([]) # to hide tick values on X and Y axis | |
| plt.plot([200,300,400],[100,200,300],'c', linewidth=5) | |
| plt.show() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment