coloria-dev/coloria
关于
:rainbow: Tools for color research
开发工具实测星标增长
- 24小时
- 0
- 7天
- 0
- 15天
- 0
- 1个月
- 正在收集历史
各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。
README.md
原文Tools for color research.
Coloria is a Python library for color science: color spaces, color appearance models, color difference formulas, chromatic adaptation transforms, and the experimental data to judge them by. All methods are fully vectorized, so they are fast on one color or a million.
Installation
Install Coloria from PyPI with
pip install coloria
Coloria needs a license to run. The first time you use it in a terminal, it offers to start a free 30-day trial, to take a license key you already have, or to buy one online. See Get started for the details.
Example
Average yellow and blue in sRGB and you get a mid gray. Do it in a perceptual space such as Oklab and you get the color you expected:
from coloria.cs import ColorCoordinates
c0 = ColorCoordinates([1.0, 1.0, 0.0], "srgb1") # yellow
c1 = ColorCoordinates([0.0, 0.0, 1.0], "srgb1") # blue
c0.convert("oklab")
c1.convert("oklab")
c2 = (c0 + c1) * 0.5
c2.convert("srgbhex", mode="clip")
print(c2.data)
#6cabc7
What's inside
![]() |
||
|---|---|---|
| The sRGB gamut in CIELAB | MacAdam ellipses in CIELAB | Gradients in Oklab |
- Color coordinates and spaces: XYZ, xyY, sRGB, CIELAB, CIELUV, DIN99, CAM02-UCS, CAM16-UCS, Jzazbz, ICtCp, proLab, Oklab, HCT and more
- Color appearance models: CIECAM02, CAM16, ZCAM
- Color difference formulas: CIE76, CIE94, CIEDE2000, CMC l:c
- Chromatic adaptation transforms: von Kries, Bradford, CAT02, CAT16 and more
- Illuminants and observers
- Gamut visualization and color gradients
- Experimental data: MacAdam, Luo-Rigg, Munsell, Ebner-Fairchild, Hung-Berns, Xiao, Fairchild-Chen
- API reference
Articles
- Algorithmic improvements for the CIECAM02 and CAM16 color appearance models, Nico Schlömer, 2018
- On the conversion from OSA-UCS to CIEXYZ, Nico Schlömer, 2019
Support
Write to [email protected].
探索相关项目
加载中…

