Posts

Showing posts with the label pillow

Does PIL work with skimage?

Does PIL work with skimage? Why is is that when I do this: from skimage import feature, io from PIL import Image edges = feature.canny(blimage) io.imshow(edges) io.show() I get exactly what I want, that being the full edged-only image. But when I do this: edges = feature.canny(blimage) edges = Image.fromarray(edges) edges.show() I get a whole mess of random dots, lines and other things that have more resemble a Jackson Pollock painting than the image? Whats wrong, and how do I fix it such that I can get what I want through both methods? for full code, visit my Github here: https://github.com/Speedyflames/Image-Functions/blob/master/Image_Processing.py Check what kind of type skimage returns and select the corresponding mode in your argument to fromarray to make sure, there is no type-based error (which is likely). – sascha Jun 29 at 17:09 ...