boundary function

Find the boundary of a shape in a pixel set