Commit Graph
55 Commits
Author SHA1 Message Date
John Pollock e507f854d7 Fix to #178 2026-03-20 22:15:30 -05:00
John Pollock b526e111b2 Fix DLPack CPU staging constraint fallback for issue #167/#177 2026-03-17 17:53:00 -05:00
John Pollock 36e5c9eb1f Set version to 2.6.0 = basic DynamicVRAM compatibility and bug/compatibility fixes 2026-03-06 09:00:15 -06:00
John Pollock 0b438f7a8b Refactor code for improved readability and performance
- Cleaned up unnecessary whitespace and comments in model_management_mgpu.py, nodes.py, wanvideo.py, and wrappers.py for better code clarity.
- Replaced list comprehensions with direct list conversions in nodes.py for efficiency.
- Updated memory logging format in model_management_mgpu.py to streamline data capture.
- Enhanced device management in wanvideo.py by ensuring consistent device setting and loading.
- Added linting configurations in pyproject.toml to enforce code quality standards.
- Removed unused imports and optimized existing ones across multiple files.
2026-03-06 05:59:12 -06:00
John Pollock c5e3e6a215 build: update to 2.5.11 based on bug fixes for latest comfy changes 2026-01-02 22:54:25 -06:00
John Pollock 75d96a237f Fix #119 and #130 - RES4LYF sampling errors 2025-10-15 21:39:00 -05:00
John Pollock 6e5225e6c9 Increment revision to 2.5.9 2025-10-15 14:53:39 -05:00
John Pollockandmax-solo23 0473c2a72a PR #128 - Improving GGUF model compatibility with DisTorch2 - Bump revision to 2.5.8
Co-authored-by: max-solo23 <maksym.solomyanov@gmail.com>
2025-10-14 13:57:25 -05:00
John Pollock a24f0a6e87 hotfix: Corrects for corner case when DisTorch VirtualVRAM=0.0 GB (previous refactor shunted to standard loader. This replicates that required logic across all nodes using DisTorch2 for allocations. Next time I will wait for the final test work flow to finish VAE conversion (where is the only place I test this.) 2025-10-13 22:08:05 -05:00
John Pollock edd1bbf8f4 Prepare for #125 release 2025-10-13 19:37:24 -05:00
John Pollockandmax-solo23 bdd612c619 hotfix: #124 - fix for CLIPTextEncode error: ‘GGUFModelPatcher’ object has no attribute ‘model_patches_models’.
Co-authored-by: max-solo23
2025-10-13 13:44:34 -05:00
John Pollock 2143a281b7 hotfix: WanVideoWrapper Wan2.2 I2V workflow corrections 2025-10-13 03:59:45 -05:00
John Pollock 5310d4a28d Update documentation and example workflows to match Comfy guidelines 2025-10-13 02:16:52 -05:00
John Pollock e31ba04f20 WanVideoWrapper updates to reflect reported changes (#118, #90) in the ComfyUI-WanVideoWrapper code base. Breaking changes. See example workflows. 2025-10-10 14:28:11 -05:00
John Pollock f60aa6a9a7 refactor: keep_loaded --> eject_models Boolean switch. Use it to eject all other models prior to loading model for inference; helpful to maximize available latent space on device prior to UNet inference, for example
So this is a change from something just newly-released in 2.5.0, but most should either see an improvement or no change to behavior. This was the weakest, and jankiest part of 2.5.0 and my decision to manage a CPU memory leak turned into a too-aggressive solution with unwanted side effects.

This solution should provide a better way to manage `compute` VRAM as the most asked-for feature is a way to remove everything else from VRAM prior to main UNet inference, which this accomplishes nicely, as well as reporting back accurate information DisTorch2 on-device shard sizes.
2025-10-04 17:42:52 -05:00
John Pollock 486a84e357 prep for final release candidate 2025-09-30 09:52:00 -05:00
John Pollock f7942dca93 Fix for (#104): drop text_encoder_initial_device patch and state - these were part of an attempt to solve a CLIP compute issue that was recently solved another way (Commit edc8a4d)
- Remove current_text_encoder_initial_device and its updates
- Delete text_encoder_initial_device_patched and stop overriding mm.text_encoder_initial_device
- Simplify set_current_text_encoder_device and logging to track only current_text_encoder_device

Bump revision to 2.4.7
2025-09-15 12:46:02 -05:00
John Pollock 80f8a14dea Fix non-deterministic behavior of CLIP compute device when ~100% offloading. 2025-09-14 14:59:01 -05:00
John Pollock d34a32f097 Fix for Triple/Quad Clip Loaders (#99) 2025-09-12 23:44:20 -05:00
John Pollock e9fb4a8c2f Hot FixL: Revert aggresive memory management until a more targeted approach can be developed. This was causing OOMs on models that should load normally using the normal loader.
Update version to 2.4.4.
2025-09-10 18:24:12 -05:00
John Pollock e1635e9996 Improve memory handling for safetensor models in corner cases
- Added preemptive model unloading and cache clearing in register_patched_safetensor_modelpatcher() to resolve potential memory issues when allocations are unavailable, prompting the usage of the standard loaders.
2025-09-09 12:00:56 -05:00
John Pollock 803cf542d9 MultiGPU garbage collection/cache clearing and DisTorch2 Clip device node bug 2025-09-08 23:10:54 -05:00
John Pollock 0adf219f60 Hot fix for (https://github.com/pollockjj/ComfyUI-MultiGPU/issues/99). It might not be 100% but will prevent error and I will revisit to ensure 2025-09-02 07:51:30 -05:00
John Pollock 54b7c5b0e6 Advanced Checkpoint and Advanced DisTorch2 Checkpoint loaders (https://github.com/pollockjj/ComfyUI-MultiGPU/issues/95), Fix CLiP loading device when MultGPU or DisTorch2 is invoked.
Advanced Checkpoint Loaders allow users to map each of the elements of the checkpoint to a different device, or in the case of DisTorch2, shard the UNet and CLiP .safetensors arbitrarily whilst ensuring actual computation remains on selected `compute` device.

Added example workflow for standard and DisTorch2 MultGPU checkpoint loaders.
2025-08-31 01:45:13 -05:00
John Pollock 4d0d4a673f fix for issue https://github.com/pollockjj/ComfyUI-MultiGPU/issues/87: ComfyU-MultiGPU not supporting all device types currently supported by Comfy Core.
Refactor device detection into dedicated utility module

- Extract device enumeration and compatibility checks to device_utils.py
- Add support for additional device types (NPU, MLU, DirectML, CoreX)
- Update all modules to use centralized device utilities
- Implement caching for device list to improve performance
- Reduce code duplication across distorch, nodes, and wanvideo modules
2025-08-30 07:39:26 -05:00
John Pollock 06bc2c3ac8 Fix for https://github.com/pollockjj/ComfyUI-MultiGPU/issues/96
Updated WanVideoWrapper nodes to reflect changes to kijai's nodes, e.g. issue #96 - WanVideoModelLoaderMultiGPU
2025-08-29 23:18:14 -05:00
John Pollock 0ca771fe68 Fix for : https://github.com/pollockjj/ComfyUI-MultiGPU/issues/93
Fix compute device inclusion in expert mode allocations

Include compute device in vram_string when expert_mode_allocations
is set but virtual_vram_gb is 0. This ensures the compute device is
properly specified in the full allocation string for expert mode
configurations without virtual VRAM.

Bump version to 2.2.1
2025-08-28 20:47:12 -05:00
John Pollock 6f5c4aa901 Preparing for 2.2.0 release (byte and ratio model allocation schemes) 2025-08-26 14:42:25 -05:00
John Pollock de00faaa3d Fixes for DisTorch V2 LoRA loading as well as sticky allocations when using standard loader 2025-08-24 06:01:07 -05:00
John Pollock 6e4181a7bb Refactor: Remove debugging and memory audit utilities
This commit removes several utility modules used for debugging, memory inspection, and hardware information gathering. These tools are no longer required and their removal simplifies the codebase.

The following files have been deleted:
- `debug_utils.py`
- `device_memory_audit.py`
- `hardware_info.py`
- `model_sig.py`

Additionally, the call to log memory usage on startup has been removed from `__init__.py`.
2025-08-15 08:25:18 -05:00
John Pollock d1c88a7cdb feat(distorch): Add universal .safetensors support & memory-based distribution
This commit introduces DisTorch v2.0.0, a major overhaul that extends multi-device model distribution to standard `.safetensors` models.

Key changes include:

- **Universal `.safetensors` Support:** The core distribution logic is no longer limited to GGUF models. It now fully supports `.safetensors`, allowing any UNet supported by native Comfy loaders to have its layers distributed across multiple devices (GPUs and CPU/RAM).
2025-08-14 08:17:15 -05:00
John Pollock 79e9230f4c fix(gguf): correct missing type enum for CLIPLoaderGGUF and DualCLIPLoaderGGUF
Populate 'type' options by sourcing from core nodes to avoid drift:\n- CLIPLoaderGGUF now derives 'type' from nodes.CLIPLoader.INPUT_TYPES()\n- DualCLIPLoaderGGUF now derives 'type' from nodes.DualCLIPLoader.INPUT_TYPES()\nThis fixes missing or outdated 'type' options in GGUF Single and Dual CLIP loaders.\n\nchore: bump version to 1.8.2
2025-08-08 01:36:59 -05:00
John Pollock 7a08dd97d5 feat: Experimental XPU support
Add guarded Intel XPU support alongside CUDA:
- get_device_list now includes xpu:N when available
- device selection (model/text encoder) considers CUDA or XPU and validates devices
- DisTorch donor/offload selection includes xpu devices
Also: remove unused MergeFluxLoRAs node and mapping; delete tools/ and precompiled_binaries/; bump project version to 1.8.1.
2025-08-07 16:22:53 -05:00
John Pollock a6f13e5ff3 feat: update README and pyproject.toml for enhanced WanVideoWrapper integration and version bump to 1.8.0 2025-08-06 17:58:07 -05:00
John Pollock a05823ff0a feat: add CLIPVisionLoaderMultiGPU support and update version to 1.7.3 2025-04-17 18:43:01 -05:00
John Pollock 4ff9b80286 feat: add QuadrupleCLIPLoader / QuadrupleCLIPLoaderGGUF support and update version to 1.7.2 2025-04-17 17:00:20 -05:00
John Pollock b0159761e2 feat: add support for 'pixart' and 'wan' types in CLIPLoaderGGUF to match core class; update version to 1.7.1 2025-03-24 05:38:44 -05:00
John Pollock 2d81ef0a21 Support for kijai's ComfyUI-WanVideoWrapper 2025-03-23 13:40:05 -05:00
John Pollock 1bf9333fc7 chore: update version to 1.6.2 and fix description formatting in pyproject.toml 2025-02-12 12:18:13 -06:00
John Pollock a2093a4fc9 feat: add text encoder device handling, whereas CLIP can sometimes default to CPU, whereas using a DisTorch CLIP load you can load the layes on CPU buy use CUDA for processing. Especially helpful llava-llama 2025-02-12 11:51:58 -06:00
John Pollock 62646d3ca3 Push Distorch 2.0 Virtual VRAM release out to Comfy Registry 2025-02-07 22:00:48 -06:00
John Pollock 3679c268ac 🔧 BREAKING CHANGE: DiffSynth functionality has been temporarily removed while investigating device management issue (Having two GPUs with different amounts of VRAM leads to OOMs pollockjj/ComfyUI-MultiGPU#13).
If you were using nodes with DiffSynth in their name (like ...DiffSynthMultiGPU), please switch to the standard MultiGPU versions for now (e.g., ...MultiGPU). This change eliminates a device management issue that was affecting some Windows users.

See: https://github.com/pollockjj/ComfyUI-MultiGPU/issues/13

Most users won't be affected as this only impacts the DiffSynth variants of nodes.

If you need help modifying your workflows, please open an issue. Will revisit DiffSynth functionality once issue can be contained or worked-around

Update comfyregistry to 1.5.0 to reflect major change in functionality, in this case, a reduction.
2025-02-06 00:32:21 -06:00
John Pollock 005b5b1882 This release includes an embeddings adapter for the IP2V part of kijai's CLIP loader for HunyuanVideo. See examples. Bump version to 1.4.3 and update category for HunyuanVideoEmbeddingsAdapter to multigpu; enhance README with new workflow examples for HunyuanVideo GGUF-quantized models. 2025-01-29 11:55:16 -06:00
John Pollock 185ecc2ab5 Push fix to check_module_exists() to Comfy Registry, thanks @3dluvr 2025-01-29 05:16:45 -06:00
John Pollock 41e974f086 1.40 -->1.4.1
Pop 1.4 (DisTorch) to Comfy Registry
2025-01-28 15:41:13 -06:00
John Pollock ff7329298c feat: Releasing Hunyuan Video UNet device split support. Update project description and bump version to 1.4.0 2025-01-15 09:26:42 -06:00
John Pollock 20ba9d099c fix: Bump version to 1.3.1 and update icon URL to raw GitHub link 2025-01-12 11:17:47 -06:00
John Pollock 92652cf816 feat: Update project description to include CPU device selection and bump version to 1.3.0; add icon URL for ComfyUI-MultiGPU 2025-01-12 11:08:41 -06:00
John Pollock 116dd935f2 chore: Rename publish workflow file and update version to 1.2.1 in pyproject.toml 2025-01-05 16:03:53 -06:00
John Pollock 4611332d12 chore: Bump version to 1.2.0 in pyproject.toml 2025-01-04 19:44:05 -06:00