Advertisement
Guest User

Untitled

a guest
Mar 27th, 2017
45
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.43 KB | None | 0 0
  1. import colour
  2.  
  3. illuminant = colour.ILLUMINANTS['cie_2_1931']['D65']
  4. RGB = [[1.0, 0.0, 0.0],
  5. [0.0, 1.0, 0.0],
  6. [0.0, 0.0, 1.0],
  7. [1.0, 1.0, 0.0]]
  8.  
  9. XYZ = colour.sRGB_to_XYZ(RGB)
  10. Luv = colour.XYZ_to_Luv(XYZ, illuminant)
  11. print(Luv)
  12.  
  13. [[ 53.23288179 175.05983019 37.76179061]
  14. [ 87.73703347 -83.0685535 107.41996534]
  15. [ 32.30258667 -9.3957447 -130.35155921]
  16. [ 97.13824698 7.71536065 106.8097148 ]]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement