From b508581f9d3c0bbce0240cedcf3c852f205cd68f Mon Sep 17 00:00:00 2001 From: Kushashwa Ravi Shrimali Date: Tue, 16 Aug 2022 18:43:36 +0530 Subject: [PATCH 1/3] Remove `sd2` sound extensions from supported audio extensions (#1409) --- CHANGELOG.md | 2 ++ flash/audio/classification/data.py | 8 ++++---- flash/audio/speech_recognition/data.py | 8 ++++---- flash/core/data/utilities/loading.py | 1 - 4 files changed, 10 insertions(+), 9 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index cc038e9a92..d7a9a00a0f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -42,6 +42,8 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/). ### Removed +- Removed support for audio files with `sd2` extension, because SoundFile (for sd2 extension) doesn't accept fsspec objects. ([#1409](https://github.com/Lightning-AI/lightning-flash/pull/1409)) + ### Fixed - Fixed JIT tracing tests where the model class was not attached to the `Trainer` class ([#1410](https://github.com/Lightning-AI/lightning-flash/pull/1410)) diff --git a/flash/audio/classification/data.py b/flash/audio/classification/data.py index 29d192211e..7b802475e7 100644 --- a/flash/audio/classification/data.py +++ b/flash/audio/classification/data.py @@ -72,7 +72,7 @@ def from_files( ``.bmp``, ``.pgm``, ``.tif``, ``.tiff``, ``.webp``, and ``.npy``. The supported file extensions for raw audio (where spectrograms will be computed automatically) are: ``.aiff``, ``.au``, ``.avr``, ``.caf``, ``.flac``, ``.mat``, ``.mat4``, ``.mat5``, ``.mpc2k``, ``.ogg``, ``.paf``, - ``.pvf``, ``.rf64``, ``.sd2``, ``.ircam``, ``.voc``, ``.w64``, ``.wav``, ``.nist``, and ``.wavex``. + ``.pvf``, ``.rf64``, ``.ircam``, ``.voc``, ``.w64``, ``.wav``, ``.nist``, and ``.wavex``. The targets can be in any of our :ref:`supported classification target formats `. To learn how to customize the transforms applied for each stage, read our @@ -184,7 +184,7 @@ def from_folders( ``.bmp``, ``.pgm``, ``.tif``, ``.tiff``, ``.webp``, and ``.npy``. The supported file extensions for raw audio (where spectrograms will be computed automatically) are: ``.aiff``, ``.au``, ``.avr``, ``.caf``, ``.flac``, ``.mat``, ``.mat4``, ``.mat5``, ``.mpc2k``, ``.ogg``, ``.paf``, - ``.pvf``, ``.rf64``, ``.sd2``, ``.ircam``, ``.voc``, ``.w64``, ``.wav``, ``.nist``, and ``.wavex``. + ``.pvf``, ``.rf64``, ``.ircam``, ``.voc``, ``.w64``, ``.wav``, ``.nist``, and ``.wavex``. For train, test, and validation data, the folders are expected to contain a sub-folder for each class. Here's the required structure: @@ -505,7 +505,7 @@ def from_data_frame( ``.bmp``, ``.pgm``, ``.tif``, ``.tiff``, ``.webp``, and ``.npy``. The supported file extensions for raw audio (where spectrograms will be computed automatically) are: ``.aiff``, ``.au``, ``.avr``, ``.caf``, ``.flac``, ``.mat``, ``.mat4``, ``.mat5``, ``.mpc2k``, ``.ogg``, ``.paf``, - ``.pvf``, ``.rf64``, ``.sd2``, ``.ircam``, ``.voc``, ``.w64``, ``.wav``, ``.nist``, and ``.wavex``. + ``.pvf``, ``.rf64``, ``.ircam``, ``.voc``, ``.w64``, ``.wav``, ``.nist``, and ``.wavex``. The targets will be extracted from the ``target_fields`` in the DataFrame and can be in any of our :ref:`supported classification target formats `. To learn how to customize the transforms applied for each stage, read our @@ -666,7 +666,7 @@ def from_csv( ``.bmp``, ``.pgm``, ``.tif``, ``.tiff``, ``.webp``, and ``.npy``. The supported file extensions for raw audio (where spectrograms will be computed automatically) are: ``.aiff``, ``.au``, ``.avr``, ``.caf``, ``.flac``, ``.mat``, ``.mat4``, ``.mat5``, ``.mpc2k``, ``.ogg``, ``.paf``, - ``.pvf``, ``.rf64``, ``.sd2``, ``.ircam``, ``.voc``, ``.w64``, ``.wav``, ``.nist``, and ``.wavex``. + ``.pvf``, ``.rf64``, ``.ircam``, ``.voc``, ``.w64``, ``.wav``, ``.nist``, and ``.wavex``. The targets will be extracted from the ``target_fields`` in the CSV files and can be in any of our :ref:`supported classification target formats `. To learn how to customize the transforms applied for each stage, read our diff --git a/flash/audio/speech_recognition/data.py b/flash/audio/speech_recognition/data.py index 85a993ebe0..e7c64d0c03 100644 --- a/flash/audio/speech_recognition/data.py +++ b/flash/audio/speech_recognition/data.py @@ -60,7 +60,7 @@ def from_files( and corresponding lists of targets. The supported file extensions are: ``.aiff``, ``.au``, ``.avr``, ``.caf``, ``.flac``, ``.mat``, ``.mat4``, - ``.mat5``, ``.mpc2k``, ``.ogg``, ``.paf``, ``.pvf``, ``.rf64``, ``.sd2``, ``.ircam``, ``.voc``, ``.w64``, + ``.mat5``, ``.mpc2k``, ``.ogg``, ``.paf``, ``.pvf``, ``.rf64``, ``.ircam``, ``.voc``, ``.w64``, ``.wav``, ``.nist``, and ``.wavex``. To learn how to customize the transforms applied for each stage, read our :ref:`customizing transforms guide `. @@ -153,7 +153,7 @@ def from_csv( Input audio file paths will be extracted from the ``input_field`` column in the CSV files. The supported file extensions are: ``.aiff``, ``.au``, ``.avr``, ``.caf``, ``.flac``, ``.mat``, ``.mat4``, - ``.mat5``, ``.mpc2k``, ``.ogg``, ``.paf``, ``.pvf``, ``.rf64``, ``.sd2``, ``.ircam``, ``.voc``, ``.w64``, + ``.mat5``, ``.mpc2k``, ``.ogg``, ``.paf``, ``.pvf``, ``.rf64``, ``.ircam``, ``.voc``, ``.w64``, ``.wav``, ``.nist``, and ``.wavex``. The targets will be extracted from the ``target_field`` in the CSV files. To learn how to customize the transforms applied for each stage, read our @@ -342,7 +342,7 @@ def from_json( Input audio file paths will be extracted from the ``input_field`` field in the JSON files. The supported file extensions are: ``.aiff``, ``.au``, ``.avr``, ``.caf``, ``.flac``, ``.mat``, ``.mat4``, - ``.mat5``, ``.mpc2k``, ``.ogg``, ``.paf``, ``.pvf``, ``.rf64``, ``.sd2``, ``.ircam``, ``.voc``, ``.w64``, + ``.mat5``, ``.mpc2k``, ``.ogg``, ``.paf``, ``.pvf``, ``.rf64``, ``.ircam``, ``.voc``, ``.w64``, ``.wav``, ``.nist``, and ``.wavex``. The targets will be extracted from the ``target_field`` field in the JSON files. To learn how to customize the transforms applied for each stage, read our @@ -468,7 +468,7 @@ def from_datasets( * A PyTorch Dataset where the ``__getitem__`` returns a dict: ``{"input": file_path, "target": target}`` The supported file extensions are: ``.aiff``, ``.au``, ``.avr``, ``.caf``, ``.flac``, ``.mat``, ``.mat4``, - ``.mat5``, ``.mpc2k``, ``.ogg``, ``.paf``, ``.pvf``, ``.rf64``, ``.sd2``, ``.ircam``, ``.voc``, ``.w64``, + ``.mat5``, ``.mpc2k``, ``.ogg``, ``.paf``, ``.pvf``, ``.rf64``, ``.ircam``, ``.voc``, ``.w64``, ``.wav``, ``.nist``, and ``.wavex``. To learn how to customize the transforms applied for each stage, read our :ref:`customizing transforms guide `. diff --git a/flash/core/data/utilities/loading.py b/flash/core/data/utilities/loading.py index d42a007287..7522882f30 100644 --- a/flash/core/data/utilities/loading.py +++ b/flash/core/data/utilities/loading.py @@ -46,7 +46,6 @@ ".paf", ".pvf", ".rf64", - ".sd2", ".ircam", ".voc", ".w64", From 0f822a04af6b74098856a2bf1a85a6bf50db2e40 Mon Sep 17 00:00:00 2001 From: Akihiro Nitta Date: Tue, 16 Aug 2022 22:14:10 +0900 Subject: [PATCH 2/3] CI: Set up dependabot for GitHub Actions (#1412) Co-authored-by: Kushashwa Ravi Shrimali --- .github/dependabot.yml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 .github/dependabot.yml diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000000..0cef51216f --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,14 @@ +# https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file +version: 2 +updates: + - package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: "weekly" + labels: + - "tests / CI" + pull-request-branch-name: + separator: "-" + open-pull-requests-limit: 5 + reviewers: + - "Lightning-AI/core-flash" From ff4c42e10044cb60584d6d92b741f29ecdc5ca45 Mon Sep 17 00:00:00 2001 From: Akihiro Nitta Date: Tue, 16 Aug 2022 22:14:50 +0900 Subject: [PATCH 3/3] CI: Update Windows from 2019 to 2022 (#1414) Co-authored-by: Akihiro Nitta Co-authored-by: Kushashwa Ravi Shrimali --- .github/workflows/ci-install-pkg.yml | 2 +- .github/workflows/ci-notebook.yml | 2 +- .github/workflows/ci-testing.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci-install-pkg.yml b/.github/workflows/ci-install-pkg.yml index 08569a05e3..8880b20dc5 100644 --- a/.github/workflows/ci-install-pkg.yml +++ b/.github/workflows/ci-install-pkg.yml @@ -33,7 +33,7 @@ jobs: # max-parallel: 6 matrix: # PyTorch 1.5 is failing on Win and bolts requires torchvision>=0.5 - os: [ubuntu-20.04, macOS-10.15] # , windows-2019 + os: [ubuntu-20.04, macOS-10.15] # , windows-2022 # fixme python-version: [3.7] # , 3.8 diff --git a/.github/workflows/ci-notebook.yml b/.github/workflows/ci-notebook.yml index 0ad6e975d8..14cfddc3ac 100644 --- a/.github/workflows/ci-notebook.yml +++ b/.github/workflows/ci-notebook.yml @@ -10,7 +10,7 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: [ubuntu-20.04, macOS-10.15, windows-2019] + os: [ubuntu-20.04, macOS-10.15, windows-2022] python-version: [3.8] # 3.6, env: TEST_ENV: TRUE diff --git a/.github/workflows/ci-testing.yml b/.github/workflows/ci-testing.yml index 46e1870aae..db15f4ef06 100644 --- a/.github/workflows/ci-testing.yml +++ b/.github/workflows/ci-testing.yml @@ -20,7 +20,7 @@ jobs: # max-parallel: 6 matrix: # PyTorch 1.5 is failing on Win and bolts requires torchvision>=0.5 - os: [ubuntu-20.04, macOS-10.15, windows-2019] + os: [ubuntu-20.04, macOS-10.15, windows-2022] python-version: [3.7, 3.9] requires: ['oldest', 'latest'] topic: [['core']]