Skip to content

Commit 9373c34

Browse files
committed
resolving merge conflicts
2 parents 607822c + 34159b8 commit 9373c34

217 files changed

Lines changed: 28796 additions & 1858 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/newtag.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: "Draft release when pushing new tag"
2+
3+
on: # yamllint disable-line rule:truthy
4+
push:
5+
tags:
6+
- "v*"
7+
8+
jobs:
9+
pre-release:
10+
name: "Draft release"
11+
runs-on: "ubuntu-latest"
12+
13+
steps:
14+
- uses: "marvinpinto/[email protected]"
15+
with:
16+
repo_token: "${{ secrets.GITHUB_TOKEN }}"
17+
draft: True
18+
prerelease: False

.github/workflows/release.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# Automatically publish to PyPI when a GitHub release is published
2+
name: Publish to PyPI
3+
4+
# Run this action when a release is published
5+
on: # yamllint disable-line rule:truthy
6+
release:
7+
types: [published]
8+
9+
# Updates version.txt, builds, and pushes to PyPI
10+
jobs:
11+
release:
12+
name: Builds and publishes to PyPI
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@v2
16+
with:
17+
ref: main
18+
- uses: actions/setup-python@v2
19+
with:
20+
python-version: 3.8
21+
- name: Install pypa/build
22+
run: python -m pip install build --user
23+
- name: Build binary wheel and source tarball
24+
run: python -m build --sdist --wheel --outdir dist/
25+
- name: Publish to PyPI
26+
if: startsWith(github.ref, 'refs/tags')
27+
uses: pypa/gh-action-pypi-publish@master
28+
with:
29+
user: __token__
30+
password: ${{ secrets.PYPI_API_KEY }}

README.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,3 +155,19 @@ Instead of a long and boring README, we prefer to provide you with different res
155155

156156
# License
157157
SpeechBrain is released under the Apache License, version 2.0. The Apache license is a popular BSD-like license. SpeechBrain can be redistributed for free, even for commercial purposes, although you can not take off the license headers (and under some circumstances, you may have to distribute a license document). Apache is not a viral license like the GPL, which forces you to release your modifications to the source code. Also note that this project has no connection to the Apache Foundation, other than that we use the same license terms.
158+
159+
# Citing SpeechBrain
160+
Please, cite SpeechBrain if you use it for your research or business.
161+
162+
```bibtex
163+
@misc{speechbrain,
164+
title={{SpeechBrain}: A General-Purpose Speech Toolkit},
165+
author={Mirco Ravanelli and Titouan Parcollet and Peter Plantinga and Aku Rouhe and Samuele Cornell and Loren Lugosch and Cem Subakan and Nauman Dawalatabad and Abdelwahab Heba and Jianyuan Zhong and Ju-Chieh Chou and Sung-Lin Yeh and Szu-Wei Fu and Chien-Feng Liao and Elena Rastorgueva and François Grondin and William Aris and Hwidong Na and Yan Gao and Renato De Mori and Yoshua Bengio},
166+
year={2021},
167+
eprint={2106.04624},
168+
archivePrefix={arXiv},
169+
primaryClass={eess.AS},
170+
note={arXiv:2106.04624}
171+
}
172+
```
173+

conftest.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,3 +11,7 @@
1111
from transformers import Wav2Vec2Model # noqa: F401
1212
except ModuleNotFoundError:
1313
collect_ignore.append("speechbrain/lobes/models/huggingface_wav2vec.py")
14+
try:
15+
import sacrebleu # noqa: F401
16+
except ModuleNotFoundError:
17+
collect_ignore.append("speechbrain/utils/bleu.py")

docs/contributing.md

Lines changed: 42 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ and where the implemented algorithm needs clarification.
133133
- The CI pipeline is triggered by pull requests.
134134
- Runs in a Ubuntu environment provided by GitHub
135135
- GitHub offers a limited amount of CI pipeline minutes for free.
136-
- CD would stand for continuous deployment, though we’re not doing that yet
136+
- CD stands for continuous deployment, check out the "Releasing a new version" section.
137137

138138
### Our test suite
139139
- Code linters are run. This means black and flake8. These are run on everything in speechbrain (the library directory), everything in recipes and everything in tests.
@@ -172,3 +172,44 @@ Fifthly, the code review is a place for professional constructive criticism,
172172
a nice strategy to show (and validate) that you understand what the PR is really
173173
doing is to provide some affirmative comments on its strengths.
174174

175+
## Releasing a new version
176+
177+
Here are a few guidelines for when and how to release a new version.
178+
To begin with, as hinted in the "Continuous Integration" section, we would like to follow a
179+
pretty tight release schedule, known as "Continuous Deployment". For us, this means a new
180+
version should be released roughly once a week.
181+
182+
As for how to name the released version, we try to follow semantic versioning for this. More details
183+
can be found at [semver.org](http://semver.org). As it applies to SpeechBrain, some examples
184+
of what this would likely mean:
185+
* Changes to the Brain class or other core elements often warrant a major version bump (e.g. 1.5.3 -> 2.0.0)
186+
* Added classes or features warrant a minor version bump. Most weekly updates should fall into this.
187+
* Patch version bumps should happen only for bug fixes.
188+
189+
When releasing a new version, there are a few user-initiated action that need to occur.
190+
1. On the `develop` branch, update `speechbrain/version.txt` to say the new version:
191+
X.Y.Z
192+
2. Merge the `develop` branch into the `main` branch:
193+
git checkout main
194+
git merge develop
195+
3. Push the `main` branch to github:
196+
git push
197+
4. Tag the `main` branch with the new version:
198+
git tag vX.Y.Z
199+
5. Push the new tag to github:
200+
git push --tags
201+
202+
This kicks off an automatic action that creates a draft release with release notes.
203+
Review the notes to make sure they make sense and remove commits that aren't important.
204+
You can then publish the release to make it public.
205+
Publishing a new release kicks off a series of automatic tools, listed below:
206+
207+
* The `main` branch is checked out and used for building a python package.
208+
* The built package is uploaded to PyPI and the release is published there.
209+
* Read the Docs uses Webhooks to get notified when a new version is published.
210+
Read the Docs then builds the documentation and publishes the new version.
211+
212+
Maintainers of relevant accounts:
213+
* Mirco Ravanelli maintains the GitHub and PyPI accounts
214+
* Titouan Parcollet maintains the website at [speechbrain.github.io](speechbrain.github.io)
215+
as well as accounts at Read the Docs and Discourse

docs/docs-requirements.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
better-apidoc>=0.3.1
2+
numba
23
recommonmark>=0.7.1
4+
six
35
sphinx-rtd-theme>=0.4.3
46
Sphinx>=3.4.3
5-
six
6-
numba

docs/index.rst

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,14 @@ Referencing SpeechBrain
3131
--------
3232
.. code-block:: txt
3333
34-
@misc{SB2021,
35-
author = {Ravanelli, Mirco and Parcollet, Titouan and Rouhe, Aku and Plantinga, Peter and Rastorgueva, Elena and Lugosch, Loren and Dawalatabad, Nauman and Ju-Chieh, Chou and Heba, Abdel and Grondin, Francois and Aris, William and Liao, Chien-Feng and Cornell, Samuele and Yeh, Sung-Lin and Na, Hwidong and Gao, Yan and Fu, Szu-Wei and Subakan, Cem and De Mori, Renato and Bengio, Yoshua },
36-
title = {SpeechBrain},
37-
year = {2021},
38-
publisher = {GitHub},
39-
journal = {GitHub repository},
40-
howpublished = {\url{https://github.com/speechbrain/speechbrain}},
41-
}
34+
@misc{speechbrain,
35+
title={SpeechBrain: A General-Purpose Speech Toolkit},
36+
author={Mirco Ravanelli and Titouan Parcollet and Peter Plantinga and Aku Rouhe and Samuele Cornell and Loren Lugosch and Cem Subakan and Nauman Dawalatabad and Abdelwahab Heba and Jianyuan Zhong and Ju-Chieh Chou and Sung-Lin Yeh and Szu-Wei Fu and Chien-Feng Liao and Elena Rastorgueva and François Grondin and William Aris and Hwidong Na and Yan Gao and Renato De Mori and Yoshua Bengio},
37+
year={2021},
38+
eprint={2106.04624},
39+
archivePrefix={arXiv},
40+
primaryClass={eess.AS}
41+
}
4242

4343

4444
.. toctree::

docs/multigpu.md

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,15 @@ The common pattern for using multi-GPU training over a single machine with Data
77

88
```
99
> cd recipes/<dataset>/<task>/
10-
> python experiment.py params.yaml --data_parallel_backend --data_parallel_count=2
10+
> python experiment.py params.yaml --data_parallel_backend
11+
```
12+
If you want to use a specific set of GPU devices, condiser using `CUDA_VISIBLE_DEVICES` as follow:
13+
```
14+
> cd recipes/<dataset>/<task>/
15+
> CUDA_VISIBLE_DEVICES=1,5 python experiment.py params.yaml --data_parallel_backend
1116
```
1217

13-
Important: the batch size for each GPU process will be: `batch_size / data_parallel_count`. So you should consider changing the batch_size value according to you need.
18+
Important: the batch size for each GPU process will be: `batch_size / Number of GPUs`. So you should consider changing the batch_size value according to you need.
1419

1520
## Multi-GPU training using Distributed Data Parallel (DDP)
1621

recipes/AISHELL-1/ASR/seq2seq/README.md

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,4 +32,26 @@ Results are reported in terms of Character Error Rate (CER). It is not clear fro
3232
You can checkout our results (models, training logs, etc,) here:
3333
https://drive.google.com/drive/folders/1zlTBib0XEwWeyhaXDXnkqtPsIBI18Uzs?usp=sharing
3434

35-
35+
# Training Time
36+
It takes about 1h 30 minutes on a NVIDIA V100 (32GB).
37+
38+
# **About SpeechBrain**
39+
- Website: https://speechbrain.github.io/
40+
- Code: https://github.com/speechbrain/speechbrain/
41+
- HuggingFace: https://huggingface.co/speechbrain/
42+
43+
44+
# **Citing SpeechBrain**
45+
Please, cite SpeechBrain if you use it for your research or business.
46+
47+
```bibtex
48+
@misc{speechbrain,
49+
title={{SpeechBrain}: A General-Purpose Speech Toolkit},
50+
author={Mirco Ravanelli and Titouan Parcollet and Peter Plantinga and Aku Rouhe and Samuele Cornell and Loren Lugosch and Cem Subakan and Nauman Dawalatabad and Abdelwahab Heba and Jianyuan Zhong and Ju-Chieh Chou and Sung-Lin Yeh and Szu-Wei Fu and Chien-Feng Liao and Elena Rastorgueva and François Grondin and William Aris and Hwidong Na and Yan Gao and Renato De Mori and Yoshua Bengio},
51+
year={2021},
52+
eprint={2106.04624},
53+
archivePrefix={arXiv},
54+
primaryClass={eess.AS},
55+
note={arXiv:2106.04624}
56+
}
57+
```

recipes/AISHELL-1/ASR/transformer/README.md

Lines changed: 34 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,39 @@ Results are reported in terms of Character Error Rate (CER).
2323
| hyperparams file | LM | Test CER | Dev CER | GPUs |
2424
|:--------------------------:|:-----:| :-----:| :-----:| :-----: |
2525
| train_ASR_transformer.yaml | No | 6.04 | 5.60 | 1xRTX 2080 Ti 11GB |
26+
| train_ASR_transformer_with_wav2vect.yaml | No | 5.58 | 5.19 | 1xRTX 8000 Ti 48GB |
2627

2728
You can checkout our results (models, training logs, etc,) here:
28-
https://drive.google.com/drive/folders/1CCNbl5iHPIANYtuH5eF9uYKZG-Pc-EUy?usp=sharing
29-
30-
29+
https://drive.google.com/drive/folders/1xKo_6Pxk0saPXjGZg8um68b_l0Tgfdjy?usp=sharing
30+
31+
# Training Time
32+
It takes about 1h 10 minutes on a NVIDIA V100 (32GB) for train_ASR_transformer.yaml,
33+
and about 5 hours minutes on a NVIDIA V100 (32GB) for rain_ASR_transformer_with_wav2vect.yaml.
34+
35+
36+
# PreTrained Model + Easy-Inference
37+
You can find the pre-trained model with an easy-inference function on HuggingFace
38+
- https://huggingface.co/speechbrain/asr-transformer-aishell
39+
- https://huggingface.co/speechbrain/asr-wav2vec2-transformer-aishell
40+
41+
42+
# **About SpeechBrain**
43+
- Website: https://speechbrain.github.io/
44+
- Code: https://github.com/speechbrain/speechbrain/
45+
- HuggingFace: https://huggingface.co/speechbrain/
46+
47+
48+
# **Citing SpeechBrain**
49+
Please, cite SpeechBrain if you use it for your research or business.
50+
51+
```bibtex
52+
@misc{speechbrain,
53+
title={{SpeechBrain}: A General-Purpose Speech Toolkit},
54+
author={Mirco Ravanelli and Titouan Parcollet and Peter Plantinga and Aku Rouhe and Samuele Cornell and Loren Lugosch and Cem Subakan and Nauman Dawalatabad and Abdelwahab Heba and Jianyuan Zhong and Ju-Chieh Chou and Sung-Lin Yeh and Szu-Wei Fu and Chien-Feng Liao and Elena Rastorgueva and François Grondin and William Aris and Hwidong Na and Yan Gao and Renato De Mori and Yoshua Bengio},
55+
year={2021},
56+
eprint={2106.04624},
57+
archivePrefix={arXiv},
58+
primaryClass={eess.AS},
59+
note={arXiv:2106.04624}
60+
}
61+
```

0 commit comments

Comments
 (0)