File size: 3,937 Bytes
77e3c67 d160c10 77e3c67 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | # code/scripts
| script | purpose | device |
|---|---|---|
| `container_smoke.sh` | serve ONE serve profile of the built package (`--profile NAME`; this package has only the default), run `server/smoke_test.py` against it (asserts ETH dispatch, the 12x10 grid and the profile's pins; compares the shipped sample's output with its stored CPU reference under the PLAN box agreement), keep the evidence (container log, `/info`, the `/predict` output and the result, in `logs/smoke/` of the repo or `--log-dir DIR`), always stop it; one `bin/devrun -t 3600 -k 150` window | yes |
| `bench.py` | stage bench of warm forwards (`ttaw.profiling.StageBench`): host preprocess / host->ttnn / H2D / trace replay / D2H / host BEVPool / postprocess / e2e p50-p99 per input (`--inputs synthetic[=preset],pandaset[=dir],nuscenes[=manifest],sample=<manifest>`), device-only replays and back-to-back frames, AICLK, a PandaSet agreement check (workspace data); `--dispatch` / `--num-cqs` for the D14 matrix (OPT_BASELINE.md) | yes, via `bin/devrun` |
| `profile_ops.py` | device profile: each trace variant replayed between its own signposts (`encode` / `decode` / `push` / `fill`, `--rounds`), `--eager` adds one eager encode + decode with module-stage signposts; `--graph-report DIR` writes a ttnn-visualizer memory / graph report instead (`python -m tracy -r -p -v --no-web-server ...`, OPT_BASELINE.md) | yes |
| `profile_summary.py` | summary of a `profile_ops.py` ops CSV: programs, kernel sum, op-to-op gaps and span per segment, per-module stages (eager labels aligned onto the traced ops), top ops and gaps | no |
| `probe_mm.py`, `probe_conv.py`, `probe_l1res.py`, `debug_l1res.py`, `probe_upk.py`, `probe_conv512.py` | optimization probes (OPT_REPORT rounds 2-6): 1x1 linear configs, per-conv `Conv2dConfig` candidates, the L1-resident bottleneck (`tt.l1res`) vs the round-3 path, and its per-block bit check on the real weights; the `upk` up-sampling kernel (bring-up shapes, host model / float64 / grid_sample errors, trace replay); transposed (COL_MAJOR) block sharding of one conv on chosen grids (DRAM in / out and chained); bit identity + device time per candidate | yes |
| `run_public_tt.py` | public-data manifests (`research/bevdet/public_data` of the tt-models workspace: nuScenes v1.0-mini, PandaSet) through the API, results in the CPU reference's format for the agreement, the mAP / NDS scripts and `make_demo.py` (`--out-dir`) | yes |
| `make_sample.py` | generates the shipped sample `tt_bevdet/samples/synthetic_6cam*` (a synthetic six-camera test pattern), its preset `calib/synthetic_6cam.json`, the stored CPU reference and the sparse reference heads of the host tests (`optimise`, then `finalise`; research venv, CPU) | no |
| `make_demo.py` | renders `media/` (camera mosaics with the TT boxes, BEV plots, TT vs CPU) from `run_public_tt.py` outputs and the TT output of the shipped sample; writes `media/ATTRIBUTION.md` (tt-models workspace: datasets + the research renderer) | no |
| `make_goldens.py` | per-module goldens of the TT port from the fp32 CPU reference (`tt_bevdet.reference`), cross-checked against the research ONNX Runtime goldens; big ones to `research/bevdet/goldens` (never shipped); `--sets pandaset --no-big` writes the PandaSet small goldens and stored reference into the staging dir (research venv, CPU) | no |
| `stage_pandaset_sample.py` | (re)creates / checks the git-ignored `staging_samples_pandaset/` (the PandaSet 019 f38-40 sample, prepared but not shipped until the user approves PandaSet samples) | no |
| `fetch_samples.sh` | downloads the non-redistributable validation key-frame of bevdet_vendor (nuScenes `sample0`, sha256-checked) and points at nuScenes v1.0-mini / PandaSet | no |
Everything here ships in `code/` on the Hub and inside the image (`source.extra_code` lists `scripts`); the scripts
marked "workspace" need data of the tt-models workspace that is not redistributed.
|