displaying image with imshow in python -
i construct image follows
import numpy im = numpy.zeros((100,100,3)) im[:,:,0] = rdata im[:,:,1] = gdata im[:,:,2] = bdata
when show data using imshow follows
imshow(im)
it not display correct result.
but if following
scipy.misc.imsave("temp.png",im) nimg = scipy.misc.imread("temp.png") imshow(nimg)
the image displayed correctly.
i not sure issue, there type problem, data mean normalized.
thanks
Comments
Post a Comment