IdentifyBuiltinColorSpace heuristics failure edgecases: ACEScc, ADX16, CIE-XYZ-D65
I maintainer di solito rispondono entro 2 giorni
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 35/100
- Tipo di issue
- Bug
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Ferma
- Ambito
- computer-graphics
Direzione di ricerca
Inizia eseguendo la riproduzione Python fornita su ocio://studio-config-latest e confronta i risultati di IdentifyBuiltinColorSpace tra i diversi flag di ottimizzazione e le impostazioni degli spazi colore inattivi. Esamina quindi Config::IdentifyBuiltinColorSpace e i percorsi di matching di ACEScc, ADX16 e CIE XYZ-D65 BuiltinTransform. Il lavoro è completato quando gli spazi colore equivalenti elencati vengono identificati in modo coerente e il comportamento richiesto per visibilità e ottimizzazione è coperto.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Apparently, ACEScc, ADX16, and both CIE XYZ-D65 spaces from ocio://studio-config-latest (as of OCIO v2.5.0) are evading our out-of-the-box matching / identification algorithms.
I've been noticing that, very occasionally, Config::IdentifyBuiltinColorSpace has trouble matching certain color spaces among configs that really do share functionally identical definitions, and should, by all accounts, be recognized as equivalent.
I wrote a little function to assess which color spaces in a given config IdentifyBuiltinColorSpace seems to have the most trouble with -- essentially, I'm using the exact same config for both the srcConfig and the builtinConfig, and just collecting the color spaces that can't be found in their own configs.
In exploring this, I found that both optimization flags (unsurprisingly) and color space visibility (surprisingly) affect the rate of success.
Insights:
- It would be useful if there were a way to force Config.IdentifyBuiltinColorSpace to always attempt to failover to searching inactive color spaces.
- It would be nice if IdentifyBuiltinColorSpace exposed an optional optimizationFlags argument as a means of fine-tuning the equivalency "tolerance"
Findings:
- "ADX16" color spaces based off of the
ADX16_to_ACES2065-1BuiltinTransform can be matched when using DRAFT optimization or higher - "ACEScc" and "ACESproxy10i" color spaces based off of the
ACEScc_to_ACES2065-1ACESproxy10i_to_ACES2065-1BuiltinTransform styles respectively remain "unmatchable", regardless of optimization settings.
Here's a python snippet if you wanna mess around:
import PyOpenColorIO as ocio
import os
def get_unmatchable_color_spaces(
config: ocio.Config,
optimization: ocio.OptimizationFlags | int | None = None,
exclude_inactive: bool = False,
verbose: bool = False,
) -> list[str]:
# Optimization Flags affect the identification heuristics. The API doesn't expose a way
# to directly control the optimization flags used for identifying color spaces, but we
# can temporarily adjust the $OCIO_OPTIMIZATION_FLAGS environment variable
# if we want to temporarily override the global optimization behavior
# Preserve the previous environment to restore later.
prev_env = dict(os.environ)
if optimization:
# Temporarily set $OCIO_OPTIMIZATION_FLAGS to the requested value.
os.environ[ocio.OCIO_OPTIMIZATION_FLAGS_ENVVAR] = str(int(optimization))
# Color space visiblity affects the identification heuristics.
# To maximize the likelihood of finding a match, we can temporarily
# activate all color spaces.
# Store the old inactive color spaces to restore later.
old_invisible_color_spaces = config.getInactiveColorSpaces()
if not exclude_inactive:
# Temporarily make all color spaces visible.
config.setInactiveColorSpaces("")
# Iterate over all the color spaces in the config, and collect names of
# color spaces that steadfastly refuse to be matched!
problem_spaces = []
for cs_name in config.getColorSpaceNames(
ocio.SEARCH_REFERENCE_SPACE_ALL,
ocio.COLORSPACE_ALL
):
# Try to match each color space in the config to... itself!
try:
matched_space = ocio.Config.IdentifyBuiltinColorSpace(config, config, cs_name)
except ocio.Exception as e:
if verbose:
ocio.LogMessage(ocio.LOGGING_LEVEL_WARNING, str(e))
problem_spaces.append(cs_name)
# Cleanup -- restore the previous environment and config state.`
os.environ.clear()
os.environ.update(prev_env)
config.setInactiveColorSpaces(old_invisible_color_spaces)
return sorted(problem_spaces)
studio_config_modified = ocio.Config.CreateFromFile("ocio://studio-config-latest")
# Add an ACESproxy10i color space to the studio-config, because I suspect it'll also fail to match itself.
studio_config_modified.addColorSpace(
ocio.ColorSpace(
ocio.REFERENCE_SPACE_SCENE,
name="ACESproxy10i",
toReference= ocio.BuiltinTransform("ACESproxy10i_to_ACES2065-1")
)
)
print(f"""
Unmatchable color spaces: {studio_config_modified.getName()}
---
- Default IdentifyBuiltinColorSpace behavior:
{get_unmatchable_color_spaces(studio_config_modified, exclude_inactive=True)}
- Ignore visibility + no optimizations:
{get_unmatchable_color_spaces(studio_config_modified, optimization=ocio.OPTIMIZATION_NONE)}
- Ignore visibility + draft optimizations:
{get_unmatchable_color_spaces(studio_config_modified, optimization=ocio.OPTIMIZATION_DRAFT)}
""")
Unmatchable color spaces: studio-config-v4.0.0_aces-v2.0_ocio-v2.5
---
- Default IdentifyBuiltinColorSpace behavior:
['ACEScc', 'ACESproxy10i', 'ADX16', 'CIE XYZ-D65 - Display-referred', 'CIE XYZ-D65 - Scene-referred']
- Ignore visibility + no optimizations:
['ACEScc', 'ACESproxy10i', 'ADX16']
- Ignore visibility + draft optimizations:
['ACEScc', 'ACESproxy10i']
- Lingua principale
- C++
- Stelle
- 2.1k
- Fork
- 503
- Merge medio
- 7g 16h
- PR unite (30g)
- 7
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di AcademySoftwareFoundation/OpenColorIO
-
Inconsistent run-time library usage for locale handling breaks GPU code generation on some systems.Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 86/100
AcademySoftwareFoundation/OpenColorIO#2351 · 2 commenti ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
AcademySoftwareFoundation/OpenColorIO#2340 ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
AcademySoftwareFoundation/OpenColorIO#2329 ·
I maintainer di solito rispondono entro 2 giorni
-
Build failure on GCC/MinGW (MXE): std::ifstream constructor mismatch with Platform::filenameToUTF()Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
AcademySoftwareFoundation/OpenColorIO#2283 ·
I maintainer di solito rispondono entro 2 giorni
-
ReadTheDocs - OS DeprecationApertaDocumentation
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 72/100
AcademySoftwareFoundation/OpenColorIO#2280 · 1 commento ·
I maintainer di solito rispondono entro 2 giorni
Tutte le issue di AcademySoftwareFoundation/OpenColorIO
Issue simili
-
The Outdated Version prompt shows the release tag as unescaped HTMLForse già presa @on8st l’ha presa oggi. Apertabug good first issue GUI maintainer-review priority: low
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
aethersdr/AetherSDR#6405 · 2 commenti ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
bitcoin-core/gui-qml#1003 ·
I maintainer di solito rispondono entro 3 giorni
-
fails to compile with Qt6Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
-
[Bug]:设置的关于页面,“系统信息”部分排版异常Apertabug
Difficoltà 2/5 1-3 ore Idoneità per principianti 63/100
metasequoiaime/msime#7328 ·
I maintainer di solito rispondono entro 1 giorno
-
[Linux] --calibrate combined with --model silently falls through to plain re-setup (setup.py:4958)Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
I maintainer di solito rispondono entro 1 giorno