Nodes/comfyui-dit-watermark/GROW Watermark Config
ComfyUI Node

GROW Watermark Config

Enter your watermark layout once, never twice — this is the node that keeps embed and detect honest

By zhangp365·Created 2 months ago·Updated 2 months ago· 1
GROW Watermark Config
    • config
    ◄secret_keywatermark►
    ◄dct_min0.15►
    ◄dct_max0.45►
    ◄max_channels8►
    ◄channel_start4►
    ◄center_ratio1.00►

    GROW Watermark Config is the least glamorous node in the pack and the one you shouldn't skip. It exists for one reason: a GROW watermark is defined by six layout parameters, and every single one has to be byte-for-byte identical between the node that embeds it and the node that detects it. Type them in twice and a typo in one field silently kills detection. This node makes you type them once.

    It stores nothing but settings and emits one GROW_CONFIG socket, which you fan out to both GROW DiT Sampler and GROW Watermark Detect. That's the "one source, many consumers" plumbing pattern ComfyUI does best - one authoritative value instead of six duplicated widgets.

    What each field does

    • secret_key (default watermark) - the scramble. It seeds a hash that reorders which mid-frequency coordinates carry your bits. Different key, different layout. Think of it as the thing that stops a stranger from reading your watermark with their own config.
    • dct_min / dct_max (default 0.15 / 0.45) - the normalized mid-frequency band in the latent's 2D FFT. Low frequencies survive compression but are visible; high frequencies are invisible but die instantly. The middle is where the tradeoff lives.
    • max_channels / channel_start (default 8 / 4) - how many latent channels get used and where the contiguous block starts. The Flux2 workflow uses channels 4–11.
    • center_ratio (default 1.0) - the central fraction of the latent used for the watermark.

    If you never change a field, you can ignore all of them - the defaults are exactly what the pack's own Flux2/Qwen workflows run.

    Why this node exists

    The author's own test shows the failure mode precisely: change channel_start to 0, or max_channels to 4, or shift dct_min/dct_max slightly, and the detector returns ecc_valid=False in every case - even though the vote margin can still look great. A high margin doesn't prove the layout is right; only the Reed–Solomon frame check is authoritative. The config node doesn't make you smarter, it makes the mismatch impossible.

    One more thing worth knowing: secret_key is stored as plain text in the workflow JSON. ComfyUI embeds the full workflow into every PNG you save, so that key travels in the file's metadata anywhere the image goes. For a watermark scheme, the "secret" is a scrambling seed more than a password, but don't paste a production key into a public workflow and expect it to stay private.

    Installing

    It ships with the pack, so one install gets you all four nodes:

    cd ComfyUI/custom_nodes
    git clone https://github.com/zhangp365/comfyui-dit-watermark
    

    Restart ComfyUI, or use Manager's search for comfyui-dit-watermark. No models to download, no pip installs - the pack only depends on ComfyUI's bundled PyTorch.

    The one gotcha

    Once you generate watermarked images with a given config, don't change it. The detector rebuilds its layout from this same node, so any tweak means old images fail to decode. If you ever need to rotate keys or widen the band, that's a new config, and old watermarks belong to the old one. Keep one GROW Watermark Config per workflow and treat its values as part of your provenance record.

    CategoryGROW/watermark

    Inputs (6)

    NameTypeDefaultDescription
    secret_keySTRINGwatermark—
    dct_minFLOAT0.150–0.95—
    dct_maxFLOAT0.450.01–1—
    max_channelsINT81–256—
    channel_startINT40–255First latent channel in the contiguous profile.
    center_ratioFLOAT1.000.25–1—

    Outputs (1)

    NameTypeDescription
    configGROW_CONFIG—