[Examples] Use Audio feature in speech classification (#14052)

* Update SEW integration test tolerance

* Update audio classification

* Update test

* Remove torchaudio

* Add dataset revision

* Hub branch naming

* Revert dataset revisions

* Update datasets
This commit is contained in:
Anton Lozhkov
2021-10-20 12:22:43 +03:00
committed by GitHub
parent 3fefa292c1
commit dbaf49203e
6 changed files with 23 additions and 32 deletions

View File

@@ -454,9 +454,9 @@ def main():
# so that we just need to set the correct target sampling rate and normalize the input
# via the `feature_extractor`
# make sure that dataset decodes audio with correct samlping rate
# make sure that dataset decodes audio with correct sampling rate
raw_datasets = raw_datasets.cast_column(
"audio", datasets.features.Audio(sampling_rate=feature_extractor.sampling_rate)
data_args.audio_column_name, datasets.features.Audio(sampling_rate=feature_extractor.sampling_rate)
)
# derive max & min input length for sample rate & max duration