Nodes/ComfyUI-aihub-workflow-exposer/AIHub Expose Image (Info Only)
ComfyUI Node

AIHub Expose Image (Info Only)

Same image expose, minus the pixels — for when you only need to know where it is

By otavanopisto·Created about a year ago·Updated 22 days ago· 7
AIHub Expose Image (Info Only)
    • POS_X
    • POS_Y
    • LAYER_ID
    • WIDTH
    • HEIGHT
    idexposed_image
    labelImage
    tooltip
    typeupload
    index0
    optionalfalse

    AIHub Expose Image (Info Only) is the sibling of AIHubExposeImage with the pixels stripped out. Same type options, same canvas-layer semantics - it just doesn't hand you the IMAGE or MASK. What you get back is geometry only: POS_X, POS_Y, LAYER_ID, WIDTH, HEIGHT.

    Why would you want that? Because sometimes you don't need to process the image contents - you need to know where it is so you can place something else there. Say your workflow generates a new texture or a background and you want to composite it back into the editor exactly where the current layer sits. One Info Only node tells you the layer's canvas position and size; the AIHub action nodes that write results back (like AIHubActionNewLayer) can use those coordinates to drop the new layer in the right spot. It's also handy as a cheap "is this layer even present" check: if optional is on, a missing image just yields zeros rather than aborting the run.

    What you set

    The inputs are the same as the full image expose, so the pattern is familiar:

    • type - the image source, defaulting to upload. The seven options mirror the full node: current_layer, merged_image, current_layer_at_image_intersection, the *_without_current_layer variants, and upload. Since you're only getting placement data, current_layer or merged_image is the pragmatic choice - the intersection variants matter when you need to reason about exactly what region a flattened canvas covers.
    • id / label / tooltip - the protocol identity and the human-facing name, same as every expose.
    • optional - with it true, a missing image won't raise; you'll get zeros instead of geometry.

    That's honestly the whole node. It's one of the thinnest in the pack, and it's not trying to be more.

    Install & gotchas

    Same story as the rest of the pack - ComfyUI Manager → search ComfyUI-aihub-workflow-exposer, or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/otavanopisto/ComfyUI-aihub-workflow-exposer
    

    then restart ComfyUI. No extra Python dependencies (no requirements.txt), no model files. Remember the AIHub folders (ComfyUI/aihub/...) and an AIHubWorkflowController with a unique id.

    The one real gotcha is the same as its sibling: in the bare web UI this node has nothing to expose. The data only arrives when an AIHub client connects over the websocket (port 8111) and runs the workflow with a value for this expose. If you need both pixels and position, use the full AIHubExposeImage - the info-only variant is purely the cheap geometry read, and mixing them up is a classic way to end up with a workflow that silently has no image input wired anywhere.

    Categoryaihub/expose

    Inputs (6)

    NameTypeDefaultDescription
    idSTRINGexposed_imageA unique custom ID for this workflow.
    labelSTRINGImageThis is the label that will appear in the field.
    tooltipSTRINGAn optional tooltip
    typeCOMBOuploadThe source of the image
    indexINT0This value is used for sorting the input fields when displaying; lower values will appear first.
    optionalBOOLEANfalseIf set to true, it will not raise an error if the image is not found

    Outputs (5)

    NameTypeDescription
    POS_XINT
    POS_YINT
    LAYER_IDINT
    WIDTHINT
    HEIGHTINT