Nodes/ComfyUI Video Depth Anything/Video Depth Anything Save EXR
ComfyUI Node

Video Depth Anything Save EXR

Export full-precision depth for VFX and 3D tools

By yuvraj108c·Created 2 years ago·Updated 7 months ago· 50
Video Depth Anything Save EXR
  • depths
  • exr_path
folder_nameexr-1

The other three nodes in this pack are about getting a depth video you can look at. This one is for people who don't want a video at all - they want the raw numbers. VideoDepthAnythingSaveEXR writes the DEPTHS data straight out as an EXR image sequence, no colormap, no 8-bit crushing, full floating-point precision preserved. If your next step is Nuke, After Effects, Blender, or Unreal rather than another ComfyUI preview, this is the node you want instead of VideoDepthAnythingOutput.

Why EXR and not just a PNG sequence

A grayscale PNG depth map is 8-bit - 256 discrete brightness levels standing in for the entire depth range of the scene. Fine for a ControlNet conditioning signal, genuinely bad for actual VFX work: compress a smooth real-world depth gradient into 256 steps and you get visible banding the moment someone tries to pull a depth-based selection or do camera-space compositing with it. EXR is a floating-point format built for exactly this - it stores the real depth values losslessly, the same category of file a render engine would output for its own depth pass. This node exists because VideoDepthAnythingOutput's gray/inferno images have already thrown that precision away by the time they're a normal image; this node captures it before that happens.

The inputs that matter

Only two, and one of them you'll rarely touch:

  • depths - the DEPTHS object from VideoDepthAnythingProcess. Same object type the Output node consumes; this one just handles it differently.
  • folder_name (default exr-1) - where the EXR sequence gets written. Bump this per run if you don't want successive exports overwriting each other or piling into the same folder - it's a plain string, so name it however your downstream pipeline expects.

Output

exr_path (type STRING) - the path the sequence was written to, so you can wire it into a display node to confirm where things landed, or chain it into any other node in your graph that consumes a file path. This node is also marked as an output node in ComfyUI's terms, meaning it's a valid endpoint on its own - you don't need to route anything further downstream of it for the graph to consider its job done.

Installing it

ComfyUI Manager: search ComfyUI Video Depth Anything, install, restart. Manually:

cd ComfyUI/custom_nodes
git clone https://github.com/yuvraj108c/ComfyUI-Video-Depth-Anything

then restart ComfyUI. Same pack as the other three nodes - install once, get all of them. This one specifically may pull in an EXR-writing library (commonly OpenEXR or a Python binding to it) as part of its requirements, since that's not something a base ComfyUI install ships with; if it fails to import at startup, that's the first dependency to check.

Common issues & troubleshooting

Node fails to import / EXR support missing. If ComfyUI's console shows an import error pointing at an EXR-related package on startup, the underlying EXR library likely didn't install cleanly - reinstalling this pack through ComfyUI Manager rather than a bare git clone gives it a better shot at landing dependencies in the right Python environment, the same fix that applies to most of this author's node packs.

Files land somewhere unexpected. folder_name is relative to wherever this pack writes its output by default, not necessarily your main ComfyUI output directory - check the returned exr_path string rather than guessing, it tells you exactly where the sequence went.

Sequence looks wrong / values seem off when read in a 3D tool. Confirm which checkpoint you loaded on LoadVideoDepthAnythingModel. If your downstream tool expects real-world scale (actual distances for camera-space compositing), you need one of the metric_ checkpoints - the plain small/base/large models output relative depth, which is the right choice for a ControlNet-style depth pass but the wrong choice if something is going to treat these EXR values as literal distances.

Huge file counts / slow writes on long clips. An EXR sequence is one file per frame at full float precision, so a long clip at a high max_res on the upstream VideoDepthAnythingProcess node adds up fast in both disk space and write time. If that's biting you, it's worth trading some resolution on the process step rather than the export step - you can't recover precision here that wasn't computed upstream.

CategoryVideoDepthAnything

Inputs (2)

NameTypeDefaultDescription
depthsDEPTHS
folder_nameSTRINGexr-1

Outputs (1)

NameTypeDescription
exr_pathSTRING