I have a gray scale image of type uint16
, size = (256,256)
ndarray object
I want to use PIL to resize it to (75,75) but it requires the input to be of Image type.
How can I convert image of ndarray object
into Image
type to use image.resize((75,75), Image.ANTIALIAS)
NOTE:
I know I can read
image using Image.open
if it is saved, but my image is obtained after some image processing steps and is not read from disk
UPDATE: I am trying to provide image that I have :
import scipy.misc
scipy.misc.imsave('image.png', box_img)
# read this similar format image of type ndarray
image = scipy.ndimage.imread('image.png')
# convert it to Image type
The image
attached when read of similar type as I need.
I need to convert this image
into Image
type
Thanks,
Gopi