calling CED in loop for edge detection. had to change CED to work with
stack images.