Bit-Identical Medical Deep Learning via Structured Orthogonal Initialization
Organizations: Independent Researcher, Mountain View, CA, United States
Abstract
Deep learning training is non-deterministic: identical code with different random seeds produces models that agree on aggregate metrics but disagree on individual predictions, with per-class AUC swings exceeding 20 percentage points on rare clinical classes. We present a framework for verified bit-identical training that eliminates three sources of randomness: weight initialization (via structured orthogonal basis functions), batch ordering (via golden ratio scheduling), and non-deterministic GPU operations (via architecture selection and custom autograd). The pipeline produces MD5-verified identical trained weights across independent runs. On PTB-XL ECG rhythm classification, structured initialization significantly exceeds Kaiming across two architectures (n=20; Conformer p = 0.016, Baseline p < 0.001), reducing aggregate variance by 2-3x and reducing per-class variability on rare rhythms by up to 7.5x (TRIGU range: 4.1pp vs 30.9pp under Kaiming, independently confirmed by 3-fold CV). A four-basis comparison at n=20 shows all structured orthogonal bases produce equivalent performance (Friedman p=0.48), establishing that the contribution is deterministic structured initialization itself, not any particular basis function. Cross-domain validation on seven MedMNIST benchmarks (n=20, all p > 0.14) confirms no performance penalty on standard tasks; per-class analysis on imbalanced tasks (ChestMNIST, RetinaMNIST) shows the same variance reduction on rare classes observed in ECG. Cross-dataset evaluation on three external ECG databases confirms zero-shot generalization (>0.93 AFIB AUC).
Figures & tables
| Comparison | Power | TOST | |||
|---|---|---|---|---|---|
| Conform. mixed vs Kaim. | 20 | 0.82 | 71% | 25 | ( ) |
| Baseline struct. vs Kaim. | 20 | 1.60 | 99% | 7 | superiority ( ) |
| CIFAR-100 struct. vs Kaim. | 20 | 0.24 | 11% a | — | ( pp) |
| Component | Test AUC | Delta |
|---|---|---|
| DCT-only (fixup=0.01) | baseline | |
| + mixed bases | +0.003 | |
| + sqrt class weight | +0.003 | |
| + mixed + cw (“Mixed”) | +0.013 | |
| Kaiming (reference) | — | |
| Kaiming + cw | a | +0.002 |
| Model | Init | Configuration | Test AUC | Params | Det. |
|---|---|---|---|---|---|
| Conformer | Mixed | 20 batch seeds | 1.83M | Init | |
| Conformer | Mixed | golden ratio | 0.966 a | 1.83M | Full |
| Conformer | Kaiming | 20 init seeds | 1.83M | No | |
| Baseline CNN | DCT | 20 batch seeds | 1.65M | Init | |
| Baseline CNN | Kaiming | 20 init seeds | 1.65M | No | |
| xresnet1d101 | Kaiming | 5 init seeds | 9.0M | No |
| Basis (single, all stages) | Test AUC (mean std) | vs. DCT (paired) |
|---|---|---|
| Hartley-only | ||
| Sinusoidal-only | ||
| Hadamard-only | ||
| DCT-only | — | |
| Kaiming+cw | a | — |
| Architecture | Init | AUC | TRIGU | SVARR | AFLT |
|---|---|---|---|---|---|
| Conformer | Mixed | ||||
| Conformer | Kaiming | ||||
| Baseline | Mixed | ||||
| Baseline | Kaiming |
| Dataset | DCT AUC | Kaiming AUC | |||
| BloodMNIST | .65 | 11,959 | |||
| OrganCMNIST | .16 | 13,000 | |||
| DermaMNIST | .74 | 7,007 | |||
| BreastMNIST | .96 | 546 | |||
| RetinaMNIST | .26 | 400 | |||
| ChestMNIST | .32 | 78,468 |
| Configuration | F10 | F9 | F8 | Mean Std |
|---|---|---|---|---|
| Conform. mixed (seeded) | .942 | .961 | .963 | |
| Conform. mixed (golden) | .908 | .948 | .968 | |
| Baseline mixed | .927 | .953 | .934 | |
| Baseline Kaiming | .923 | .949 | .941 |
| Model | AFDB | CPSC2018 | Chapman | Params |
|---|---|---|---|---|
| Baseline (xresnet) | 0.952 | 0.979 | 0.991 | 1.65M |
| Conformer | 0.932 | 0.979 | 0.984 | 1.83M |
Appendix figures & tables4 assets
Supplementary material from the paper’s appendix.
Appendix
| Dataset | Init | Accuracy | Params |
|---|---|---|---|
| CIFAR-100 | DCT 2D | % | 11.2M |
| CIFAR-100 | Kaiming | % | 11.2M |
| Basis | Clean AUC | BW drop | Muscle drop | EM drop |
|---|---|---|---|---|
| Hartley | ||||
| Hadamard | ||||
| Sinusoidal | ||||
| DCT |
| Method | AUC | Seed-free? | Notes |
|---|---|---|---|
| Seeded shuffle (control) | 0.955 | No | Upper bound |
| Class guaranteed | 0.947 | Yes | Highest seed-free; needs calibration |
| Golden ratio | 0.941 | Yes | Selected: parameter-free |
| Sobol sequence | 0.939 | Yes | Quasi-random coverage |
| Feature-space diverse | 0.883 | Yes | Rotating projection |
| Stratified quantile | 0.579 | Yes | Loss-based, class-correlated |
ML Reproducibility
Machine learning reproducibility studies whether model results and scientific claims can be independently checked and reliably repeated.
See all 136 papers