Nodes/Avatar Graph/Object Call Find Armature
ComfyUI Node

Object Call Find Armature

Locating the rig behind a mesh

By avatechai·Created 3 years ago·Updated 2 years ago· 264
Object Call Find Armature
  • BPY_OBJ
  • BPY_OBJ

ObjectCall_FindArmature is a rigging-pipeline primitive tucked into Avatar Graph's (avatechai/avatar-graph-comfyui) tail of raw bpy.types.Object API wrappers. The pack's headline job is rigging a still character portrait into a live, blinking, lip-syncing 2D avatar; this node isn't part of that documented workflow, but the question it answers - "given a mesh, what skeleton is driving it?" - is a real one for any script working across multiple, differently-built avatar characters.

How it works

It maps to Object.find_armature(), documented as: "find armature influencing this object as a parent or via a modifier." Blender walks the object's parent chain and its Armature modifier stack looking for a linked Armature object - the skeleton of bones that a rigged mesh deforms against - and hands it back if one exists.

Why you'd reach for it

Useful if you're writing logic that needs to work across many avatar characters without hardcoding each one's rig name - find the armature programmatically instead of assuming you already know it. Worth knowing going in, though: Avatar Graph's own default pattern is shape-key driven (that's what "Shape Flow" actually animates), not Armature-bone driven. A typical avatar built with this pack's documented workflow may well have no Blender Armature at all, in which case this call comes back empty - it's a Blender rigging primitive more than a fit for how this specific pack usually builds its rigs.

Inputs and outputs

Just one optional BPY_OBJ input, one BPY_OBJ output. In real Blender, find_armature() returns the found Armature object, or None if there isn't one - but that result doesn't surface as a separate wire here, only the original mesh object passes through unchanged. There's no way from this node alone to tell whether it found an armature or came back empty.

Installing it

Avatar Graph pulls in Blender's bpy module as a dependency, which makes it a real install rather than a drop-in. On Windows, use the author's bundled Python 3.10 environment (linked in their README), unzipped into your ComfyUI folder and launched via the included .bat, then install "Avatar Graph" from ComfyUI Manager. On macOS/Linux, pin your ComfyUI environment to Python 3.10.x exactly - conda is the cleanest way (conda create --name comfyui python=3.10). Then cd ComfyUI/custom_nodes, git clone https://github.com/avatechai/avatar-graph-comfyui.git (their README's own manual-install command points at a stale org, avatechgg - the repo lives under avatechai). cd avatar-graph-comfyui && python -m pip install -r requirements.txt, then restart with python main.py --enable-cors-header (Mac: also --force-fp16). That flag opens CORS so the hosted viewer at editor.avatech.ai can talk to your local ComfyUI; skip it if you're exporting .glb/.gltf from Avatar Main Output instead.

Common issues

Python-version mismatch is where most people get stuck first - bpy needs 3.10.x specifically. Specific to this node: if you're testing it against a typical Avatar Graph output and it seems to "not work," check whether your character is actually shape-key driven rather than armature-driven first - that's the expected case for this pack's own documented pipeline, and it means there's genuinely nothing for this node to find. As with the rest of this batch, there's no author documentation for it - this description comes from Blender's own Object.find_armature() API docs.

Categoryblender

Inputs (1)

NameTypeDefaultDescription
BPY_OBJoptBPY_OBJ

Outputs (1)

NameTypeDescription
BPY_OBJBPY_OBJ