skeletonize question

Stéfan van der Walt stefan at sun.ac.za
Mon Dec 12 20:56:12 EST 2011


On Mon, Dec 12, 2011 at 5:13 PM, Tony Yu <tsyu80 at gmail.com> wrote:
>
> Strange: when I open "circles.png" using the matplotlib backend, I get a
> float32 array (with the white pixels equal to 0.00392157). With the PIL
> backend, I get a bool array (before your recent bug fix) or uint8 (after the
> fix). Are you not having the same issue with matplotlib?

While the bool type is fine (it's a black and white image), the pixel
order was completely messed up; try to display it!

In mpl, I see the same thing you do.  It is because matplotlib assumes
that all images with depth < 8 is 8-bit, and therefore returns 1/255
instead of 1.  Filed here:

https://github.com/matplotlib/matplotlib/pull/623

Cheers
Stéfan



More information about the scikit-image mailing list