Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Re-implement LM rescore for online transducer #1231

Merged
merged 6 commits into from
Sep 6, 2024

Conversation

SilverSulfide
Copy link
Contributor

Shallow fusion can be too slow for online cpu inference. Added an option to use classical LM rescore instead.

CPU runtime comparison for ~1 min wav file using the default --lm-num-threads=1

Method Runtime (s) RTF
No LM 5.7 0.098
Rescore 40 0.68
Shallow Fusion 69 1.2

@SilverSulfide
Copy link
Contributor Author

@csukuangfj hi, are there any more changes that should be written?

@csukuangfj
Copy link
Collaborator

Could you fix the CI errors for Python?

@SilverSulfide
Copy link
Contributor Author

@csukuangfj should be resolved now!

@csukuangfj
Copy link
Collaborator

Thank you for your contribution!

@csukuangfj csukuangfj merged commit 888f74b into k2-fsa:master Sep 6, 2024
189 of 203 checks passed
@SilverSulfide SilverSulfide deleted the online_lm_rescore branch September 10, 2024 12:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants