Nodes/ComfyUI-Artha-Nodes/πŸ”± Artha Color Match
ComfyUI Node

πŸ”± Artha Color Match

Make your generations actually look like the reference

By CyrostarΒ·Created 10 months agoΒ·Updated 8 months agoΒ· 0
πŸ”± Artha Color Match
  • source_image
  • target_image
  • image
β—„primary_methodβ–Ύβ–Ί
β—„secondary_methodβ–Ύβ–Ί
β—„mixing_modeβ–Ύβ–Ί
β—„primary_weight0.70β–Ί
β—„preserve_luminancetrueβ–Ί
β—„iterations1β–Ί
β—„gamut_modeautoβ–Ί
β—„strength1.00β–Ί
β—„use_regrainfalseβ–Ί
β—„regrain_strength0.60β–Ί
β—„regrain_radius3β–Ί

Artha Color Match is the πŸ”± Artha pack's heavy artillery for a problem every image pipeline hits eventually: you generated something great, but the colors don't match the reference you had in mind. Film-still energy that comes out greenish, a product shot with the wrong white balance, a character whose palette drifted between passes - this node transfers the color grade from one image to another.

Unlike the simple histogram-matching you'll find in a dozen other packs, this one is a genuine multi-method toolkit. Six color-transfer algorithms, a secondary method you can blend in, gamut control, grain restoration - it's the node you reach for when "close enough" stops being close enough.

How it works

At its core it's the classic color-transfer pipeline: convert both images to a color space, shift the source's statistics toward the target's, and convert back. The depth is in the options. The primary_method dropdown picks the transfer algorithm - Reinhard (statistics-based, the classic), MKL, CIEDE2000, LAB-NN, color-mood, and PDF matching - each with different behavior on tricky grades. iterations (1–10) re-runs the primary method for stronger results. A secondary_method can then be applied and mixed in via one of five mixing_modes (blend, sequential, luminance, detail, or none), with primary_weight controlling how much each contributes.

Three settings prevent the usual color-match disasters: preserve_luminance keeps the source's light/dark structure so you don't get a flat posterized result, gamut_mode sets the working color space (srgb, adobe_rgb, prophoto_rgb, rec2020, dci_p3, or auto), and use_regrain + regrain_strength/regrain_radius restore fine detail after the color shift, which is what keeps the result looking like a photograph instead of a smoothed gradient. strength (0–2) blends the whole result back toward the original.

Inputs that matter

  • source_image - the image you're recoloring. target_image - the image whose look you want. This direction trips people up constantly: the target is the reference.
  • primary_method - the main algorithm; Reinhard is the safe starting point.
  • preserve_luminance - keep it on unless you specifically want the target's lighting too.
  • strength - your safety dial. Start at 1.0, back it off to ~0.6 if the grade looks overcooked.

Output is a single image IMAGE output, ready to feed a save/preview node or back into an img2img pass.

Installing it

One-pack install, same as the rest of Artha:

cd ComfyUI/custom_nodes
git clone https://github.com/Cyrostar/ComfyUI-Artha-Nodes
pip install -r ComfyUI/custom_nodes/ComfyUI-Artha-Nodes/requirements.txt

then restart, or install "ComfyUI-Artha-Nodes" through ComfyUI Manager. The color matching leans on scikit-learn and opencv-python from the pack's requirements - those are the real dependencies here, and they're heavier than the pack's other nodes. No API key, no model downloads, fully local.

Common issues

  • Result looks washed out or flat: usually preserve_luminance off, or an aggressive iterations setting. Re-enable luminance and drop back to 1–2 iterations.
  • Green/gray cast after matching: a gamut mismatch. Try switching gamut_mode to match the target's working space, or auto.
  • Grainy, splotchy detail: turn on use_regrain and tune regrain_radius (3 is the default) to pull source detail back.
  • Tiny color shift, not enough: crank strength toward 2.0, or add a second method via secondary_method.

The one-liner: it's the pack's most technical node and it repays the fiddling. If all you need is "make image B look like image A, quick", the Reinhard default with luminance preserved gets you 80% there - the extra knobs are for when 80% isn't good enough.

CategoryArtha/Image

Inputs (13)

NameTypeDefaultDescription
source_imageIMAGEβ€”
target_imageIMAGEβ€”
primary_methodCOMBO6 options: reinhard, mkl, ciede2000, lab_nn, color_mood, pdf
secondary_methodCOMBO7 options: none, reinhard, mkl, ciede2000, lab_nn, color_mood, +1
mixing_modeCOMBO5 options: none, blend, sequential, luminance, detail
primary_weightFLOAT0.700–1β€”
preserve_luminanceBOOLEANtrueβ€”
iterationsINT11–10β€”
gamut_modeCOMBOauto6 options: auto, srgb, adobe_rgb, prophoto_rgb, rec2020, dci_p3
strengthFLOAT1.000–2β€”
use_regrainBOOLEANfalseβ€”
regrain_strengthFLOAT0.600–1β€”
regrain_radiusINT31–15β€”

Outputs (1)

NameTypeDescription
imageIMAGEβ€”