-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Icefall-based, Transducer ASR Model #2339
Closed
Closed
Changes from 2 commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
39a661e
Add Pytorch Icefall speech recognizer to ART
e2ddf45
Update pytest to remove dependency on forked branches; Implement exam…
c094d3a
Remove swallowed exceptions
6df000b
Undo changes on file that should not be touched
b734069
Remove superfluous imports
6705b36
Refactor icefall ci pipeline, replace Google Drive link with Dropbox …
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,89 @@ | ||
name: CI PyTorchIcefall | ||
on: | ||
# on manual trigger | ||
workflow_dispatch: | ||
|
||
# on pull requests | ||
pull_request: | ||
paths-ignore: | ||
- '*.md' | ||
|
||
# on merge queue | ||
merge_group: | ||
|
||
# when pushing to main or dev branches | ||
push: | ||
branches: | ||
- main | ||
- dev* | ||
|
||
# scheduled CI flow daily | ||
schedule: | ||
- cron: '0 8 * * 0' | ||
|
||
jobs: | ||
test_icefall: | ||
name: PyTorchIcefall | ||
runs-on: ubuntu-latest | ||
defaults: | ||
run: | ||
shell: bash -l {0} | ||
steps: | ||
- name: Checkout Repo | ||
uses: actions/checkout@v3 | ||
- name: Setup Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: ${{ matrix.python }} | ||
- name: Install Dependencies | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get -y -q install ffmpeg libavcodec-extra | ||
python -m pip install --upgrade pip setuptools wheel | ||
pip3 install -r requirements_test.txt | ||
apt-get update \ | ||
&& apt-get install -y \ | ||
libgl1-mesa-glx \ | ||
libx11-xcb1 \ | ||
git \ | ||
gcc \ | ||
mono-mcs \ | ||
libavcodec-extra \ | ||
ffmpeg \ | ||
curl \ | ||
libsndfile-dev \ | ||
libsndfile1 \ | ||
&& apt-get clean all \ | ||
&& rm -r /var/lib/apt/lists/* | ||
pip install astropy | ||
pip install matplotlib | ||
pip install pandas | ||
pip install -U scikit-learn | ||
pip install -u scikit-image | ||
pip install -U torch==2.0.0 torchaudio==2.0.1 --index-url https://download.pytorch.org/whl/cpu | ||
pip install k2==1.24.3.dev20230726+cpu.torch2.0.1 -f https://k2-fsa.github.io/k2/cpu.html | ||
pip install lhotse | ||
git clone https://github.com/k2-fsa/icefall.git | ||
cd icefall | ||
pip install -r requirements.txt | ||
pip install pytest | ||
pip install pytest-cov | ||
pip install kaldiio | ||
pip install tensorflow | ||
cd egs/fluent_speech_commands/SLU/transducer | ||
wget -O epoch-6.pt https://www.dropbox.com/scl/fi/97wvdjmbuyj13kpzhricc/epoch-6.pt?rlkey=7mehc4v41fovfz0ksbt98krry&dl=0 | ||
wget --load-cookies /tmp/cookies.txt "https://docs.google.com/uc?export=download&confirm=$(wget --quiet --save-cookies /tmp/cookies.txt --keep-session-cookies --no-check-certificate 'https://docs.google.com/uc?export=download&id=1K-CaHTtJ-zZ5oW0us0OaKQmsD2-cO0xN' -O- | sed -rn 's/.*confirm=([0-9A-Za-z_]+).*/\1\n/p')&id=1K-CaHTtJ-zZ5oW0us0OaKQmsD2-cO0xN" -O frames.zip && rm -rf /tmp/cookies.txt1K-CaHTtJ-zZ5oW0us0OaKQmsD2-cO0xN | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can we change this to a dropbox instead of. google drive? |
||
unzip frames.zip | ||
- name: Test Action | ||
run: | | ||
cd icefall | ||
export PYTHONPATH=$PYTHONPATH:$(pwd) | ||
cd egs/fluent_speech_commands/SLU/ | ||
export PYTHONPATH=$PYTHONPATH:$(pwd) | ||
cd transducer | ||
export PYTHONPATH=$PYTHONPATH:$(pwd) | ||
pytest --cov-report=xml --cov=art --cov-append -q -vv ../../../../../tests/estimators/speech_recognition/test_pytorch_icefall.py --framework=pytorch --durations=0 | ||
- name: Upload coverage to Codecov | ||
uses: codecov/codecov-action@v3 | ||
with: | ||
fail_ci_if_error: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a reason why this is done as two
apt install
steps? Can't they be combined into one?