In this article
A successful first-part read does not establish that the intended view or target was loaded from a multipart file.
Distinguish parts from channels
An EXR file can contain multiple image parts, each with its own header and channels. A renderer may use those parts for separate views, resolutions or pass groups. A loader that expects a single color image can therefore return plausible pixels while ignoring the target needed for training. Treat the file as a structured container and define the intended image identity before interpreting any convenient array returned by a reader.
Know what convenience methods select
The Python module documentation explains that the file-level header and channel convenience methods refer to the first part. It explicitly advises validating the part count when code assumes a single-part file. A missing target channel should trigger an investigation of the part structure, not an immediate fallback to a similarly named channel in the first image. Enumerate actual parts before deciding that the export is incomplete.
Build an explicit selection rule
The technical introduction describes multipart organization and image metadata. Select the requested part using documented producer conventions and validate its expected channels and dimensions. A positional index can be acceptable under a pinned export contract, but it should not silently survive a producer that changes part ordering. Preserve the selected identity in dataset metadata so troubleshooting can trace a training sample to its actual source image.
Validate each selected image independently
The image I/O guide shows that multipart storage can contain different image types. Do not assume every part shares the same resolution, data window or flat-versus-deep representation. Check these properties for the chosen part before aligning inputs and targets. A file-wide check is insufficient when the RGB input and a supervision pass come from different parts with distinct spatial or numerical contracts.
Reject ambiguity rather than hiding it
Test a file whose first part is a preview and whose later part contains the intended measurement. Also test a missing requested part and an unexpected additional part. The guides to dataset annotation identity and image coordinate integrity explain adjacent contracts. Require the loader either to identify a valid intended part or to report a clear mismatch; choosing the first readable image can turn a recoverable export change into incorrect training data.
Earn rental income from GPUs
Have idle GPUs or looking to fund AI infrastructure? Retrivium finds a rental platform, sets up the server and helps you assess income and costs with a pilot.