File size: 3,441 Bytes
b9c4982 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 | ---
license: other
license_name: mixed-per-source
license_link: LICENSE
task_categories:
- automatic-speech-recognition
- audio-classification
language:
- en
- zh
tags:
- audio
- speech
- asr
- audio-captioning
- mel-spectrogram
- tfrecord
pretty_name: Stage 1A Audio Alignment Smoke Data (AuT 128-mel)
size_categories:
- 100K<n<1M
---
# stage1a_smoke_data — AuT-ready 128-mel TFRecords (en/zh)
Smoke-scale training data for **Stage 1A input audio alignment** of a Qwen3-ASR-AuT → MLP →
frozen-VL-LLM omni model. Audio is **pre-extracted 128-bin log-mel** (the Qwen3-ASR AuT frontend:
`WhisperFeatureExtractor`, 16 kHz, hop 160, n_fft 400) so training only needs to run the frozen AuT
encoder — no raw-audio decoding at train time.
**113,396 samples** across 4 sources, stored as GZIP-compressed **TFRecords** (one file per source shard).
## Sources & mix
| source | task | lang | samples |
|---|---|---|---|
| LibriSpeech `train.clean.100` | asr | en | 28,539 |
| AISHELL-1 (train) | asr | zh | 34,679 |
| AudioCaps (train) | caption | en | 45,178 |
| synthetic silence/no-speech | silence | na | 5,000 |
> Licenses follow the upstream corpora: LibriSpeech CC-BY-4.0; AISHELL-1 Apache-2.0; AudioCaps
> CC-BY-NC-4.0 (**non-commercial**); silence is synthetic. Use accordingly.
## TFRecord schema (per `tf.train.Example`)
| feature | type | meaning |
|---|---|---|
| `mel` | bytes | fp16 raw, reshape to `[n_mels, n_frames]` |
| `n_mels` | int64 | 128 |
| `n_frames` | int64 | mel frames, **multiple of 100** (AuT `n_window*2` chunk requirement) |
| `feature_len` | int64 | true valid mel frames (`<= n_frames`; the tail is zero-pad) |
| `n_audio_tokens` | int64 | `aut_out_lengths(feature_len)` = number of AUDIO_PAD placeholders after the AuT encoder (each full 100 mel frames → 13 encoder frames) |
| `text` | bytes | utf-8 target: transcript / caption / `<no_speech>` |
| `task` | bytes | `asr` \| `caption` \| `silence` |
| `lang` | bytes | `en` \| `zh` \| `na` |
## Load
```python
import tensorflow as tf, numpy as np, glob
FEAT = {
"mel": tf.io.FixedLenFeature([], tf.string),
"n_mels": tf.io.FixedLenFeature([], tf.int64),
"n_frames": tf.io.FixedLenFeature([], tf.int64),
"feature_len": tf.io.FixedLenFeature([], tf.int64),
"n_audio_tokens": tf.io.FixedLenFeature([], tf.int64),
"text": tf.io.FixedLenFeature([], tf.string),
"task": tf.io.FixedLenFeature([], tf.string),
"lang": tf.io.FixedLenFeature([], tf.string),
}
def parse(raw):
e = tf.io.parse_single_example(raw, FEAT)
return e
files = glob.glob("*.tfrecord.gz")
ds = tf.data.TFRecordDataset(files, compression_type="GZIP").map(parse)
for e in ds.take(1):
nm, nf = int(e["n_mels"]), int(e["n_frames"])
mel = np.frombuffer(e["mel"].numpy(), np.float16).reshape(nm, nf) # [128, n_frames], cast to fp32 for AuT
print(mel.shape, e["text"].numpy().decode(), int(e["feature_len"]), int(e["n_audio_tokens"]))
```
At train time: `mel[:, :ceil_to_100(feature_len)]` → cast fp32 → frozen AuT encoder → 2048-d
audio_states → trainable 2-layer MLP → scatter into `n_audio_tokens` AUDIO_PAD slots of the frozen LLM.
## Provenance
Generated by `stage1a_data_prep.py` + `stage1a_npz_to_tfrecord.py`
(LLaVA-OV2-tpu, branch `feat/qwen3-audio-stack`). This is **smoke-scale** for pipeline validation;
full-scale Stage 1A uses online mel extraction over the larger recipe (MLS-en, People's Speech, etc.).
|