I want to extract polygons(with different colors) from a doodle photo, but I have no idea how to implement it.