Skip to content

feat: verify LM repeatability across rounds and checkpoints - #35

Open
soomro-abd wants to merge 1 commit into
feat/reference-causal-lmfrom
feat/lm-repeatability
Open

soomro-abd wants to merge 1 commit into
feat/reference-causal-lmfrom
feat/lm-repeatability

Conversation

@soomro-abd

Copy link
Copy Markdown
Collaborator

The determinism tester previously compared only one final scalar, which could hide different intermediate rounds, training records or learned weights. LM repeatability now checks the full execution evidence and retained checkpoints, and the new configurations cover repeated GPU attempts plus a longer clean learning check.

Depends on #34. The base is feat/reference-causal-lm so this PR contains only repeatability checks, their tests and experiment configurations. Merge the stack in dependency order and retarget after the parent lands.

Changes

  • Route LM determinism testing through provenance/initialization/client-record checks and requested-metric comparisons at round zero, every trained round and the final summary.
  • Require exact prediction and application-specific held-out details. Compare finite checkpoint tensors by name, shape and dtype, with bounded temporary comparison arrays and an explicit absolute tolerance. Require distinct retained checkpoint directories.
  • Expose an audit helper for already completed attempts, avoiding duplicate GPU training just to check another metric. Preserve classification determinism behavior.
  • Add zero-tolerance repeatability configurations for all three applications and both backends, plus a 15-round SmolLM2 Finance learning check and regression tests for false parity.

Validation

  • Full Linux/Python 3.11 suite: 343 passed, 1 optional NVFlare test skipped; strict MkDocs build and git diff --check passed.
  • 12 GPU attempts / six repeatability pairs passed on two Quadro RTX 6000 nodes: Finance, Stack Overflow and Medical, each repeated twice on reference and Flower. Checked metrics at every round, predictions, training evidence and checkpoint tensors agreed with zero tolerance. Both Flower attempts for every application used both nodes. Independent report audits also verified exact cross-backend metric agreement for both attempts.
  • 15-round SmolLM2-135M Finance learning check passed: fixed 64-record holdout accuracy 20.3125% → 51.5625% (+31.25 percentage points), loss 2.926445 → 0.454218. Four IID clients, two sampled per round, batch 8, ten local steps, 256 training rows/client and cosine learning rates. The final scheduled round exceeded the configured two-point gain threshold; no weak-learning warning remained.
  • Audited all 16 evaluations, raw-prediction accuracy, selected clients, the schedule and disjoint training/evaluation record IDs. Source matched on both nodes; Ray was stopped and GPUs returned to idle.

These are empirical same-hardware/software SmolLM2 checks. Strict PyTorch deterministic-algorithm mode is not enabled, and the capped learning run is separate from full-size Mistral/Qwen baselines, target participation-scale validation, full attack/defense grids and plots.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant