为什么在 colorsys 包中将 rgb 转换为 hsl 时 rgb 值中的 r 不正确
why the r in rgb value is not correct when converting rgb to hsl in colorsys package
import colorsys
print(colorsys.rgb_to_hls(92/255, 137/255, 78/255))
[0.29378531 0.42156863 0.2744186]
饱和度(S)、明度(L)是正确的(据此website),但是色相应该是106,不知道哪里有问题?
colorsys.rgb_to_hls
的输出以每单位份数(0 到 1 之间)表示:
106/360=0.294
colorsys
函数的允许取值如下图:
import colorsys
print(colorsys.rgb_to_hls(92/255, 137/255, 78/255))
[0.29378531 0.42156863 0.2744186]
饱和度(S)、明度(L)是正确的(据此website),但是色相应该是106,不知道哪里有问题?
colorsys.rgb_to_hls
的输出以每单位份数(0 到 1 之间)表示:
106/360=0.294
colorsys
函数的允许取值如下图: