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

Fix continuous integration #672

Merged
merged 11 commits into from
Jul 6, 2023
15 changes: 10 additions & 5 deletions .flake8
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,13 @@ verbose = 2
# https://pep8.readthedocs.io/en/latest/intro.html#error-codes
format = pylint
ignore =
E731 # E731 - Do not assign a lambda expression, use a def
W605 # W605 - invalid escape sequence '\_'. Needed for docs
W504 # W504 - line break after binary operator
W503 # W503 - line break before binary operator, need for black
E203 # E203 - whitespace before ':'. Opposite convention enforced by black
# E731 - Do not assign a lambda expression, use a def
E731
# W605 - invalid escape sequence '\_'. Needed for docs
W605
# W504 - line break after binary operator
W504
# W503 - line break before binary operator, need for black
W503
# E203 - whitespace before ':'. Opposite convention enforced by black
E203
4 changes: 2 additions & 2 deletions .github/workflows/test_asteroid_package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,14 +47,14 @@ jobs:

- name: Source code tests
run: |
coverage run -a -m py.test tests --ignore tests/models/publish_test.py
coverage run -a -m pytest tests --ignore tests/models/publish_test.py
chmod +x ./tests/cli_test.sh
./tests/cli_test.sh

# This tends to fail despite the code works, when Zenodo is slow.
- name: Model-sharing tests
run: |
coverage run -a -m py.test tests/models/publish_test.py
coverage run -a -m pytest tests/models/publish_test.py
env:
ACCESS_TOKEN: ${{ secrets.ACCESS_TOKEN }}

Expand Down
2 changes: 1 addition & 1 deletion asteroid/dsp/overlap_add.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ def __init__(
n_src,
window_size,
hop_size=None,
window="hanning",
window="hann",
reorder_chunks=True,
enable_grad=False,
):
Expand Down
3 changes: 2 additions & 1 deletion requirements/install.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
-r ./torchhub.txt
PyYAML>=5.0
pandas>=0.23.4
pytorch-lightning>=1.5.0,<2.0.0
pytorch-lightning>=1.5.0,<=1.7.7
torchmetrics<=0.11.4
torchaudio>=0.8.0
pb_bss_eval>=0.0.2
torch_stoi>=0.0.1
Expand Down
2 changes: 1 addition & 1 deletion requirements/torchhub.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Minimal set of requirements required to be able to run Asteroid models from Torch Hub.
# Note that Asteroid itself is not required to be installed.
numpy>=1.16.4
scipy>=1.1.0
scipy>=1.10.1
torch>=1.8.0,<2.0.0
asteroid-filterbanks>=0.4.0
requests
Expand Down
5 changes: 3 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,15 +38,16 @@ def find_version(*file_paths):
install_requires=[
# From requirements/torchhub.txt
"numpy>=1.16.4",
"scipy>=1.1.0",
"scipy>=1.10.1",
"torch>=1.8.0,<2.0.0",
"asteroid-filterbanks>=0.4.0",
"SoundFile>=0.10.2",
"huggingface_hub>=0.0.2",
# From requirements/install.txt
"PyYAML>=5.0",
"pandas>=0.23.4",
"pytorch-lightning>=1.5.0,<2.0.0",
"pytorch-lightning>=1.5.0,<=1.7.7",
"torchmetrics<=0.11.4",
"torchaudio>=0.5.0",
"pb_bss_eval>=0.0.2",
"torch_stoi>=0.1.2",
Expand Down
2 changes: 1 addition & 1 deletion tests/dsp/overlap_add_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
@pytest.mark.parametrize("length", [1390, 8372])
@pytest.mark.parametrize("batch_size", [1, 2])
@pytest.mark.parametrize("n_src", [1, 2])
@pytest.mark.parametrize("window", ["hanning", None])
@pytest.mark.parametrize("window", ["hann", None])
@pytest.mark.parametrize("window_size", [128])
@pytest.mark.parametrize("hop_size", [64])
def test_overlap_add(length, batch_size, n_src, window, window_size, hop_size):
Expand Down