A computational framework for colour metrics and colour space transforms
- Published
- Accepted
- Subject Areas
- Computer Vision, Graphics, Optimization Theory and Computation, Scientific Computing and Simulation, Software Engineering
- Keywords
- colour metrics, colour space, transform, object-oriented, python
- Copyright
- © 2016 Farup
- Licence
- This is an open access article distributed under the terms of the Creative Commons Attribution License, which permits unrestricted use, distribution, reproduction and adaptation in any medium and for any purpose provided that it is properly attributed. For attribution, the original author(s), title, publication source (PeerJ PrePrints) and either DOI or URL of the article must be cited.
- Cite this article
- 2016. A computational framework for colour metrics and colour space transforms. PeerJ PrePrints 4:e1700v1 https://doi.org/10.7287/peerj.preprints.1700v1
Abstract
An object-oriented computational framework for the transformation of colour data and colour metric tensors is presented. The main idea of the design is to represent the transforms between spaces as compositions of objects from a class hierarchy providing the methods for both the transforms themselves and the corresponding Jacobian matrices. In this way, new colour spaces can be implemented on the fly by transforming from any existing colour space, and colour data in various formats as well as colour metric tensors and colour difference data can easily be transformed between the colour spaces. This reduces what normally requires several days of coding to a few lines of code without introducing a significant computational overhead. The framework is implemented in the Python programming language.
Author Comment
This is a submission to PeerJ for review.
Supplemental Information
Python demo file, to be included as Figure 4
Figure 4: Small demo of the colour package.