'Why converted images now shown as grayscale?

I am working on image compression problem, i want to convert the images from 3 channel to 1 channle , i used

tf.image.rgb_to_grayscale(img_data_array, name=None)

and its done with the convert as I want but the problem is when I want to show the converted image its not shown as gray scale its have a colors but different from the original ?

is this mean that the converts not working well ? how to be sure that the images are 100% gray scale ?

Check the images enter image description here



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source