Nodes/ComfyUI-SplatKit/Repair Metrics
ComfyUI Node

Repair Metrics

The honest check that your repair backend didn't just repaint the frame

By mickmumpitz·Created about a month ago·Updated about 22 hours ago· 17
Repair Metrics
  • before
  • after
  • diff_map
  • report
  • gain
  • drift
label

If you're going to repair stretched cube faces, you need a way to tell whether the repair actually helped - and for a 3D Gaussian splat, "did the image get sharper" is not the same question as "did the geometry survive." Repair Metrics is a tiny diagnostic node that measures both sides of that. Wire the ORIGINAL damaged frame into before, the backend's output (Qwen, SeedVR2, SUPIR - anything) into after, and it returns two numbers plus a heatmap:

  • gain = sharpness(after) / sharpness(before). Greater than 1 means sharper; ~1 means the backend did nothing.
  • drift = mean absolute luma change (0–255). This is the one to watch for splats: a big gain with big drift means it repainted geometry, not just deblurred - and repainted geometry is exactly what a splat can't explain with one 3D model, so it shows up as floaters and blur later.

diff_map (an IMAGE) shows where the change landed, so you can see if it's confined to the smeared region or if the backend went ahead and rewrote the whole wall. The label input (e.g. seedvr2 / supir) just tags the report. Outputs: diff_map, report, gain, drift, and it's an output node - it prints the numbers to the console and shows them on the node.

How you'd use it

Pair it with the repair pipeline: Prepare Repair Batch picks a damaged face, your Qwen graph repairs it, and Repair Metrics sits on the before/after pair so you can see per-frame whether the gain justifies the drift. If you're A/B-ing repair backends, this is the node that gives you a number instead of vibes - run each on the same batch, compare gain and drift, and let the drift decide. The author's framing is exactly right: for video, drift barely matters; for a splat, it's the whole question.

Install & gotchas

cd ComfyUI/custom_nodes
git clone https://github.com/mickmumpitz/ComfyUI-SplatKit
python_embeded\python.exe -m pip install -r ComfyUI-SplatKit/requirements.txt

Restart, and you're done - this node is pure numpy-level image math with no model downloads and no GPU requirement beyond what ComfyUI already uses. The only trap is reading gain in isolation: a repair backend that adds texture everywhere will post a flattering sharpness gain while silently rewriting the scene. Always look at drift next to it - for splat work, drift is the number that predicts whether the repair stays in the final reconstruction.

CategorySplatKit

Inputs (3)

NameTypeDefaultDescription
beforeIMAGEThe ORIGINAL damaged frame.
afterIMAGEThe repaired frame (backend output).
labeloptSTRINGA name for this backend (e.g. seedvr2 / supir) -- shown in the report.

Outputs (4)

NameTypeDescription
diff_mapIMAGE
reportSTRING
gainFLOAT
driftFLOAT