Skip to content

Commit

Permalink
PR: Last Stretch for RC1 (#76)
Browse files Browse the repository at this point in the history
* Last stretch for rc1!

Signed-off-by: Thomas Mansencal <thomas.mansencal@gmail.com>

* Update "README.rst" file and documentation.

Signed-off-by: Thomas Mansencal <thomas.mansencal@gmail.com>

* Drop "Python 3.8" requirement.

Signed-off-by: Thomas Mansencal <thomas.mansencal@gmail.com>

* Update "requirements.txt" file.

Signed-off-by: Thomas Mansencal <thomas.mansencal@gmail.com>

* Address code review notes.

Signed-off-by: Thomas Mansencal <thomas.mansencal@gmail.com>

* Use "SVG" for graph image, reducing energy consumption.

Signed-off-by: Thomas Mansencal <thomas.mansencal@gmail.com>

* Raise package version to 1.0.0-rc1.

Signed-off-by: Thomas Mansencal <thomas.mansencal@gmail.com>

Signed-off-by: Thomas Mansencal <thomas.mansencal@gmail.com>
  • Loading branch information
KelSolaar committed Oct 8, 2022
1 parent 678c346 commit 4a39825
Show file tree
Hide file tree
Showing 27 changed files with 1,345 additions and 257 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,7 @@ jobs:
strategy:
matrix:
os: [macOS-latest, ubuntu-20.04, windows-latest]
python-version: [3.8, 3.9, '3.10']
exclude:
- os: windows-latest
python-version: 3.8
python-version: [3.9, '3.10']
fail-fast: false
runs-on: ${{ matrix.os }}
steps:
Expand Down
13 changes: 8 additions & 5 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,13 @@ The following features are available:
- Automatic *OCIO* **Reference** configuration generation for *aces-dev*
*CTL* reference implementation.

- Discovery of *aces-dev* *CTL* transforms.
- Generation of the *CTL* transforms graph.
- Discovery of *aces-dev* *CTL* transforms.
- Generation of the *CTL* transforms graph.
- `Spreadsheet <https://docs.google.com/spreadsheets/d/1SXPt-USy3HlV2G2qAvh9zit6ZCINDOlfKT07yXJdWLg>`__-driven generation.

- Generators producing the *OCIO* **CG** and **Studio** configurations.
- `Spreadsheet <https://docs.google.com/spreadsheets/d/1nE95DEVtxtEkcIEaJk0WekyEH0Rcs8z_3fdwUtqP8V4>`__-driven generation.

- Included *CLF* transforms along with generator and discovery support.

User Guide
Expand Down Expand Up @@ -171,17 +174,17 @@ Components Status
+-------------------------------+----------------+----------------------------------------------------------------------------------+
| Custom Config Generation | In-Progress | We are designing the components so that one can generate a custom *ACES* config. |
+-------------------------------+----------------+----------------------------------------------------------------------------------+
| *Studio* Config Generation | In-Progress | |
| *Studio* Config Generation | Complete | |
+-------------------------------+----------------+----------------------------------------------------------------------------------+
| *CLF* Transforms Discovery | Complete | Minor updates will be required if classification changes. |
+-------------------------------+----------------+----------------------------------------------------------------------------------+
| *CLF* Transforms Generation | In-Progress | The *CG* Config *CLF* transforms are implemented |
| *CLF* Transforms Generation | Complete | |
+-------------------------------+----------------+----------------------------------------------------------------------------------+
| Public API Surfacing | In-Progress | What is part of the Public API is not well defined currently. |
+-------------------------------+----------------+----------------------------------------------------------------------------------+
| Unit Tests | In-Progress | |
+-------------------------------+----------------+----------------------------------------------------------------------------------+
| API Documentation | In-Progress | |
| API Documentation | Complete | |
+-------------------------------+----------------+----------------------------------------------------------------------------------+
| Continuous Integration | Complete | |
+-------------------------------+----------------+----------------------------------------------------------------------------------+
Expand Down
958 changes: 958 additions & 0 deletions docs/_static/ACES_Conversion_Graph.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 5 additions & 2 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,13 @@ The following features are available:
- Automatic *OCIO* **Reference** configuration generation for *aces-dev*
*CTL* reference implementation.

- Discovery of *aces-dev* *CTL* transforms.
- Generation of the *CTL* transforms graph.
- Discovery of *aces-dev* *CTL* transforms.
- Generation of the *CTL* transforms graph.
- `Spreadsheet <https://docs.google.com/spreadsheets/d/1SXPt-USy3HlV2G2qAvh9zit6ZCINDOlfKT07yXJdWLg>`__-driven generation.

- Generators producing the *OCIO* **CG** and **Studio** configurations.
- `Spreadsheet <https://docs.google.com/spreadsheets/d/1nE95DEVtxtEkcIEaJk0WekyEH0Rcs8z_3fdwUtqP8V4>`__-driven generation.

- Included *CLF* transforms along with generator and discovery support.

User Guide
Expand Down
4 changes: 3 additions & 1 deletion docs/opencolorio_config_aces.clf.rst
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,12 @@ Common LUT Format Generation
.. autosummary::
:toctree: generated/

generate_clf_transforms_arri
generate_clf_transforms_bmdfilm
generate_clf_transforms_canon
generate_clf_transforms_davinci
generate_clf_transforms_itu
generate_clf_transforms_ocio
generate_clf_transforms_utility
generate_clf_transforms_panasonic
generate_clf_transforms_red
generate_clf_transforms_sony
70 changes: 70 additions & 0 deletions docs/process.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
..
SPDX-License-Identifier: CC-BY-4.0
Copyright Contributors to the OpenColorIO Project.
Process
=======

aces-dev Discovery & Classification
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

The config generation process starts with a set of definitions and classes to discover, parse and classify the CTL transforms from `aces-dev <https://github.com/ampas/aces-dev>`__:

- :func:`opencolorio_config_aces.discover_aces_ctl_transforms`
- :func:`opencolorio_config_aces.classify_aces_ctl_transforms`
- :func:`opencolorio_config_aces.print_aces_taxonomy`

.. note:: This approach allowed us to improve the consistency of the **CTL** transforms ``ACEStransformID`` while fixing various filename issues.

Using ``ACES2065-1`` and ``OCES`` as connection spaces, it is possible to build a colour conversion graph with all the high-level relevant transforms.

- :func:`opencolorio_config_aces.build_aces_conversion_graph`
- :func:`opencolorio_config_aces.plot_aces_conversion_graph`

.. only:: html

.. image:: _static/ACES_Conversion_Graph.svg

Analytical & Reference Configs Generation
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

The colour conversion graph is then used to create the *Analytical* config that maps 1-to-1 the **aces-dev** **CTL** transforms to theoretical **OpenColorIO** builtin transforms.
This config does not work but it is useful to test basic generation capabilities whilst diagnosing issues in the mapping.

The *Reference* config is driven by a *CSV* file generated from a `spreadsheet <https://docs.google.com/spreadsheets/d/1SXPt-USy3HlV2G2qAvh9zit6ZCINDOlfKT07yXJdWLg>`__ mapping the ``ACEStransformID`` to **OpenColorIO** builtin transforms.

- :func:`opencolorio_config_aces.generate_config_aces`

CLF Transforms Generation, Discovery & Classification
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

The working group decided to express additional colour transforms using `CLF <https://acescentral.com/knowledge-base-2/common-lut-format-clf>`__.
Some *CLF* transforms can be serialised into a config which reduces the need for external files. Each *CLF* transform has a ``CLFtransformID`` specified according to the `CLF Formatting for ACES OCIO Config <https://docs.google.com/document/d/1uYNnq1IlKqP8fRXnPviZHrAAu37ctvVsjJZeajOFF2A>`__ document.

The repository contains code to generate, discover and classify the additional *CLF* transforms that the *CG* and *Studio* configs require.

- :func:`opencolorio_config_aces.discover_clf_transforms`
- :func:`opencolorio_config_aces.classify_clf_transforms`
- :func:`opencolorio_config_aces.print_clf_taxonomy`

CG Config Generation
^^^^^^^^^^^^^^^^^^^^

The *CG* config generator also uses a *CSV* file generated from a `spreadsheet <https://docs.google.com/spreadsheets/d/1nE95DEVtxtEkcIEaJk0WekyEH0Rcs8z_3fdwUtqP8V>`__ that expresses which ``ACEStransformID`` should be used from the `Reference` config and which ``CLFtransformID`` should be used from the shipped *CLF* transforms.

- :func:`opencolorio_config_aces.generate_config_cg`

The conversion process is as follows:

*aces-dev Discovery & Classification* -> *Reference Config Generation* -> *CLF Transforms Generation, Discovery & Classification* -> *CG Config Generation*

Studio Config Generation
^^^^^^^^^^^^^^^^^^^^^^^^

The *Studio* config generator follows the same approach but uses a different `pivot table <https://docs.google.com/spreadsheets/d/1nE95DEVtxtEkcIEaJk0WekyEH0Rcs8z_3fdwUtqP8V4/edit#gid=1155125238>`__ of the spreadsheet.

- :func:`opencolorio_config_aces.generate_config_studio`

The conversion process is as follows:

*aces-dev Discovery & Classification* -> *Reference Config Generation* -> *CLF Transforms Generation, Discovery & Classification* -> *Studio Config Generation*
10 changes: 5 additions & 5 deletions docs/usage.rst
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ Reference Config
****************

+-----------------------+--------------------------------------------+
| Task | Command |
| *Task* | *Command* |
+-----------------------+--------------------------------------------+
| Build | `invoke build-config-reference` |
+-----------------------+--------------------------------------------+
Expand All @@ -34,7 +34,7 @@ CG Config
*********

+-----------------------+-------------------------------------+
| Task | Command |
| *Task* | *Command* |
+-----------------------+-------------------------------------+
| Build | `invoke build-config-cg` |
+-----------------------+-------------------------------------+
Expand All @@ -43,11 +43,11 @@ CG Config
| Updating Mapping File | `invoke update-mapping-file-cg` |
+-----------------------+-------------------------------------+

Reference Config
****************
Studio Config
*************

+-----------------------+-----------------------------------------+
| Task | Command |
| *Task* | *Command* |
+-----------------------+-----------------------------------------+
| Build | `invoke build-config-studio` |
+-----------------------+-----------------------------------------+
Expand Down
1 change: 1 addition & 0 deletions docs/user-guide.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,4 @@ and explains important concepts and features, details can be found in the

Installation <installation>
usage
process
8 changes: 4 additions & 4 deletions opencolorio_config_aces/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,9 +129,9 @@

__application_name__ = "OpenColorIO Configuration for ACES"

__major_version__ = "0"
__minor_version__ = "3"
__change_version__ = "1"
__major_version__ = "1"
__minor_version__ = "0"
__change_version__ = "0-rc1"
__version__ = ".".join(
(__major_version__, __minor_version__, __change_version__)
) # yapf: disable
)
7 changes: 7 additions & 0 deletions opencolorio_config_aces/clf/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,15 @@
)
from .transforms import (
generate_clf_transform,
generate_clf_transforms_arri,
generate_clf_transforms_bmdfilm,
generate_clf_transforms_canon,
generate_clf_transforms_davinci,
generate_clf_transforms_itu,
generate_clf_transforms_ocio,
generate_clf_transforms_panasonic,
generate_clf_transforms_red,
generate_clf_transforms_sony,
)

__all__ = [
Expand All @@ -27,10 +30,14 @@
]
__all__ += [
"generate_clf_transform",
"generate_clf_transform",
"generate_clf_transforms_arri",
"generate_clf_transforms_bmdfilm",
"generate_clf_transforms_canon",
"generate_clf_transforms_davinci",
"generate_clf_transforms_itu",
"generate_clf_transforms_ocio",
"generate_clf_transforms_panasonic",
"generate_clf_transforms_red",
"generate_clf_transforms_sony",
]
18 changes: 16 additions & 2 deletions opencolorio_config_aces/clf/transforms/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,15 @@
clf_basename,
)
from .arri import (
generate_clf_arri,
generate_clf_transforms_arri,
)
from .blackmagic import (
generate_clf_transforms_bmdfilm,
generate_clf_transforms_davinci,
)
from .canon import (
generate_clf_transforms_canon,
)
from .itu import (
generate_clf_transforms_itu,
)
Expand All @@ -28,6 +31,9 @@
from .red import (
generate_clf_transforms_red,
)
from .sony import (
generate_clf_transforms_sony,
)

__all__ = [
"matrix_transform",
Expand All @@ -37,11 +43,16 @@
"format_clf_transform_id",
"clf_basename",
]
__all__ += ["generate_clf_arri"]
__all__ += [
"generate_clf_transforms_arri",
]
__all__ += [
"generate_clf_transforms_bmdfilm",
"generate_clf_transforms_davinci",
]
__all__ += [
"generate_clf_transforms_canon",
]
__all__ += [
"generate_clf_transforms_itu",
]
Expand All @@ -54,3 +65,6 @@
__all__ += [
"generate_clf_transforms_red",
]
__all__ += [
"generate_clf_transforms_sony",
]
4 changes: 2 additions & 2 deletions opencolorio_config_aces/clf/transforms/arri/__init__.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# SPDX-License-Identifier: BSD-3-Clause
# Copyright Contributors to the OpenColorIO Project.

from .generate import generate_clf_arri
from .generate import generate_clf_transforms_arri

__all__ = [
"generate_clf_arri",
"generate_clf_transforms_arri",
]
8 changes: 4 additions & 4 deletions opencolorio_config_aces/clf/transforms/arri/generate.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
Defines procedures for generating ARRI *Common LUT Format* (CLF)
transforms:
- :func:`opencolorio_config_aces.clf.generate_clf_arri`
- :func:`opencolorio_config_aces.clf.generate_clf_transforms_arri`
"""

from math import log, log10
Expand All @@ -34,7 +34,7 @@
"FAMILY",
"GENUS",
"VERSION",
"generate_clf_arri",
"generate_clf_transforms_arri",
]

FAMILY = "ARRI"
Expand Down Expand Up @@ -390,7 +390,7 @@ def _generate_logc4_transforms(output_directory):
return transforms


def generate_clf_arri(output_directory):
def generate_clf_transforms_arri(output_directory):
"""
Generate CLF files for ARRI color encodings and save to disk.
Expand Down Expand Up @@ -438,7 +438,7 @@ def _main():

output_directory = Path(__file__).parent.resolve() / "input"

generate_clf_arri(output_directory)
generate_clf_transforms_arri(output_directory)

return 0

Expand Down
4 changes: 2 additions & 2 deletions opencolorio_config_aces/clf/transforms/sony/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
# Copyright Contributors to the OpenColorIO Project.

from .generate import (
generate_clf_sony,
generate_clf_transforms_sony,
)

__all__ = [
"generate_clf_sony",
"generate_clf_transforms_sony",
]
8 changes: 4 additions & 4 deletions opencolorio_config_aces/clf/transforms/sony/generate.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
Defines procedures for generating Sony *Common LUT Format* (CLF)
transforms:
- :func:`opencolorio_config_aces.clf.generate_clf_sony`
- :func:`opencolorio_config_aces.clf.generate_clf_transforms_sony`
"""

import PyOpenColorIO as ocio
Expand All @@ -32,7 +32,7 @@
"FAMILY",
"GENUS",
"VERSION",
"generate_clf_sony",
"generate_clf_transforms_sony",
]

FAMILY = "Sony"
Expand Down Expand Up @@ -102,7 +102,7 @@ def _build_venice_sgamut3_cine_mtx():
return mtx


def generate_clf_sony(output_directory):
def generate_clf_transforms_sony(output_directory):
"""
Make all the Sony CLFs.
Expand Down Expand Up @@ -281,4 +281,4 @@ def generate_clf_sony(output_directory):

output_directory = Path(__file__).parent.resolve() / "input"

generate_clf_sony(output_directory)
generate_clf_transforms_sony(output_directory)
Loading

0 comments on commit 4a39825

Please sign in to comment.