Model menagerie#178
Merged
Merged
Conversation
…nstalled first) run_across_envs now supports per-env torch_pin + torch_index_url, installed BEFORE the editable torchlens install via --index-url (which forces the chosen CUDA wheels, unlike --extra-index-url). Fixes the cross-env failure where the torchlens install pulled torch 2.12+cu130 and frameworks (mmcv/detectron2/fla) then found no matching wheel. Validated: pinning torch==2.4.1+cu121 makes mmcv install from a wheel. Wired into the mmlab/detectron2/fla recipes; the torch pin now appears as the first install step.
Adds research-backed cross-env recipes (status=untested) for effdet, espnet, speechbrain, basicsr (basicsr-fixed), ppocr (paddleocr 2.10.0), ppdet (git@release/2.6, separate env), dgl (2.5.0+cu121, torch_pin 2.4.1), nemo (2.4.0 [asr], torch_pin 2.4.1), lerobot (py3.12, torch_pin 2.7.1), and gan (BigGAN/StyleGAN2 + wrapper). Uses the new torch_pin field for frameworks needing a specific torch. ~1,500+ dep-gated models now have an install path; the cross-env runner validates + records status/resolved_packages per env on --execute.
… post_install_commands hook Adversarial research cracked the OpenMMLab path: the mmdet/mmseg mmcv<2.2.0 cap is conservative (mmcv 2.2.0 is additive-only over 2.1.0 - only NPU ops). torch 2.4.1 + mmcv 2.2.0 wheel + spoofing mmcv.__version__->2.1.0 via a sitecustomize.py lets the full stack import; real compiled ops work vs torch 2.4.1 (CUDA nms verified). Proven end-to-end: RetinaNet/FCOS/FCN/PSPNet/DeepLabV3/SegFormer/ ResNet50 instantiate+trace. Adds a post_install_commands hook to run_across_envs (post-install bash steps in the env) used to write the spoof; mmlab env_specs wired (torch_pin 2.4.1 + numpy<2 + mim stack + spoof). No torchlens changes, no per-recipe changes.
… codex waves) Categorized all 6,911 non-rendered models by exact blocker, then dispatched 6 focused ~242-row codex waves on the FAILED_EXC base-env recipe bugs (assign-model / NameError / undefined-class / syntax / shape-dtype). 981/1,452 repaired + verified (instantiate + trace) in py311; 97 routed to cross-env (needs-env), 19 flagged as torchlens-bug candidates. Chunked ~250 waves succeed where the earlier 1,000+-row single waves bailed.
…arkers
The menagerie builds every model RANDOM-INIT, so gated/missing trained weights are irrelevant.
The 'gated' marker matched architectural terms ('gated activation', 'GatedGenerator') and wrongly
skipped 69 buildable models as fake ceilings (cornet_rt traces 130 layers, Deep Kalman Filter 351).
Removed the gated/weights-gated/not-random-init markers; such rows now render or surface a real,
repairable recipe bug -- never a 'ceiling'. (JMT: a genuine ceiling only exists if the model isn't
described anywhere in enough detail to reproduce.)
…PIs, FAILED_EXC) Resolve sketch/broken/dep-gated recipes across the menagerie via cross-env recipe-gen (mmdet/mmseg/mmpretrain .mim configs) + codex API-faithful fixes for dependency-gated families and base-env exception repairs. Keyed (name,zoo) in-place replace; render verification per-env to follow.
…cluster envs) Add EnvRecipe torch-pin + post-install support and 16 env specs (mmlab with mmcv 2.2.0->2.1.0 sitecustomize spoof, paddle, effdet, dgl, espnet, basicsr, nemo, gan, etc.) so dependency-gated families render in isolated conda envs.
…e fixes) Faithfulness audit found the base-env FAILED_EXC repair wave reduced ~76% of its models to fake torch.nn stubs (eva02->3-layer conv, glipv2->ReLU stack). Revert all 263 FE + 176 dep-gated true-stubs (no real source import) to their originals; keep 2504 faithful recipes that cite real libraries/repos (dg 1985 + mm* 519). Stubbed models go on a redo-faithfully list (cite real source or mark reimpl-needed).
…add --names-file unrenderable_reason() blanket-flagged any Config.fromfile recipe as web_or_config_recipe_sketch, wrongly pre-skipping all 838 mm-family recipes that build the real published architecture from the installed .mim config. Now only flag config recipes lacking a resolved .mim/configs path. Add --names-file for targeted batch renders (render only the listed model names).
…mpressai, e3nn, mmpose/mmocr, ...) Cover previously-uncovered dependency-gated families so their recipes render in isolated conda envs; OpenMMLab families mirror the mmlab mmcv-spoof.
…rauds Fold in 1801 audited-faithful dep-gated recipes + 319 other-mm* + 346 redo + 29 full-config re-fixes. Revert 182 debug-config frauds caught by the LLM faithfulness audit (audiocraft debug LMs, tiny ADM UNet, degenerate YouTubeDNN) to honest originals; 178 truly-unreproducible models tracked as reimpl-needed.
required_modules() matched the name after import even in from-X-import-Y form, treating Y (e.g. create_model) as a required module and cluster-skipping every installed dep-gated family. Parse per-statement so from-X-import-Y yields only X.
parse_shape() now handles 'imgs=(1,V,3,H,W); proj=(1,V,4,4); pos=(N,3)' specs -- one tensor per parenthesised group, symbolic dims (V,N,...) resolved to concrete defaults. tl.trace unpacks the list as *args. Unblocks ~1130 of ~1540 unsupported_input models.
…ter recipes Cross-lab parallel push (OpenAI codex + Claude agents): per-family input adapters (recbole/speech/gan/molecular/graph/transformers/mmengine/...) + long-tail diverse libraries, each building the real architecture with its real input via an ignore-input wrapper. ~667 stub/approximation frauds rejected by LLM faithfulness audit; ~370 genuinely-unreproducible (JAX/CUDA-only/proprietary) tracked as reimpl-needed.
…ace hook Empty notes fields ended rows with a trailing tab that the trailing-whitespace hook stripped, dropping the 9th column. Pad to 9 cols + fill empty notes so the TSV round-trips through the hook. All 10541 rows now valid 9-col.
Sonnet recovery agents (web-search enabled) recovered the previously-flagged stub/impossible tail: ~805 recovered with faithful, instantiation-verified reimplementations (MaskDINO, SetTransformer, nanodet, ProGAN, NeMo ASR, the Paddle/TSLib families, etc.) pulled from real source/papers; the '971 impossible' collapsed to ~15 genuinely-blocked (CUDA-compile-only, never-released, checkpoint-locked).
…__module__) instantiate_model's restricted builtins lacked type() (and the sandbox was illusory -- __import__ was allowed), and separate globals/locals left recipe imports invisible to lambdas + left type()-built classes module-less (torchlens AttributeError __module__). Use full builtins + single namespace + __name__='__main__'. Unblocks ~2838 ignore-input wrapper recipes (the dep-gated + recovery adapters) that silently failed at trace.
…allback neato spline routing (-Gsplines=true) is super-linear in edge crossings; dense-but-modest graphs (DenseNet/MaxViT/ConvNeXt, 785-2747 nodes) timed out at 120s or overflowed neato's rtree coordinate limit. The old guard keyed off node count only (<1000). Now _choose_spline_mode degrades to straight lines above 700 nodes OR when edges>nodes*1.5 (>=300 nodes), a rtree-overflow retry rescales pinned coordinates, and a spline timeout retries once with splines=line. convnext 120s->0.5s, densenet 120s->0.7s, maxvit rtree-error->3.3s; small/sparse graphs keep curved splines.
…ssics - render worker runs in its own session and killpg's the whole group on timeout, so graphviz dot/neato grandchildren can no longer orphan and run for hours (the load-runaway behind dense-graph draw timeouts). - add espnet_speech/u2net/zoedepth classics with self-declaring MENAGERIE_ENTRIES (10 trace-verified variants). - fix _classics_source_rows multi-builder row generation: derive the builder from entry['build'].__name__ instead of hardcoding module.build().
TorchLens used exactly two torch>=2.4-only APIs -- is_autocast_enabled(device_type) and get_autocast_dtype(device_type) in utils/rng.py. _torch_compat.py routes both through capability-probed helpers that fall back to the torch 2.1-2.3 per-device forms, so TorchLens now imports and captures on torch 2.1+. On torch>=2.4 behavior is byte-identical. This unblocks every torch<2.4 framework (notably the OpenMMLab stack: mmcv<2.2 only ships wheels for torch<=2.1), enabling ~1,100 mm* menagerie models to render in a torch-2.1 env. Lowers the floor torch>=2.4 -> torch>=2.1.
…nted classics - renderer: parse multi-input recipes (per-tensor dtypes, tuple-of-tuples, JSON spec -> *args/kwargs); ~428 previously unsupported_input models now build inputs without data edits. - dependency parser: AST-based (was regex) -- local imports (models/src/lib) no longer misclassified as missing pip deps; malformed recipes get a clean recipe_error instead of garbled cluster keys. - +48 self-declaring classics modules (~81 entries, 0 load errors): spiking NNs, flow-matching, lane detection, YOLO-World, fla linear-attention, DnCNN, Point Transformer/PointConv, MPRNet, Uformer, Grounding-DINO, Jamba, etc. Faithful random-init reconstructions -- 0 architecture ceilings in the wave. - supersede 48 mm* recipes (config-resolution + mode='tensor' wrapper) and 4 AST-parse recipe repairs in master_catalog.
92 diffusers recipes (correct per-class forward args + small configs) and 148 input-shape recipes (multi-input specs, column-realignment, prose->concrete shapes) superseded into master_catalog. Canonical render 42.9% -> 52.4%.
Ceiling-buster wave collapsed the 'unrenderable' set: - 30 hard diffusers recipes (per-class small-config forward args). - 81 giant VLM/video models tiny-config'd (internvl/janus/qwen-omni/llama4/...). - 11 structured-input sci models reimplemented (OpenFold/AF2/AF3, Boltz-2, Chemprop, Uni-Mol, GRACE, Aurora, scGPT-spatial, DeepAR/N-HiTS/TFT). - 9 CUDA-kernel archs as pure torch (megablocks, mamba, s2cnn, lava x5, VOTR). - 6 GigaGAN family; 6 'hard floor' paper-only world models reconstructed (Cosmos-Predict, Matrix-Game, Genie-LAM, Searth, EquiformerV2, GrapNet). - prune 28 non-model rows. Genuine never-renders now ~5.
…iblings Render worker sets RLIMIT_AS to 0.8x total RAM, so a pathological model that allocates a runaway amount fails its own worker (clean MemoryError -> failed: exception) instead of the kernel OOM-killing an innocent concurrent worker.
Record search coverage for future expansion rounds: 12 parallel sweeps (6 framework-provenance + 6 broad all-domain proceedings). Framework axis done: +28 new, ~72 already-covered. CRAWL_LOG.md prose + history row, HARVEST_SOURCES.md framework zoos, crawl_history.json crawls[] entry (in_progress).
…l reimplementation Faithfully reimplement dependency-gated/failed models in torch as audited classics and repair recipes so every catalog entry renders (up from ~43%). ~665 new faithful classics, 0 stubs, 5,483 distinct architectures. Renderer fixes: is_classics_row registry-based detection; graphviz process-group reaping; per-worker RLIMIT_AS; segformer3d multi-stage carry; neural_cde shadowing.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.