Nodes/Nilor Nodes by Nilor Corp/๐Ÿ‘บ Save EXR Arbitrary
ComfyUI Node

๐Ÿ‘บ Save EXR Arbitrary

Save any number of float channels as a real OpenEXR, not just an RGB PNG

By nilor-corpยทCreated 2 years agoยทUpdated 6 months agoยท 6
๐Ÿ‘บ Save EXR Arbitrary
  • channels
    โ—„filename_prefixoutputโ–บ

    Most of ComfyUI's save nodes are built around the assumption that your data is an image - three to four 8-bit channels, colors, done. But sometimes your tensor carries something else entirely: a depth map, a normal pass, a raw float buffer, a stack of arbitrary channels that would be destroyed by an 8-bit PNG round-trip. ๐Ÿ‘บ Save EXR Arbitrary is the escape hatch. It takes a list of same-sized tensors, names them R, G, B, A, Channel4, Channel5โ€ฆ, and writes them all into a real OpenEXR file at full float precision.

    If you don't know why that matters, you don't need this node yet. EXR is the HDR/float workhorse of VFX and 3D pipelines - 32-bit float per channel, no 0โ€“255 clamping, values above 1.0 survive intact. That's what makes it right for depth or multi-pass rendering data where the number is the point, not the color. If you've ever exported a depth map and watched a PNG crush your far-plane values to pure black or white, this is the fix. A node that writes EXR also tends to be the thing that lets you hand data to an external tool that only speaks EXR (Blender's compositor, Nuke, Houdini) without a lossy detour through PNG.

    The mechanism is honest plumbing: it converts each incoming tensor to a float32 numpy array, builds an EXR header with one channel per tensor (named R, G, B, A, then ChannelN), and writes with the OpenEXR library. It handles batches too - a [batch, h, w] stack of channels gets one file per batch index. Files land in ComfyUI's output folder with an incrementing counter, or you can give filename_prefix an absolute path to write wherever you like.

    Inputs and output

    • channels - a list of same-sized tensors, one per EXR channel. The * type means it'll take anything, but the source requires them all to share dimensions.
    • filename_prefix - output name prefix (default output), or an absolute path for custom placement.
    • No outputs - it's an output node; the side effect is the file on disk.

    Installing it

    This is the node that actually justifies the pack's heaviest dependency. Part of Nilor Nodes (nilor-corp/nilor-nodes):

    cd ComfyUI/custom_nodes
    git clone https://github.com/nilor-corp/nilor-nodes
    

    or ComfyUI Manager โ†’ search "Nilor Nodes" โ†’ install โ†’ restart. The openexr Python package in the pack's requirements.txt is what does the writing - if EXR saving fails with an import error, that's the dependency to check. No model files.

    Troubleshooting

    The source is strict about one thing: every channel tensor must have identical height and width, or it raises. If your channels came from different nodes that resized differently, fix that upstream. The other gotcha is expectations about precision - the output is float32, which is exactly right for EXR and a good reason not to pipe ordinary sRGB images through it (they'll just be huge floats). There's no community support for this pack to fall back on, and the README is thin here, so the source is your reference. And check that openexr actually installed cleanly - binary wheels are normally fine, but a stale Python environment is the most common way this node fails.

    CategoryNilor Nodes ๐Ÿ‘บ/IO

    Inputs (2)

    NameTypeDefaultDescription
    channels*โ€”
    filename_prefixSTRINGoutputโ€”

    Outputs (0)

    No outputs