Nodes/SDXL Auto Prompter/APNext H3 Scene Counter
ComfyUI Node

APNext H3 Scene Counter

The APNext H3 Scene Counter

By dagthomas·Created 3 years ago·Updated 12 days ago· 290
APNext H3 Scene Counter
    • status
    • remaining
    index
    count

    This is a tiny output node and it knows it. No LLM, no model files, no API - it takes two numbers and shows you a big "Scene 3 of 8 - 5 remaining" readout on the canvas, updated every run. If you've ever sat through a 24-scene render queue wondering which clip the machine is on, you get the appeal immediately.

    Where it fits

    The pack's multi-scene H3 writers (Presentation Writer, Crossover Writer, Scenes Writer, Music Video) output a scenes list. You can render the whole list in one queue, but when you're iterating on a single scene - polishing one shot without paying for the other 23 - the intended pattern is the H3 Scene Pick node: it collapses a scenes list to one element by a 0-based index, so you fix the writer's seed and step the index to render scenes one at a time. That's exactly the workflow this counter is built for. Wire Scene Pick's index and count outputs into the counter and you get a live "where am I in this run" display instead of counting clips yourself.

    What you wire in

    • index - the 0-based index of the scene being rendered (H3 Scene Pick's index output).
    • count - the total number of scenes (Scene Pick's count, or any writer's scene_count).

    Both are forced inputs, so you connect them rather than typing. That's the whole input list. Under the hood it computes done = min(index + 1, count) and remaining = count - done, then formats the status line. The readout itself is rendered by a small JS file, which is why it looks like a proper widget rather than a text value.

    The outputs

    Two, both modest: status (the "Scene X of N - M remaining" string) and remaining (the integer). The status text is also printed to the ComfyUI console on every run. Honestly, the sockets exist so you can do something slightly clever with them - building remaining into a filename, or feeding a node that decides what to do when the count hits zero - but for most people the value is purely the on-node display. There's no real troubleshooting here: if the readout looks wrong, check that your index is actually stepping between runs (a fixed seed with no cache-busting will keep rendering the same scene), and remember the index is 0-based while the display counts from 1.

    Installing it

    It's part of the dagthomas/comfyui_dagthomas pack - ComfyUI Manager, search "comfyui_dagthomas", or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/dagthomas/comfyui_dagthomas
    cd comfyui_dagthomas
    pip install -r requirements.txt
    

    then restart ComfyUI. You'll find it under the APNext → H3 category. It won't appear anywhere unless you're already running the pack's pick-one scene workflows, and that's fine - it's a dashboard, not a generator. The example workflows h3_scenes_pick_one.json and h3_crossover_pick_one.json ship with it wired in, so the easiest way to see it earn its keep is to load one of those.

    Categorycomfyui_dagthomas/H3

    Inputs (2)

    NameTypeDefaultDescription
    indexINT0-based index of the scene being rendered (H3 Scene Pick's `index` output).
    countINTTotal number of scenes (H3 Scene Pick's `count` or a writer's `scene_count`).

    Outputs (2)

    NameTypeDescription
    statusSTRING
    remainingINT