In my code, I am creating an image as a RGB array (224 * 224 * 3).
This is how my image representation looks like:
[[[0.44861878 0.64972376 0.95801105], [0.44861878 0.64972376 0.95801105], [0.44861878 0.64972376 0.95801105], ..., [0.44861878 0.45082873 0.82475138], [0.44861878 0.45082873 0.83270718], [0.44861878 0.45082873 0.84066298]],, [[0.44861878 0.64972376 0.95801105], [0.44861878 0.64972376 0.95801105], [0.44861878 0.64972376 0.95801105], ..., [0.44861878 0.45082873 0.83270718], [0.44861878 0.45082873 0.83270718], [0.44861878 0.45082873 0.84066298]],, [[0.44861878 0.65767956 0.95801105], [0.44861878 0.64972376 0.95801105], [0.44861878 0.64972376 0.95801105], ..., [0.44861878 0.45082873 0.83270718], [0.44861878 0.45082873 0.83270718], [0.44861878 0.45082873 0.84066298]],, ...,, [[0.44861878 0.45082873 0.83270718], [0.44861878 0.45082873 0.82475138], [0.44861878 0.45082873 0.82475138], ..., [0.44861878 0.45082873 0.82475138], [0.44861878 0.45082873 0.82475138], [0.44861878 0.45082873 0.82475138]],, [[0.44861878 0.45082873 0.82475138], [0.44861878 0.45082873 0.82475138],...
now, when I use:
plt.imshow(image)
plt.show()
I am getting this image:
when I use :
image = np.asarray(image * 255, dtype=np.int)
PIL.Image.fromarray(image, "RGB").show()
I am getting :
Why can't I show the image using PIL?

