Skip to content

(School context) - Scilab implementation of the Canny edge detector.

Notifications You must be signed in to change notification settings

hiveship/canny-edge-detector

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Canny edge detector

Scilab implementation of the Canny edge detector during a school project.

The Canny edge detector is an edge detection operator that uses a multi-stage algorithm to detect a wide range of edges in images. It was developed by John F. Canny in 1986.

Among the edge detection methods developed so far, canny edge detection algorithm is one of the most strictly defined methods that provide good and reliable detection. Owing to its optimality to meet with the three criteria for edge detection and the simplicity of the process for implementation, it becomes one of the most popular algorithms for edge detection.

Steps

The Process of Canny edge detection algorithm can be broken down to 5 different steps:

  1. Apply Gaussian filter to smooth the image in order to remove the noise
  2. Compute the intensity gradients of the image
  3. Apply non-maximum suppression to get rid of spurious response to edge detection
  4. Apply double threshold to determine potential edges
  5. Track edge by hysteresis: Finalize the detection of edges by suppressing all the other edges that are weak and not connected to strong edges

Note that the hysteresis threshold can be changed: for a good value, pick something between 70% and 85%.

Warning

  • Possible issues if you use Scilab 64 bits (Scilab 32 bits preferred)
  • All the code, comments and the project report (PDF file provided in this repository) are written in French

How to use this code?

  • Run script in your Scilab env
    • Make sure you installed the SIVP lib (http://sivp.sourceforge.net/)
    • Take a look at the main function and do not hesitate to play with some parameters (original image, Gaussian mask and thresholds)

Example

input output

About

(School context) - Scilab implementation of the Canny edge detector.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages