benchmarks-mv
Measurement harnesses and evidence bundles for AIEN on the NVIDIA DGX Spark GB10. Speed is reported against the machine's physical limit and my own previous run. Attachment of AienOS.
Brought by drakestapleton
benchmarks-mv / evidence / q36-step-model-20261031 / scripts / extract-inputs.sh
| 1 | #!/usr/bin/env bash |
| 2 | # Writes inputs.wl (the Wolfram association q36in) from the sha256-pinned files of this directory. |
| 3 | # The hosted Wolfram evaluator cannot read local files, so every input is embedded as data; this script is the |
| 4 | # only path from the pinned files to that data and is rerun by the README check (byte-identical inputs.wl). |
| 5 | # No arithmetic happens here: integers and strings are copied, the README ladder medians are copied as text. |
| 6 | # usage (from the evidence directory): scripts/extract-inputs.sh > inputs.wl |
| 7 | set -eu |
| 8 | cd "$(dirname "$0")/.." |
| 9 | wl() { jq -c "$1" "$2" | tr '[]' '{}'; } # JSON integer arrays -> Wolfram lists |
| 10 | readme=inputs/motor-chip-README.md |
| 11 | # lever-2 ladder table, README L247-250: | heads | lever 2 ms per stroke (median) | ... |
| 12 | ladder_line() { sed -n "${1}p" "$readme" | cut -d'|' -f3 | awk '{print $1}'; } |
| 13 | for l in 247 248 249 250; do |
| 14 | sed -n "${l}p" "$readme" | grep -q '^| [1248] | [0-9.]* (' || { echo "README L$l is not a lever-2 ladder row" >&2; exit 1; } |
| 15 | done |
| 16 | stamp_median=$(sed -n 's/.*chip per stroke median \([0-9.]*\) ms.*/\1/p' inputs/stroke8l2-stamps.log) |
| 17 | echo '(* q36in: generated by scripts/extract-inputs.sh from the files pinned in SHA256SUMS; do not edit by hand *)' |
| 18 | echo 'q36in = <|' |
| 19 | echo " \"source\" -> \"aien-sovereign-core-mv d3dec0eb evidence/motor-chip-20261021 + q36-host-20261020 goldens\"," |
| 20 | for n in 1 2 4 8; do |
| 21 | echo " \"ladderNs$n\" -> $(wl '.stroke_chip_ns' inputs/stroke${n}l2-real.json)," |
| 22 | echo " \"ladderFileMedianNs$n\" -> $(jq '.stroke_chip_ns_median' inputs/stroke${n}l2-real.json)," |
| 23 | echo " \"ladderHeads$n\" -> $(jq '.heads' inputs/stroke${n}l2-real.json)," |
| 24 | done |
| 25 | echo " \"readmeLadderMs\" -> {$(ladder_line 247), $(ladder_line 248), $(ladder_line 249), $(ladder_line 250)}," |
| 26 | echo " \"stampsNs\" -> $(wl '.stroke_chip_ns' inputs/stroke8l2-stamps.json)," |
| 27 | echo " \"stampsLogMedianMs\" -> $stamp_median," |
| 28 | echo " \"stampsKindNs\" -> <|$(jq -r '.timeline_last_stroke.per_kind | map("\"\(.kind)\" -> \(.ns)") | join(", ")' inputs/stroke8l2-stamps.json)|>," |
| 29 | echo " \"stampsKindLaunches\" -> <|$(jq -r '.timeline_last_stroke.per_kind | map("\"\(.kind)\" -> \(.launches)") | join(", ")' inputs/stroke8l2-stamps.json)|>," |
| 30 | echo " \"stampsTotalNs\" -> $(jq '.timeline_last_stroke.total_ns' inputs/stroke8l2-stamps.json)," |
| 31 | for f in 4p 4chat 8prompts 8prompts-b; do |
| 32 | echo " \"pinnedUnionMean[$f]\" -> $(jq '.mean_union' inputs/expert-union-$f.json)," |
| 33 | echo " \"pinnedUnionIndep[$f]\" -> $(jq '.independent_draws' inputs/expert-union-$f.json)," |
| 34 | done |
| 35 | for f in ladder1-p1 ladder2-p1p2 ladder4-p1234 4chat 8a ladder8-setb pair-code-p2 pair-code-review; do |
| 36 | echo " \"cells[$f]\" -> $(wl '.cells' derived/union-cells-$f.json)," |
| 37 | done |
| 38 | for k in expert gate_up down shared mix o_proj ab router lm_head layers routed_expert_tensor_sets_layer0; do |
| 39 | echo " \"bytes[$k]\" -> $(jq ".$k" derived/header-bytes.json)," |
| 40 | done |
| 41 | echo ' "end" -> True' |
| 42 | echo '|>;' |