Repository navigation
A throughput claim gets its same-container pair from two refs, alternating - #115
Merged
Merged
Conversation
…e refs `compare_profile` gives a fusion claim the same-container pair SPEC 11 asks for, but only for `bin/profile`. Throughput is quoted from `bin/train.rs`, and every measurement this month has hand-rolled that pairing. `compare_train` is the trainer's shape of it, with two differences the profile pair does not need. Both arms are worktrees of one clone, so neither side is the mounted tree and both are exactly what was committed; and the arms alternate round by round rather than running once each, which turns a drift in clocks into a spread each arm reports beside its mean instead of a difference between them.
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.
Why
compare_profilegives a fusion claim the same-container pair SPEC §11 asks for, butonly for
bin/profile. A throughput claim is quoted frombin/train.rs, and everymeasurement PR this month has hand-rolled that pairing by hand (#112 wrote one and
reverted it as out of scope). This is that utility, once.
What it is
compare_train(ref, baseline_ref="main", steps=12, rounds=2, shard=None), reachable asTwo differences from
compare_profile, both of which the trainer needs and the profilepair does not:
compare_profilepairs a cloned baseline against the mountedworking tree. Here both arms are
git worktree --detachcheckouts of one clone, sowhat is measured is exactly two committed refs and nothing uncommitted leaks into
either side. The candidate must therefore be pushed. (
--detachis also what letsmainbe both arms, which is how the harness is validated below.)train.rs discards its own first step besides — then the arms alternate round by round.
A drift in clocks across the container's life then lands on both arms and shows up as
each arm's spread rather than as a difference between them.
Bis a compile-time constant of train.rs and is left as whatever each ref says it is;the harness does not rewrite it. Per-run tokens/s and MFU are parsed from train.rs's own
throughput=line, and each arm reports mean, spread, and the runs behind them.Validation:
mainvsmainOne B200 container,
--steps 6 --rounds 2(5 measured steps a run), both armsmain.The correct answer is two indistinguishable arms:
Two indistinguishable arms, as they must be: the arms differ by 0.39% while one arm's
own two runs differ by 1.75%, so the between-arm difference is a quarter of the
noise the harness itself reports. That 1.75% is the useful number here — it is what five
measured steps costs in resolution, and a claim under ~2% wants more
--steps(thedefault 12 measures 11) or more
--rounds, which is exactly what the spread column isfor. All four runs sat within 0.7% of the 38.6-39.0% MFU band.
Cost: one B200 container, six trainer processes (two builds/warmups + four timed runs),
about 25 minutes wall.
Note for whoever merges this
origin/rmsnorm-fusions(#113) carries its owncompare_traininmodal_app.py, addedindependently for that PR's own A/B; a third copy exists on an unpushed local branch.
Whichever of the two lands second should drop its copy rather than resolve the conflict —
the two do the same job, this one from two refs with alternating rounds and summary
statistics, that one from one ref against the mounted tree with a
--batchrewrite. Thediff here is additive-only (one function, one entrypoint, one README paragraph) and
touches nothing existing.