5 ms·
Colour Science for Python
- kelsolaar 12y agoWe have an introductory tutorial (http://colour-science.org/tutorial.php http://colour-science.org/tutorial.php) showcasing some features of the API and we have started some IPython Notebooks (http://nbviewer.ipython.org/github/colour-science/colour-ipython/blob/master/notebooks/colour.ipynb http://nbviewer.ipython.org/github/colour-science/colour-ipy...) to cover it deeply along with the theoretical aspect.
- foolrush 12y agoWonderful work. Any chance of a C or C++ implementation?
- jacobolus 12y agoThere are already C/C++ implementations of most of this, and Matlab implementations, if you go hunting around. If there’s something specific you need, some of the algorithms have some fiddly parts, but there’s not too much that’s fundamentally difficult to implement in any of them. Any particular part should only take a day or two to build for some one-off use case.
- mwfunk 12y agoThere are tons of them. OS X and Windows both have color management APIs as standard system components, and there are open source solutions for those and other OS's as well (http://www.littlecms.com http://www.littlecms.com for one).
- kelsolaar 12y agoI don't think so, like stated in the below comments, there are already quite a few implementation.
- gtaylor 12y agoShameless plug for python-colormath, which has been cooking since about 2008: http://python-colormath.readthedocs.org/ http://python-colormath.readthedocs.org/ Has a lot of the same conversions/comparisons/color spaces, excellent test coverage, and in my own biased opinion, pretty good documentation.
- jacobolus 12y agoOther than the silly British spelling of color, looks like great work! If you guys are ever in the SF Bay Area, shoot me a note and I’ll buy you a coffee. (For people looking for JavaScript implementations, I put a CIECAM02 implementation and some other stuff at https://github.com/jrus/chromatist https://github.com/jrus/chromatist)
- ezequiel-garzon 12y agoAre you serious about your remark about spelling? I must say it caught my attention, but why would it be silly?
- bostonpete 12y agoProbably because British people are silly -- John Cleese, Benny Hill, etc.
- clockworkelf 12y agoIt's silly because everybody knows Americans have a monopoly on the spelling of APIs. That was sarcasm.
- spamizbad 12y agoMost of the world's English speakers spell color w/o the u. (292 million Americans, 44 million Filipinos)
- billforsternz 12y agoI think you are forgetting one billion plus Indians.
- michaelmior 12y agoUs Canucks also enjoy an extra u here and there :)
- kelsolaar 12y agoActually, in the begining, the API was named "color" , I decided to go for "colour" because the CIE is using "colour" and not "color": http://eilv.cie.co.at/termlist?field_term_search_value_op=contains&field_term_search_value=colour http://eilv.cie.co.at/termlist?field_term_search_value_op=co...
- idunning 12y agoSee also the fantastic Color.jl, a Julia package with similar functionality. Makes very pretty IJulia notebooks! More info at https://github.com/JuliaLang/Color.jl https://github.com/JuliaLang/Color.jl or just run Pkg.add("Color") at your Julia REPL.
- StefanKarpinski 12y agoI'd be curious about a comparison of the capabilities and approaches of these two libraries. Color.jl got to be quite comprehensive almost by accident.
- kelsolaar 12y agoColor.jl is excellent! They have a few stuff we don't support like DIN99 colourspace related computations and colour deficiency support, on an other hand I think we have one of the largest dataset around, the features pages will give you a nice overview: http://colour-science.org/features.php http://colour-science.org/features.php
- AceJohnny2 12y agoI've been peripherally interested in colo[u]r science for a while, and as a software guy was amazed to discover the complexities of accurately describing and computing color across a not-so-wide range of devices (my LCD screen, your LCD screen, that projector, this printer...). For example, I was looking for a way to find "perceptual distance" between colours, since the standard RGB rainbow gives more space for green than, say, yellow. Turns out there are colour spaces for that: CIELAB and CIELUV! However, converting between these spaces and RGB is... fun. (also, a fun way to tick off your illustrator friends is to install F.Lux on their computer) Thank you for this great library!
- TheLoneWolfling 12y agoCIELAB is great. Even just being able to average colors is really useful.
- photojosh 12y agoI'm surprised how at how poorly documented colour profile conversion is. I'm using Django for a webapp that takes images from a bunch of sources and primarily in AdobeRGB, and using Pillow to do the colour profile conversion has been... interesting...
- kelsolaar 12y agoYeah, it's sadly true. I would also like to add that most of the publications are very highly priced which make them not easily accessible. I had to buy a few of them and an account on OSA for a few hundreds dollars.
- blt 12y agoimport colour as color