Dwpose Tensorrt ⚡
DWPose on TensorRT
- images
- yolox_trt_model
- dwpose_trt_model
- IMAGE
If you've ever run the stock DWPose preprocessor from ControlNet Aux on a video, you know the pain: one person estimate every second or two, and a 15-minute video turning into an hour of preprocessing. This node is the same DWPose - better hand tracking than plain OpenPose, whole body plus face and hands - but compiled to NVIDIA TensorRT engines, and it chews through frames at roughly 20 FPS on a 4090 or L40s. Same skeletons, a fraction of the wall time. That's the whole pitch, and it holds up.
What it actually is
DwposeTensorrt is one half of the ComfyUI-Dwpose-Tensorrt pack by yuvraj108c, who's made a little empire of these TRT-accelerated ports (Depth Anything, RIFE, an upscaler). It's the execution node: you feed it images and it hands back a pose skeleton map that you wire straight into an OpenPose-style ControlNet. The detection itself is two-stage - a YOLOX model finds the people in the frame, then the dw-ll_ucoco_384 model estimates body, face, and hand keypoints for each detected box. Both stages run as pre-built TensorRT engines, which is where the speed comes from; the ONNX fallback path the Aux pack uses often limps along on CPU, which is exactly the failure people hit with it.
It's not a drop-in replacement for nothing - you still need the ControlNet + pose-conditioned checkpoint on the other side - but it is a drop-in replacement for the slow preprocessing step.
The inputs that matter
The node takes five required inputs, and only three of them are worth touching:
- images - your batch of frames (works on video batches, not just stills).
- yolox_trt_model / dwpose_trt_model - these come from the pack's
LoadDwposeTensorrtModelsnode. Wire those two outputs in and forget about them. - show_body, show_hands, show_face - all default to
true. If your ControlNet only cares about the body skeleton, flip hands/face off; the output gets cleaner and marginally faster.
Output: a single IMAGE of the drawn pose map. It feeds the ControlNet openpose preprocessor input. Because the outputs are just images, you can preview them or save them - useful when you're iterating on a video and don't want to re-run detection every tweak.
How to install it
Through ComfyUI Manager (search "ComfyUI-Dwpose-Tensorrt"), or the old-fashioned way:
cd ComfyUI/custom_nodes
git clone https://github.com/yuvraj108c/ComfyUI-Dwpose-Tensorrt
cd ComfyUI-Dwpose-Tensorrt
pip install -r requirements.txt
Then restart ComfyUI and add the node via Right Click → tensorrt → Dwpose Tensorrt. It needs NVIDIA TensorRT 10, CUDA 12.4, and Python 3.10 per the README - the pack is tested on Ubuntu, and Windows is officially "not tested, but should work."
Where people get burned
The number-one failure is ModuleNotFoundError: No module named 'tensorrt' at load time. Nine times out of ten that means pip install ran into the wrong Python - the bane of the ComfyUI portable install, which has its own venv. Install the requirements into that environment (Manager usually handles this correctly), not your system Python. Also note the heavy bits: on first run, the pack downloads two ONNX models from HuggingFace (yolox_l.onnx and dw-ll_ucoco_384.onnx) and compiles TensorRT engines, which takes a few minutes and a chunk of VRAM. Let it finish. If you change precision later, it rebuilds - that's expected, not a hang.
Inputs (6)
| Name | Type | Default | Description |
|---|---|---|---|
| images | IMAGE | — | |
| yolox_trt_model | YOLOX_TRT_MODEL | — | |
| dwpose_trt_model | DWPOSE_TRT_MODEL | — | |
| show_face | BOOLEAN | true | — |
| show_hands | BOOLEAN | true | — |
| show_body | BOOLEAN | true | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |