Function cannyEdgeDetector