← Back to Leaderboard
CComfy-Org

Comfy-Org/comfy-aimdo

A PyTorch allocator that keeps model weights on the GPU as VRAM allows

View on GitHub ↗
Engineering Health (Methodology)
B+ · 69/100
Maintenance Activity
● Updated today
Latest Release
Rolling commits (main)
Commercial License Check
Custom / Check Repo

Automated SPDX check for reference only — not legal advice. Disclaimer

Maintenance35/35
Fork Adoption17/25
Release Cadence11/20
License Clarity6/20
GPULocal AI
Total Stars
★ 88
24h Growth
+0
7d Growth
+5
Forks
52

GitHub Star History

Full-history star trajectory from GitHub official history. Switch ranges or hover any point for exact counts.

Comfy-Org/comfy-aimdo Star History (2026-01-19 - 2026-12-04) ALL-TIME STAR HISTORY (2026-01 – 2026-12) +87 in 319d · avg +0/day 93 47 0 2026-01-19: ★ 12026-02-14: ★ 112026-03-07: ★ 202026-03-28: ★ 312026-04-18: ★ 342026-05-09: ★ 382026-05-30: ★ 432026-06-20: ★ 442026-07-11: ★ 482026-08-01: ★ 492026-08-22: ★ 562026-09-12: ★ 662026-10-03: ★ 682026-10-24: ★ 722026-11-13: ★ 752026-12-04: ★ 88 ★ 88 2026-01 2026-06 2026-12

Evidence-Backed Technical Brief

AI Deep Review

Architecture & Core Mechanics

AIMDO is a native PyTorch allocator extension for ComfyUI integration, not a standalone inference engine. The application reserves a per-model Virtual Base Address Register (VBAR) and places weight tensors within that range. Address reservation does not allocate physical VRAM; the application must call fault() before touching a weight. A successful call makes the weight accessible, and a new or changed signature tells the caller to refresh its contents. After the layer finishes using the weight, unpin() makes it eligible for eviction.

The native CUDA backend uses cuMemAddressReserve, cuMemCreate, and cuMemMap; the AMD backend follows the same design with HIP equivalents. The primary PyTorch allocator plugin uses the same reserve/create/map sequence, so the weight allocator must be evaluated alongside the primary allocator. The Python package is comfy_aimdo, and examples/example.py illustrates the application-side integration.

Key Capabilities & Differentiators

AIMDO adapts weight residency to available VRAM rather than requiring the application to assign a fixed quota to each model. Newer VBARs and lower addresses within a VBAR take precedence, so the order in which the application lays out weights matters. A higher-priority fault can evict lower-priority weights. Eviction establishes a watermark within the affected VBAR, so weights above it fail fast on later calls instead of repeatedly trying to regain residency.

prioritize() promotes an existing VBAR and resets its watermark, which is useful when a workflow returns to a partially resident model. If fault() fails, the application copies the weight into a temporary regular GPU tensor for the current layer and lets PyTorch reclaim it afterward. Integration is at the tensor level; no specific model family or weight-file format is established as a compatibility requirement.

Trade-offs & Limitations

Compared with ordinary PyTorch caching allocation, AIMDO adds an explicit policy for which model weights stay resident. Compared with application-managed offloading at fixed model boundaries, it adapts to pressure without per-model quotas, but requires the caller to manage tensor access, copy refreshes, and pin lifetimes. The fallback still needs space for a temporary GPU tensor and can pay the copy cost again on subsequent layer executions; it does not guarantee that a workflow will fit.

The key operational caveat is fragmentation: while weights are being offloaded, the primary PyTorch cache can keep receiving successful allocations, and AIMDO cannot distinguish heavy usage from poor cache layout. Clear the PyTorch cache before each new model run so idle reservations do not take precedence over incoming weights. No commercial substitute is identified. A LICENSE file exists, but the license terms are unspecified in the available metadata and should be checked before redistribution.

Hardware & Deployment Guide

The package requires Python 3.9 or later and uses setuptools.build_meta, with build requirements setuptools>=61.0, setuptools-scm>=8, and wheel. The runtime requires PyTorch 2.8+ and either CUDA 12.8+ for NVIDIA or ROCm 7+ for AMD. Listed OS support is Windows 11+ and Linux within Python's manylinux support. Check the OS, PyTorch build, and GPU runtime together rather than assuming that every OS/backend pairing has a ready-to-install binary.

The package includes native .so and .dll files as package data; the v0.0.0 release entry dated December 27, 2025 covers AIMDO binary dependencies. That release entry does not establish a complete binary distribution matrix. AIMDO runs locally without a separate inference service. Start with examples/example.py, then validate the target workflow under realistic memory pressure, including model switches and the temporary-tensor fallback path.

Virtual addressing: Per-model VBARs reserve GPU address space without allocating physical VRAM for the weights.
Layer integration: fault() maps weights on demand, signatures guide refresh copies, and unpin() makes weights eligible for eviction.
Fallback: A failed fault() routes the layer through a temporary regular GPU tensor rather than an unmapped weight.
Eviction policy: VBAR recency and weight address order set priorities; a per-VBAR watermark prevents repeated fault attempts above the cutoff.
Backend support: PyTorch 2.8+ with CUDA 12.8+ on NVIDIA or ROCm 7+ on AMD; Linux and Windows 11+ are listed.
Cache management: Clear the PyTorch cache between model runs so stale reservations do not take priority over incoming weights.
Best For

Local ComfyUI or PyTorch workflows where models compete for VRAM, the application can manage each weight's lifecycle, and temporary copies are an acceptable fallback.

Skip If

You need drop-in deployment with no application changes, the model already fits comfortably, or repeated weight copies would violate your latency budget.

Reviewed on 2026-12-03 · Grounded in GitHub README, root file tree & releasesMethodology

AI Context Briefing (for Claude / Cursor / Windsurf)

Standardized architecture summary & quickstart commands ready to paste into coding agents.

Raw .md ↗
curl -sL https://repoforai.com/repo/Comfy-Org/comfy-aimdo.md

Embed Star History Chart & Badges in README.md

Full-history Star History SVGs and velocity cards on GitHub Camo: drop-in replacement for OSSInsight and Star History widgets.

Comfy-Org/comfy-aimdo Star History on RepoForAI

Active README embeds unlock Hot-Tier 6h Telemetry Refresh automatically (zero pay-to-rank).

Frequently Asked Questions about comfy-aimdo

What must the PyTorch application do at each layer?

Reserve a VBAR and place weight tensors inside it in priority order. Before using a weight, call fault(). On success, copy the weight if the returned signature is new or has changed, then use it and call unpin() when finished. On failure, copy the weight into a temporary regular GPU tensor and use that instead. Never access an unmapped VBAR tensor.

Can AIMDO make a workflow fit on a 16 GB GPU?

Possibly, but 16 GB is not a compatibility guarantee. The GPU still needs enough headroom for activations, workspaces, and temporary copies of offloaded weights. Test the actual workflow and concurrency level, measuring peak VRAM and comparing rerun times; repeated copies can increase latency even when the workflow fits.

Can we run AIMDO locally and redistribute it commercially?

The allocator runs locally and does not require a remote inference API. A LICENSE file is present, but its terms are not identified here. Verify the applicable terms for both the source and distributed binaries before shipping AIMDO in a commercial product or container.

When should we prefer AIMDO over standard allocation or explicit offloading?

Start with the standard PyTorch allocator if weights already fit. Explicit weight offloading is preferable when you want the application to control placement directly at known model boundaries. AIMDO is worth testing when residency should adapt to changing VRAM pressure and the application can manage the fault()/unpin() lifecycle.

Upstream README & Documentation

This profile focuses on independent engineering analysis and live telemetry. Read the full upstream README, changelog, and examples directly on GitHub.

Maintaining Comfy-Org/comfy-aimdo? Pin to Homepage + competitor /alternatives pages with a custom Cloud/Demo CTA.Feature Comfy-Org/comfy-aimdo on Homepage & Alternatives ($19)
WEEKLY BREAKOUT DIGEST

Top 10 Breakout Open-Source AI Repos, Every Thursday

Signal-only digest of fast-growing AI repos, SPDX license alerts, and architecture picks. Zero spam.

Zero spam · 1-click unsubscribe · Privacy Policy

Saved in your browser · Export Markdown RFC tables or jump into /vs compare