Parallel CBS Transformer Based ASR
Project description
fujielab-asr-parallel-cbs
Parallel CBS Transformer based ASR system built on ESPnet
Overview
fujielab-asr-parallel-cbs is an automatic speech recognition (ASR) system based on ESPnet, featuring a parallelizable Contextual Block Streaming (CBS) Transformer.
Features
- Implementation of a parallel CBS Transformer encoder extending the ESPnet framework
- Supports online and streaming ASR inference
- Pretrained models available via Hugging Face
- Example script for chunk-by-chunk streaming recognition
Requirements
- Python 3.11
torch,torchaudio, and other packages listed inrequirements.txt
Installation
PyPI Installation
You can install the package directly from PyPI:
pip install fujielab-asr-parallel-cbs
Local Installation
- Install the dependencies and this package:
pip install -r requirements.txt pip install -e .
If you skip installing the package, running the examples may fail withModuleNotFoundError. Alternatively, you can setPYTHONPATH=$(pwd)before executing the scripts. - If there are additional dependencies, please refer to
pyproject.toml.
Usage
Example: Running Inference
You can perform inference from an audio file using examples/run_streaming_asr.py:
python examples/run_streaming_asr.py
The script streams the input audio in 100 ms chunks and prints partial
results. At the first run it downloads a small example audio (aps-smp.mp3)
from the CSJ corpus and a pretrained model from Hugging Face. When the
recognition finishes successfully, the final transcript is displayed at the end
of the log.
Directory Structure
fujielab/asr_parallel_cbs/espnet_ext/: ESPnet extension implementationespnet/: Extensions for ESPnet1espnet2/: Extensions for ESPnet2 (ASR, transducer, joint network, etc.)
examples/: Sample audio and inference scriptswarprnnt_pytorch/: Dummy module for warprnnt_pytorch
License
This repository is released under the Apache License 2.0.
Acknowledgements
This project is based on the ESPnet framework and incorporates contributions from various open-source projects. We thank the ESPnet team and contributors for their work.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file fujielab_asr_parallel_cbs-0.1.0.tar.gz.
File metadata
- Download URL: fujielab_asr_parallel_cbs-0.1.0.tar.gz
- Upload date:
- Size: 46.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
27c959a463e12dbc198f86a9a015d147041e1517bd65fae2f15b4a06fc811c38
|
|
| MD5 |
a5fc50fec47a1be8fb2ca713453d9635
|
|
| BLAKE2b-256 |
6c266a169f6d74de49fdec2d59504593075636ac8b3a35c9c54b5dd6eefa6f26
|
File details
Details for the file fujielab_asr_parallel_cbs-0.1.0-py3-none-any.whl.
File metadata
- Download URL: fujielab_asr_parallel_cbs-0.1.0-py3-none-any.whl
- Upload date:
- Size: 45.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
431c9b277de1a21e78a9c123f57f24bd0c29ebe776436d00fe1a61bda8353535
|
|
| MD5 |
a70b9a7278796f824c59b0c6c2cd3acf
|
|
| BLAKE2b-256 |
f9cafcfcd9a8ae5ca3a8579e568baa744302c01f362ac153c9d581e2315b1038
|