RGB2Gray, Canny Detector and html cleanup