How to use PIL to isolate a shape of like-pixels and turn it into an outline of (x,y) data

Hi guys,

I'm a total noob with python and I need to isolate a shape in some pictures, and then get its outlines as (x,y) scatterplot data. I've been using PIL to grayscale and increase the contrast, but now I have a noisy, burry image like this: http://imgur.com/8YXszZt

How can I clean up this image with python and get the outline of the black shape to dimension?

Thanks for your time.

Posted Feb 21, 2016, 9:55 PM UTC

82
Loading comments…