Ornix Codec — polar phase-parameterized Audio-VAE (step 20000)
RESEARCH / NON-PROMOTABLE
Audio-VAE codec: audio → latent → audio
Polar magnitude/phase decoder
16-clip diagnostic proof succeeded
Not yet full-data production qualified
Not a text-to-speech model
This repository hosts the best currently available Ornix Audio-VAE codec checkpoint: the P2-C polar (magnitude, phase) decoder after 20 000 diagnostic memorization steps on 16 clips, together with its exact configuration, the research evidence that motivated it, and the deprecated predecessor for archive purposes.
Nothing in this repository is an accepted/production model. The checkpoint is a 16-clip research artifact published so the repair can be inspected, reproduced and listened to; it is not a released codec.
1. What this model is
A continuous Audio-VAE codec: it maps a 48 kHz mono waveform to a continuous
latent sequence (50 latent frames/s, 64-dim) and back to a waveform
(AudioTensor → latent → AudioTensor). It contains no text encoder, no language
model, no planner and no vocoder conditioning. It cannot say anything.
The published variant is the P2-C phase-parameterized decoder: the decoder's two output heads are interpreted as an explicit polar pair instead of raw Cartesian coefficients.
| Cartesian (canonical) | Polar (this checkpoint) | |
|---|---|---|
| head 1 | real | magnitude = softplus(raw) |
| head 2 | imaginary | phase = raw |
| coefficients | (real, imaginary) | (magnitude·cos(phase), magnitude·sin(phase)) |
Both variants have identical parameter shapes (78,653,315 parameters, fp32, 233 tensors); the polar variant transfers the canonical initialization into the same weights and only changes what the two heads mean. The phase output is no longer a free Cartesian coefficient that can absorb magnitude error, which is what the canonical recipe was collapsing into.
2. Why it exists (evidence summary)
The AUDIO_VAE_FULLTRAIN_001 50 000-step production run produced unintelligible output at every checkpoint (owner listening at step 35 000: UNINTELLIGIBLE; 0/16 successful ASR transcriptions at all 14 quality checkpoints). AUDIO_VAE_DIAG-001 root-caused it:
- The phase path never learned. Magnitude-weighted wrapped phase-difference error sat at the uniform-random value (π/2 ≈ 1.5708 rad) at every checkpoint from step 0 to 50 000, coherence ≈ 0.02. Training reduced it by nothing.
- The objective's gradients are phase-blind. MR-STFT + mel gradient norms 2448 + 1053 vs 6.3 for complex-STFT coefficients and 0.57 for waveform L1; the phase-teaching terms hold 0.196 % of summed gradient norm at step 50 000 (down from 6.53 % at initialization).
- The synthesis primitive is not the bug. An exact-coefficient STFT→iSTFT roundtrip reconstructs references at SI-SDR ≈ 138 dB.
- Data/step count are excluded. A 16-clip tiny-overfit run reached step 20 000 (~1250 epochs, loss still falling) with the phase error still pinned to the random floor under the canonical parameterization.
The fix — reproducible on the same 16 clips at the same seed and step — is the polar head semantics:
| checkpoint | phase-diff error (rad) | phase coherence | SI-SDR (dB) | waveform corr. |
|---|---|---|---|---|
| canonical @ 5000 | 1.5686 | 0.0154 | −32.0 | 0.001 |
| canonical @ 20000 | 1.5614 | 0.0187 | −41.8 | 0.006 |
| P2-C polar @ 5000 | 1.3664 | 0.1642 | −14.1 | 0.211 |
| P2-C polar @ 10000 | 1.0196 | 0.4319 | −4.4 | 0.522 |
| P2-C polar @ 20000 (this repo) | 0.5584 | 0.7459 | +7.1 | 0.910 |
Random-phase floor = π/2 = 1.5708 rad, coherence 0.0. Monotone across six
checkpoints; phase-oracle A−C gap closes 37.8 → 25.7 → 13.5 dB. Independent
PCM16 audits of the delivered audio reproduce every number. See
evidence/polar_phase_parameterization_diagnosis.md.
Scope of the claim: this is a 16-clip diagnostic result, on clips the model was trained on. It proves the parameterization repair works on the diagnostic gate. It is not generalization evidence, not an evaluation-gate acceptance (A5) result, and not a statement about the 8 691-clip corpus.
3. Files
| path | bytes | sha256 |
|---|---|---|
model/polar-phase-parameterized-step20000/model_state.pt | 314 699 305 | 2d75bcffc60e379a682767db2ff87dd466217d04bc667835bfb0c9f74a94499e |
model/polar-phase-parameterized-step20000/diagnostic_checkpoint.pt | 943 623 713 | de013b12c64e4b8b395c64c60ddba61740d5fd54a52d92abcb159ce35596e582 |
archive/old-real-imag-50k/core_state.pt | 943 581 407 | 5b36f998022bec6a4b98dd2e9bcc60ab356bdc1da2c4b9ce7046a5d6e5d9aa72 |
model_state.pt— weights only (dict[str, Tensor], loadable withtorch.load(..., weights_only=True)); the artifact to load for inference.diagnostic_checkpoint.pt— the complete diagnostic memorization checkpoint (model + AdamW state + scheduler + CPU/CUDA RNG), the exact artifact the evidence was measured on. Loadable only throughornix.training.diagnostic_memorization.load_diagnostic_checkpointwith the matching identity (architecture_marker = "p2c-magnitude-phase-heads").archive/old-real-imag-50k/core_state.pt— the deprecated 50 000-step Cartesian production run. Known phase failure; do not use as a model. Kept only as the research control and as the only surviving copy of those weights. Seearchive/old-real-imag-50k/DEPRECATED.md.
SHA256SUMS lists the digests of every file in this repository.
4. Checkpoint identity
architecture / model variant : p2c-magnitude-phase-heads (polar decoder)
optimizer step : 20000
seed : 17
schedule horizon : 50000 (diagnostic memorization schedule)
dataset fingerprint : sha256-8caddc4d53dea3ab487d18b7e18c85c3291d51d6d259ab33f6167520600c78f7
config sha256 (resolved) : 716329386ee2063e85b54613ac972ab7c614da19105b57e9e393dd5179224db0
parameters : 78,653,315 (fp32)
sample rate : 48 kHz mono
latent : 50 frames/s, 64-dim, 960 samples/frame
The config in config/audio_vae.yaml is the exact training config. The polar
decoder is implemented in code/diagnostic_phase_ablation.py
(PhaseParameterizedSpectralDecoder, build_phase_parameterized_model).
5. Training summary
- Data: 16 clips of the owner-directed Vietnamese corpus, 48 kHz derived audio (deterministic polyphase resampling from the 24 kHz source).
- Recipe: diagnostic tiny-overfit — batch 1, AdamW (lr 1e-4, betas 0.9/0.95, wd 0.01), warmup-cosine over a 50 000-step horizon, gradient clipping 1.0, Phase-A reconstruction warmup (no KL, no GAN), fp32 eager, seed 17.
- Cost: ≈ 42 min of RTX 3090 for the 5 000 → 20 000 step extension (≈ 2 h 45 m for the whole AUDIO_VAE_DIAG-001 campaign).
- Determinism: checkpoints store the model, optimizer, scheduler and CPU/CUDA RNG states; the extension resume was bitwise-exact against a fresh run.
6. Listening
listening/diag-repair-p2c-phaseparam-step-00020000.zip — 16 clip pairs
(<clip>__REFERENCE.wav = input, <clip>__p2c-phaseparam.wav = model output,
48 kHz PCM16). These are the memorized clips, i.e. the best case this checkpoint
can produce; the control variants for the same steps are in the evidence bundle
of the diagnosis report.
6b. Out-of-set probe — what this checkpoint does not do
Three test-split clips that the 16-clip run never saw were passed through this
checkpoint and through the canonical control at the same step (probe tool:
reconstruct subcommand; 24 kHz sources converted with the pinned deterministic
resampler):
| checkpoint | mean SI-SDR | phase-diff error | phase coherence |
|---|---|---|---|
| polar (this repository) | −35.9 dB | 1.5685 rad | 0.0288 |
| canonical (control, step 20000) | −37.7 dB | 1.5779 rad | 0.0173 |
Both sit at the random-phase floor (π/2 = 1.5708 rad): the repair does not
generalize beyond the 16 memorized clips. Audio for both:
listening/unseen-clip-probe-step20000.zip. This is the strongest available
evidence that this checkpoint is a diagnostic artifact and not yet a usable
codec, and it is the reason the model card is labelled NON-PROMOTABLE.
7. Known limitations
- Not production qualified. No full-data (8 691-clip) run of the polar recipe exists yet. The 50 000-step scale has never been run with polar heads.
- Memorization scope. Trained on 16 clips only; the numbers above are train-set reconstructions. Generalization is untested.
- Quality. Even at +7.1 dB SI-SDR / 0.75 phase coherence on the 16 clips, the reconstruction remains an autoencoder round-trip, not a released codec; the latent space has not been validated for downstream planners.
- Latent identity. This checkpoint shares the canonical config and latent shape, but its decoder semantics differ from the canonical recipe; do not mix latents produced by this model with the canonical decoder or vice versa.
- No text-to-speech. There is no text pathway anywhere in this repository.
- Consent/provenance. Training audio is the owner-directed Vietnamese corpus whose consent status is recorded as UNKNOWN with an NC license; this research artifact inherits that restriction.
8. Non-claims
- Audio-VAE reconstruction intelligibility is NOT full text-to-speech proof.
- ASR-derived metrics are NOT MOS/naturalness/speaker-similarity.
- No A5/E2E PASS is fabricated from reconstructed audio or from any metric here.
- The 50 000-step Cartesian checkpoint is NOT a baseline to improve on; it is a documented failure kept for control purposes.
9. Source
Code, diagnosis and gates: github.com/Teedyyy-rm/Ornix-TTS.
Authoritative write-up: docs/research/audio_vae_intelligibility_failure_analysis.md
(also shipped here as evidence/polar_phase_parameterization_diagnosis.md).
Evidence bundle revision: repository commit 096b096 and earlier (the diagnosis
itself is frozen at a55cb90).