cd /news/artificial-intelligence/one-more-measured-note-for-diffusers… · home › topics › artificial-intelligence › article
[ARTICLE · art-178055] src=discuss.huggingface.co ↗ pub= topic=artificial-intelligence verified=true sentiment=↑ positive

One more measured note for diffusers — named containers never hook as blocks

Hugging Face merged diffusers pull request #15409 on November 28, 2026, which warns on and ignores redundant ModuleList names so group offloading preserves child grouping, fixing issue #15386. In a test on a Tesla T4 with three FP32 Linear/Tanh blocks in one container and two in another, released 0.43.0 registered 2 groups and 2 group-hook entries that hooked only the two containers, while the fixed revision registered 5 groups and 5 entries that hooked the five children, with onload/offload method calls rising from 0/0 to 5/5 and output matching a no-offload reference at a max absolute difference of 0.0 across three forwards. The tested fix was revision ffd566461df1ab130c46bee8b0131469bcc756ed, not the released wheel; the latest release on November 29 was still 0.43.0 from November 12.

recommendation

Use automatic block grouping for ordinary ModuleList blocks and drop redundant list names; diagnose with a fresh model, block_level, group size one and use_stream=False, then verify repeated forwards match a no-offload reference before measuring memory or speed.

more in playbook: Inference and self-hosting
read3 min views3 publishedNov 29, 2026

In addition to counting the groups, I also checked whether the hooks actually fired and compared the outputs:

I tested the three-plus-two-block selection difference with real Diffusers hooks on a small CUDA model.

PR #15409, addressing issue #15386, merged on November 28, 2026. It warns and ignores redundant ModuleList names, preserving child grouping. Named Sequential modules still take the explicit selection path.

On a Tesla T4 I used three FP32 Linear/Tanh blocks in one container and two in another, not a FLUX checkpoint. Both names were supplied, with group size one and streams enabled.

Observation Released 0.43.0 With the ModuleList change
Unique groups / registered group-hook entries 2 / 2 5 / 5
Hook locations The two containers The five children
Input and weight at the first block’s computation CUDA input, CPU weight Both CUDA
Onload / offload method calls during the first attempted forward 0 / 0 5 / 5
Output comparison against a no-offload reference Stopped at a device-mismatch check Max absolute difference 0.0 on each of three forwards

The failure was an explicit device check in my block immediately before Linear, not an uninstrumented PyTorch matmul exception. Transfer counts are real group method invocations, not every hook callback or a GPU copy trace. Both the functional-hunk variant and the fixed source gave the result on the right.

A directly called named Sequential already worked with two parent groups. Manually iterating its children bypassed those groups and triggered the guard. The actual call boundary matters.

The latest release on November 29 was still 0.43.0 (November 12). The tested fixed revision was ffd566461df1ab130c46bee8b0131469bcc756ed; it was not the released wheel.

Start with automatic grouping for ordinary ModuleList blocks. Removing redundant names avoids the old selection branch.

Omitting block_modules or setting None can select the model’s _group_offload_block_modules defaults; [] bypasses that fallback in the inspected versions. Preserve custom callable parent names that are actually needed.

Situation First thing I would try
Ordinary ModuleLists, no special parent selection needed Use automatic block grouping.
Pinned to 0.43.0 and supplying redundant list names Remove the redundant names; check whether a model default reintroduces them.
Model default only contains redundant lists An explicit empty list is a candidate on the old release; verify the resulting groups.
Model default also identifies real callable parent modules Preserve those deliberately selected parents; remove only the redundant list entries if needed.
Sequential or custom container is called as a unit A parent-level group can be intentional.
Children are called individually instead Prefer a grouping boundary that the real forward path reaches.

Start diagnosis with a fresh model, block_level, size one, and use_stream=False; repeat with streams at size one and multiple forwards once correct. Turning off streams does not fix the named-list selection problem.

See the memory optimization guide for configuration options.

The counting result therefore has an execution counterpart. The merged change restores child grouping for redundant ModuleList names; matching group ownership to actual execution and checking repeated reference parity are useful before measuring memory or speed.

── more in #artificial-intelligence 4 stories · sorted by recency
── more on @hugging face 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
→ Live at https://your-agent.zahid.host ✓
Get free account → Pricing
from €0/mo · no card required
LIVE [news/one-more-measured-no…] indexed:0 read:3min 2026-11-29 · —