ComfyUI Node

CoCo Saver

The node that finally writes real EXR (and 16-bit PNG) files

By Conor-Collins·Created about a year ago·Updated 6 months ago· 105
CoCo Saver
  • images
    file_path
    filenameComfyUI
    save_modesingle
    use_versioningfalse
    file_typepng

    Here's the problem CoCo Saver solves: ComfyUI's built-in Save Image writes an 8-bit PNG and nothing else. No EXR, no 16-bit PNG, no TIFF, no per-format compression control. If your pipeline ends at a render pass or a client delivery spec, that's a hard wall. This node from the CoCoTools pack is the output end of that gap - a saver that actually respects bit depth and file format.

    How it works

    Under the hood it splits the work between two libraries: OpenImageIO writes EXR, PNG and TIFF, and OpenCV handles JPG and WebP. That split matters because EXR and TIFF are float- and integer-native formats that OIIO handles properly, while the lossy web formats are just 8-bit quality settings. The node also does a fast grayscale check (sampling pixels above 1MP) so a single-channel image gets saved as a proper single-channel file instead of a wasteful RGB one.

    The widget that makes it feel alive is file_type. Switch it and the node rebuilds its own options via a small JS extension, so the controls always match the format you picked:

    • EXR: bit depth 16 or 32 (default 32), compression from none/zip/zips/rle/pxr24/b44/b44a/dwaa/dwab (default zips)
    • PNG: 8 or 16 bit (default 16)
    • TIFF: 8/16/32 bit
    • JPG / WebP: quality slider, 8-bit only

    That's the honest trade here - this is a tool for people who deliver real files, not a social-media JPG machine.

    Inputs that matter

    The required inputs are images (the IMAGE tensor), file_path, filename, save_mode, use_versioning, and file_type. The ones you actually touch:

    • file_path + filename - leave file_path empty and it saves into ComfyUI's normal output folder. Give it a path and it'll create the directories. filename defaults to "ComfyUI".
    • save_mode - single writes one file per image; sequence unlocks frame controls and, when your filename contains a #### pattern, pads the frame number (render_####.exrrender_0001.exr).
    • use_versioning - appends _v001, _v002 style counters instead of overwriting. Nice for iterating a look.

    There are no outputs - it's an output node. It also deliberately skips ComfyUI's caching (IS_CHANGED always returns NaN), so it runs every time. Don't expect it to be skipped when nothing changed; that's by design so you can't accidentally miss a frame.

    Installing it

    It ships in the CoCoTools pack, so install the pack once:

    • ComfyUI Manager: search "CoCoTools" and install, then restart ComfyUI.
    • Manual:
    cd ComfyUI/custom_nodes
    git clone https://github.com/Conor-Collins/ComfyUI-CoCoTools_IO
    # Windows portable - use the bundled Python:
    "..\..\python_embeded\python.exe" -m pip install -r ComfyUI-CoCoTools_IO\requirements.txt
    # Otherwise your normal pip:
    pip install -r ComfyUI-CoCoTools_IO/requirements.txt
    

    Then restart ComfyUI.

    Common issues

    The heavy dependency here is OpenImageIO, and it's non-negotiable for EXR/TIFF saves - the node raises if it's missing. On the portable build, install the requirements with python_embeded's Python, not your system Python, or pip installs into the wrong environment and ComfyUI still can't import it. Two gotchas worth knowing before they bite:

    • The README's own pip command says ComfyUI-CoCoTools/requirements.txt - the folder is actually ComfyUI-CoCoTools_IO. Copy that line verbatim and pip will error.
    • JPG/WebP are hard-capped at 8-bit. If you picked a 16-bit depth and switch to JPG, you're getting an 8-bit file no matter what; choose your format before you judge the output.

    It's a niche tool - the pack overall is small and this node sees single-digit-to-low-20s impressions - but if you've ever manually converted a ComfyUI output to EXR in a second app, this is the one that removes the second app.

    CategoryCOCO Tools/Savers

    Inputs (6)

    NameTypeDefaultDescription
    imagesIMAGE
    file_pathSTRING
    filenameSTRINGComfyUI
    save_modeCOMBOsingle2 options: single, sequence
    use_versioningBOOLEANfalse
    file_typeCOMBOpng5 options: exr, png, jpg, webp, tiff

    Outputs (0)

    No outputs