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

Add fast_beam_search_nbest for streaming pruned rnn-t #82

Merged
merged 10 commits into from
Jul 26, 2022

Conversation

ezerhouni
Copy link
Collaborator

No description provided.

@ezerhouni ezerhouni requested a review from csukuangfj July 25, 2022 11:34
@ezerhouni
Copy link
Collaborator Author

@csukuangfj It is not done yet. However, I did some refactoring to have a clearer way to pass parameter to beam search. Please let me know what you think about it. Then I will add the same changes (if you agree) to the other models.

@ezerhouni
Copy link
Collaborator Author

@csukuangfj The doc is not update, I will do so, if you agree with the changes

Copy link
Collaborator

@csukuangfj csukuangfj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

The refactoring looks good to me.

sherpa/python/sherpa/decode.py Show resolved Hide resolved
sherpa/python/sherpa/utils.py Show resolved Hide resolved
@csukuangfj csukuangfj added ready and removed ready labels Jul 25, 2022
@csukuangfj
Copy link
Collaborator

@ezerhouni
Could you fix the CI errors?

FYI: You can re-trigger the CI by removing the label ready and re-add it after pushing new commits.

https://github.com/k2-fsa/sherpa/runs/7502556741?check_suite_focus=true

Traceback (most recent call last):
  File "./sherpa/bin/pruned_stateless_emformer_rnnt2/streaming_server.py", line 43, in <module>
    from beam_search import FastBeamSearch, GreedySearch, ModifiedBeamSearch
  File "/home/runner/work/sherpa/sherpa/sherpa/bin/pruned_stateless_emformer_rnnt2/beam_search.py", line 7, in <module>
    from sherpa import (
  File "/opt/hostedtoolcache/Python/3.7.13/x64/lib/python3.7/site-packages/k2_sherpa-0.6-py3.7-linux-x86_64.egg/sherpa/__init__.py", line 23, in <module>
    from .decode import (
  File "/opt/hostedtoolcache/Python/3.7.13/x64/lib/python3.7/site-packages/k2_sherpa-0.6-py3.7-linux-x86_64.egg/sherpa/decode.py", line 21, in <module>
    from icefall.decode import Nbest
ModuleNotFoundError: No module named 'icefall'

@ezerhouni ezerhouni added ready and removed ready labels Jul 26, 2022
@ezerhouni
Copy link
Collaborator Author

@ezerhouni Could you fix the CI errors?

FYI: You can re-trigger the CI by removing the label ready and re-add it after pushing new commits.

https://github.com/k2-fsa/sherpa/runs/7502556741?check_suite_focus=true

Traceback (most recent call last):
  File "./sherpa/bin/pruned_stateless_emformer_rnnt2/streaming_server.py", line 43, in <module>
    from beam_search import FastBeamSearch, GreedySearch, ModifiedBeamSearch
  File "/home/runner/work/sherpa/sherpa/sherpa/bin/pruned_stateless_emformer_rnnt2/beam_search.py", line 7, in <module>
    from sherpa import (
  File "/opt/hostedtoolcache/Python/3.7.13/x64/lib/python3.7/site-packages/k2_sherpa-0.6-py3.7-linux-x86_64.egg/sherpa/__init__.py", line 23, in <module>
    from .decode import (
  File "/opt/hostedtoolcache/Python/3.7.13/x64/lib/python3.7/site-packages/k2_sherpa-0.6-py3.7-linux-x86_64.egg/sherpa/decode.py", line 21, in <module>
    from icefall.decode import Nbest
ModuleNotFoundError: No module named 'icefall'

I add icefall as a dependency in the CI. I restarted the workflow. Let see

@ezerhouni ezerhouni added ready and removed ready labels Jul 26, 2022
@ezerhouni ezerhouni added ready and removed ready labels Jul 26, 2022
@ezerhouni
Copy link
Collaborator Author

@csukuangfj any idea why the CI jobs are queued for more than an hour now ?

@csukuangfj
Copy link
Collaborator

@csukuangfj any idea why the CI jobs are queued for more than an hour now ?

Now, it is started. For each test, if there are more than two jobs, I just canceled all but the latest one.

@ezerhouni ezerhouni added ready and removed ready labels Jul 26, 2022
@ezerhouni ezerhouni added ready and removed ready labels Jul 26, 2022
@ezerhouni
Copy link
Collaborator Author

@csukuangfj I think the CI passed. Is it good to go ?

.github/scripts/install-icefall.sh Outdated Show resolved Hide resolved
@ezerhouni
Copy link
Collaborator Author

Merging it then. Thanks @csukuangfj for your review

@ezerhouni ezerhouni merged commit adba776 into k2-fsa:master Jul 26, 2022
@csukuangfj
Copy link
Collaborator

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants