Nodes/Melite Kimodo Nodes/πŸ§β†’1 Select Person Β· estimator β†’ one GLB
ComfyUI Node

πŸ§β†’1 Select Person Β· estimator β†’ one GLB

The two-widget node that stops you wiring a string of file paths into a node that wants one

By JayDataEngineerΒ·Created 2 months agoΒ·Updated 5 days agoΒ· 1
πŸ§β†’1 Select Person Β· estimator β†’ one GLB
    • glb_path
    β—„mesh_pathsβ–Ί
    β—„index0β–Ί

    The Multi-HMR 2 node detects people in a photo and hands you their meshes as one ;-joined string - one GLB per person, in detection order. Character assembly wants one path, not a list. This node is the seam between those two facts, and it's deliberately boring.

    It takes mesh_paths (wire it from MultiHMR2ImageToAnny.mesh_paths) and an index, and returns a single glb_path. That's it. Two widgets, one output, no model, no checkpoint, no inference.

    You'd think a node that just splits a string is the kind of thing you could leave out of the graph, and for a one-person photo you could - the string happens to contain exactly one path. Wire it anyway when there's any chance of a second person in frame, because the useful thing here isn't the picking, it's the refusal.

    Why the refusals are the feature

    Both failure paths raise instead of guessing. Empty input (estimator returned no mesh paths) tells you the upstream run detected nobody. An index beyond the number of people detected raises and prints the whole detected list - so if you asked for person 3 in a photo with two people, you find out which two before you start debugging the wrong thing.

    That's a small thing that saves real time, because the alternative is the classic silent-string failure: index out of range quietly yielding an empty path, then a downstream node erroring about a missing file, four nodes away from the cause.

    index runs 0 to 64 and follows detection order, not left-to-right in the frame. In practice that means the model's ordering is the ordering, and you shouldn't assume person 0 is the person on the left. If the wrong body comes out, change the index - don't re-run the whole estimator.

    Install

    Nothing extra. It ships with the pack, has no dependencies of its own, and never touches a model file:

    cd /path/to/ComfyUI/custom_nodes
    git clone https://github.com/JayDataEngineer/melite-kimodo-nodes.git
    cd melite-kimodo-nodes
    pip install -r requirements.txt
    

    Restart ComfyUI. If you're using ComfyUI Manager instead, search melite-kimodo-nodes and install the pack - this node comes along with the other seven.

    What you wire next

    glb_path goes into AnnyGroundBody's glb_path input. That's the step that matters more than this one: the estimator's meshes are in OpenCV camera space, with the person floating at camera distance, so a body straight out of MultiHMR2ImageToAnny is upside down and hovering unless something grounds it. AnnyGroundBody flips it, drops it onto y=0 and centres it.

    One caveat on the whole chain: the meshes here are estimator output, not modelled topology. The pack's own source says out-of-range selection refuses rather than truncating, but nothing fixes a bad detection - a partially occluded person gives you a bad body no matter which index you pick. Re-shoot or crop the photo instead of fighting the fit.

    CategoryMelite/Anny

    Inputs (2)

    NameTypeDefaultDescription
    mesh_pathsSTRING';'-joined GLB paths β€” wire MultiHMR2ImageToAnny.mesh_paths
    indexINT00–64Which detected person (detection order, 0 = first)

    Outputs (1)

    NameTypeDescription
    glb_pathSTRINGβ€”