ComfyUI Node

✋ Hand Tracking

Working MediaPipe hands and a gesture detector that's simpler than it looks

By kanibus·Created about a year ago·Updated about a year ago· 5
✋ Hand Tracking
  • image
  • hand_landmarks
  • annotated_image
  • gestures
  • confidence
max_hands2
detection_confidence0.50
enable_gesturestrue
smoothing0.50
wan_versionauto
enable_t2i_adaptertrue
cache_resultstrue

Real node number four. HandTracking in the kanibus/kanibus pack is another genuine MediaPipe wrapper: it detects hands, returns 21 landmarks per hand, draws them, and throws in a gesture label for good measure. It's not the most sophisticated hand tracker in the ComfyUI ecosystem, but it works, and in a repo full of placeholder stubs (Claude-generated, last commit Aug 2025) working is the headline feature.

How it works

It runs MediaPipe Hands on your frame and pulls 21 landmarks per hand - the standard 21-point hand topology (wrist, thumb joints, four fingers at 3 points each) - scaled to pixel coordinates with a per-landmark z value. Landmarks come back as a list of 21×3 arrays, one per detected hand, as the hand_landmarks output. It draws circles on each point in the annotated_image, and if enable_gestures is on, runs a finger-count heuristic (_recognize_gesture) that labels the pose - open palm, fist, pointer, and friends. The gestures output is a comma-joined string.

The inputs are the three you'd expect:

  • max_hands (1–4, default 2) - how many hands to track. More hands costs more compute.
  • detection_confidence (0.1–1, default 0.5) - lower on blurry video, higher to cut false detections.
  • enable_gestures (default on) - toggles the gesture labeling.

confidence per output is an average of per-hand placeholders (0.8 per hand) - treat it as "a hand was found," not a quality score. smoothing is declared but effectively inert in the shipped code.

How it fits

Hand landmarks are the standard input for hand-ControlNet work, and the annotated image is your visual check. Same caveat as the pack's pose node: its own MultiControlNetApply doesn't actually apply any control (it returns the model unchanged), so for real hand-pose-to-generation you'll want to take annotated_image and feed it to a standard OpenPose/hand ControlNet stack. If you're here for the eye tracking, hands are a bonus channel - useful for full-body consistency in video work.

Installing

cd ComfyUI/custom_nodes
git clone https://github.com/kanibus/kanibus
cd kanibus    # lowercase - README's "cd Kanibus" fails on Linux/Mac
pip install -r requirements.txt   # or requirements_minimal.txt if it clashes
python install.py

Restart ComfyUI, find it under Kanibus. MediaPipe's hand model auto-downloads on first use. The README's "MUST download ~5.6GB of ControlNet models" line doesn't apply - this node loads no such model.

Gotchas

  • Hands in frame, please. Like all MediaPipe detectors, it wants reasonable hands at reasonable size; tiny hands far from camera get missed.
  • max_hands is a cap, not a target. It returns however many it finds, up to the cap.
  • Gesture set is basic. The recognizer is a finger-count heuristic, so complex gestures (pinches, rotations, dynamic movement) come back as whatever finger-count label is closest. Don't expect ASL-grade recognition.
  • Stateful. Node-instance state persists between runs; restart ComfyUI if you're getting stale results across different workflows.

Net: if you've installed the pack and want hand landmarks without adding another custom node, this gets the job done. If you're picking one hand-tracking node for serious work, the ecosystem has deeper options - but this one is honest, functional, and free of the fake-output problem that plagues several of its packmates.

CategoryKanibus

Inputs (8)

NameTypeDefaultDescription
imageIMAGE
max_handsINT21–4
detection_confidenceFLOAT0.500.1–1
enable_gesturesoptBOOLEANtrue
smoothingoptFLOAT0.500–1
wan_versionoptCOMBOauto3 options: wan_2.1, wan_2.2, auto
enable_t2i_adapteroptBOOLEANtrue
cache_resultsoptBOOLEANtrue

Outputs (4)

NameTypeDescription
hand_landmarksHAND_LANDMARKS
annotated_imageIMAGE
gesturesSTRING
confidenceFLOAT