Trim the comments across the diffusion backend
Comment-only pass over the Python this PR touches: drop what the code already says, collapse multi-line explanations that still read on one line, and keep the reasoning that is not recoverable from the code. No code, docstring semantics or behaviour changes; verified with an AST comparison against the previous revision, and the backend suite is unchanged (same 37 environment failures as before: the API integration tests that need a live keyed server, the flash-attn install hooks, and the GPU memory fields).
This commit is contained in:
parent
ea3c3822a1
commit
36df317293
113 changed files with 3389 additions and 4087 deletions
|
|
@ -45,8 +45,8 @@ def main() -> int:
|
|||
lins = [(n, m) for n, m in model.named_modules() if isinstance(m, torch.nn.Linear)]
|
||||
selected = [(n, m) for n, m in lins if m.in_features >= MIN and m.out_features >= MIN]
|
||||
print(f"\n### {label}: {len(lins)} Linear, {len(selected)} pass min_features={MIN}")
|
||||
# Heuristic: a modulation/embedder Linear is one OUTSIDE the repeated transformer blocks,
|
||||
# i.e. its fqn does not contain a numeric block index, OR out==k*in (k>=3) AdaLN shape.
|
||||
# A modulation/embedder Linear sits outside the repeated blocks (no numeric index in its fqn),
|
||||
# or has an AdaLN out==k*in (k>=3) shape.
|
||||
sus = []
|
||||
for n, m in selected:
|
||||
depth_idx = any(p.isdigit() for p in n.split("."))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue