I want to get a color palette of an RGB image in order to draw the histograms of distribution of each color
i I separated the RGB values of the image but i get stuck how to get the color palette
def separ(obj):
import numpy as np
data=np.asarray(obj)
#print(data)#v
b, g, r = data[:, :, 0], data[:, :, 1], data[:, :, 2] # tuple RGB np tab image
return b,g,r