convert grayscale to rgb python code example
Example 1: rgb to grayscale python
from PIL import Image
img = Image.open('image.png').convert('LA')
img.save('greyscale.png')
Example 2: convert grayscale to rgb python
backtorgb = cv2.cvtColor(gray,cv2.COLOR_GRAY2RGB)