ThomasEhling / OpenCV_Operations

Series of operation on an image with the OpenCV library

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

OpenCV_Operations

Series of operation on an image with the OpenCV library. Assignment of the Computer Vision Class at IIT Chicago.

Use OpenCV "cv2" and Python 2.7

Implementation :

The image should be taken from computer file if a path is specified. If not, the image should be taken from the camera.

Whenever a key is entered, the image should be updated with the following operations :

  • i : reload original image
  • w : save the current modified image
  • g : convert to grayscale with OpenCv
  • G : convert to grayscale with a personnal implementation
  • c : cycle through color channels
  • s : convert to grayscale and smooth with openCV
  • S : convert to grayscale and smooth with a personnal implementation
  • d : downsample the image by 2
  • D : downsample the image by 2 and smooth it
  • x : convert to grayscale and apply x derivative filter
  • y : convert to grayscale and apply y derivative filter
  • m : convert to grayscale and show magnitude
  • p : convert to greyscale and plot gradient vectors
  • r : convert to greyscale an
  • ESC : quit the program

! the path to display the help file is relative and set to "../data/help_menu.png". Please do run the code in the provided folder architecture or do not use the help function.

About

Series of operation on an image with the OpenCV library


Languages

Language:Python 100.0%