Skip to content

PR: Ohno (2013) Correlated Colour Temperature Performance Improvements#951

Merged
KelSolaar merged 7 commits intodevelopfrom
feature/cct_optimisation
Mar 2, 2022
Merged

PR: Ohno (2013) Correlated Colour Temperature Performance Improvements#951
KelSolaar merged 7 commits intodevelopfrom
feature/cct_optimisation

Conversation

@KelSolaar
Copy link
Copy Markdown
Member

@KelSolaar KelSolaar commented Mar 1, 2022

Summary

This PR dramatically improves the performance of the Ohno (2013) CCT computations by use of caching and vectorised spectral conversion:

  • colour.uv_to_CCT_Ohno2013 is ~100x faster
  • colour.CCT_to_uv_Ohno2013 is ~425x faster

A definition that converts from CCT to CIE UCS colourspace uv chromaticity coordinates using Planck's Law has also been added:

  • colour.CCT_to_uv_Planck1900

Preflight

Code Style and Quality

  • Unit tests have been implemented and passed.
  • Mypy static checking has been run and passed.
  • Pre-commit hooks have been run and passed.
  • [N/A] New transformations have been added to the Automatic Colour Conversion Graph.
  • New transformations have been exported to the relevant namespaces, e.g. colour, colour.models.

Documentation

  • New features are documented along with examples if relevant.
  • The documentation is Sphinx and numpydoc compliant.

@KelSolaar KelSolaar added this to the v0.4.2 milestone Mar 1, 2022
@KelSolaar KelSolaar requested a review from a team March 1, 2022 08:10
@KelSolaar KelSolaar force-pushed the feature/cct_optimisation branch from 2534931 to 5acfcae Compare March 1, 2022 09:32
@KelSolaar KelSolaar force-pushed the feature/cct_optimisation branch from 5acfcae to f09af99 Compare March 2, 2022 00:12
@coveralls
Copy link
Copy Markdown

Coverage Status

Coverage decreased (-0.005%) to 99.891% when pulling f09af99 on feature/cct_optimisation into 7e4300a on develop.

@KelSolaar KelSolaar merged commit f2daff2 into develop Mar 2, 2022
@KelSolaar KelSolaar deleted the feature/cct_optimisation branch May 29, 2022 07:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants