Load InstantHMR Model:
The InstantHMRLoader node, displayed as “Load InstantHMR Model” in the image/detection category, prepares an InstantHMR model for use in a human mesh reconstruction workflow. InstantHMR is used to estimate a three-dimensional human body representation from image content; this loader handles model preparation rather than analyzing images or producing a body mesh itself. It reads saved model weights, builds the corresponding model architecture, and checks that the weights match that architecture. It also integrates the model with ComfyUI’s device and memory management, allowing ComfyUI to choose an appropriate computing device and numerical precision for your setup. This provides a ready-to-connect model for compatible InstantHMR processing nodes without requiring you to configure hardware placement or precision manually.
Load InstantHMR Model Input Parameters:
model_file
Required COMBO parameter that selects the InstantHMR model checkpoint to load. Its options come from the files registered in ComfyUI’s “detection” model category, so the available choices depend on your installed files and configured model search paths; the source does not provide a fixed list of filenames or an explicit default selection. Minimum and maximum values do not apply because this is a file selection rather than a numeric setting. Your choice determines the model weights and the backbone architecture constructed from those weights, making checkpoint compatibility essential. A file appearing in this list is not necessarily an InstantHMR checkpoint: the category may also contain other detection-related models. The loader reads the selected file with safe loading enabled and requires its saved weights to match the constructed InstantHMR model exactly. An unrelated, incomplete, or incompatible checkpoint can therefore prevent the node from completing.
Load InstantHMR Model Output Parameters:
instanthmr_model
An output of type INSTANTHMR_MODEL containing the loaded InstantHMR model wrapped in ComfyUI’s model-management system. You can connect it to a compatible input expecting this model type, such as the model input of an InstantHMR prediction node. This output represents a prepared inference model, not a rendered image, a body mesh, or a prediction result; a downstream processing node must use it to perform reconstruction. Internally, the wrapper records the model’s execution device, offload device, and estimated size so ComfyUI can manage its placement and memory use. The effective model precision is selected automatically from supported floating-point types, with manual casting applied where ComfyUI determines it is needed. You do not need to interpret or edit the output’s internal contents.
Load InstantHMR Model Usage Tips:
- Select a checkpoint specifically intended for InstantHMR. The dropdown lists files from the shared “detection” model category, so choosing a detector checkpoint simply because it appears in the list will not make it compatible.
- If your checkpoint is missing from the dropdown, confirm that it is stored in a directory registered for ComfyUI’s “detection” category. Refresh the available model choices or restart ComfyUI after adding the file.
- Connect the model output to a compatible InstantHMR processing node to perform reconstruction. Running the loader alone only prepares the model and does not analyze an image.
- Let ComfyUI manage device placement and precision. This node has no separate device, precision, or memory controls; it automatically considers the checkpoint’s weight type and your available hardware, using supported float16, bfloat16, or float32 execution settings.
- If memory is limited, reduce other active model workloads before loading or using InstantHMR. ComfyUI’s offloading support helps manage memory, but it does not guarantee that every checkpoint and workflow will fit on your hardware.
- If you also use InstantHMR Live Capture, remember that its live inference is paused while a workflow runs to avoid conflicts involving shared models. That pause is a live-capture safeguard, not evidence that this loader failed.
Load InstantHMR Model Common Errors and Solutions:
Selected model file cannot be found
- Explanation: This is a descriptive error category rather than a fixed message defined by the node. The loader requires the selected filename to resolve to an existing file in the registered “detection” paths. A renamed, moved, or deleted checkpoint, or a stale dropdown selection, can cause path resolution to fail.
- Solution: Confirm that the checkpoint still exists in a registered detection model directory, refresh the model list or restart ComfyUI, and select the file again. Check your configured search paths if you store models outside the standard installation directories.
Error(s) in loading state_dict for InstantHMR
- Explanation: This is typical PyTorch wording for a model-weight compatibility failure. The loader uses strict matching, so missing weights, unexpected weights, or incompatible tensor dimensions are not silently ignored. Additional details may include “Missing key(s)”, “Unexpected key(s)”, or “size mismatch”.
- Solution: Choose an InstantHMR checkpoint compatible with your installed extension. Do not substitute a detector or another model family’s checkpoint. If necessary, obtain a compatible checkpoint from the extension’s documented source and follow any version requirements provided there.
Checkpoint loading fails before the model is created
- Explanation: This is a descriptive error category; the exact message comes from ComfyUI or the underlying file-loading library. A damaged download, unsupported file contents, or a file that is not a usable model checkpoint can prevent the saved weights from being read. The node enables safe loading, so some serialized contents may also be rejected.
- Solution: Verify that you downloaded the actual model file rather than a webpage or placeholder, check the download’s completeness, and download it again from a trusted source if needed. Use the checkpoint format recommended for the extension rather than disabling safe loading.
KeyError while interpreting checkpoint weights
- Explanation: A missing-key error can occur while the loader examines the checkpoint to construct its backbone, before the final strict weight check. The exact missing key depends on the checkpoint and implementation; the supplied code does not define a fixed message. This can indicate that the selected file does not contain the expected InstantHMR weight structure.
- Solution: Check that you selected the correct model rather than another file from the shared detection category. If it is an InstantHMR checkpoint, verify that its version is supported by your installed extension.
CUDA out of memory
- Explanation: This is typical wording for insufficient available NVIDIA GPU memory. It may occur during model setup or later when a connected node uses the model. Automatic precision selection and offloading reduce the need for manual configuration, but cannot eliminate hardware memory limits.
- Solution: Close other GPU-heavy applications, reduce simultaneous model workloads, and use ComfyUI’s available memory-management settings. If memory remains occupied after a failed run, restarting ComfyUI may help release it. This loader has no direct image-size or batch-size setting.
Device or floating-point type is not supported
- Explanation: This is a descriptive category for hardware or software compatibility failures; exact messages vary by backend. Although the loader asks ComfyUI to choose appropriate operations and precision, an incompatible PyTorch build, outdated drivers, or limited backend support can still prevent model setup or execution.
- Solution: Verify that your ComfyUI installation, PyTorch build, and hardware drivers are compatible with your device. Follow the extension’s documented installation requirements and keep ComfyUI and the extension on mutually compatible versions. There is no precision override in this node’s interface.
