Skip to content

Instantly share code, notes, and snippets.

@ChongyeWang
Created March 15, 2019 05:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ChongyeWang/fb1303db25765a5c0e8691d7d2ada99e to your computer and use it in GitHub Desktop.
Save ChongyeWang/fb1303db25765a5c0e8691d7d2ada99e to your computer and use it in GitHub Desktop.
import cv2
image = cv2.imread('images/input.jpg')
smaller = cv2.pyrDown(image)
larger = cv2.pyrUp(smaller)
cv2.imshow('Original', image )
cv2.imshow('Smaller ', smaller )
cv2.imshow('Larger ', larger )
cv2.waitKey(0)
cv2.destroyAllWindows()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment