lightning-flash icon indicating copy to clipboard operation
lightning-flash copied to clipboard

Remove `sd2` sound extensions from supported audio extensions

Open krshrimali opened this issue 3 years ago • 2 comments

What does this PR do?

CI is failing, because SoundFile (for sd2 extension) doesn't accept fsspec objects. Following raises an error:

with fsspec.open(file_path) as _file:
    sound_file = SoundFile(_file)

Error raised:

RuntimeError: Error opening <fsspec.implementations.local.LocalFileOpener object at 0x100f4ac50>: Format not recognised

From discussion, we have decided to remove sd2 extension from supported audio extensions.

Before submitting

  • [ ] Was this discussed/approved via a Github issue? (no need for typos and docs improvements)
  • [ ] Did you read the contributor guideline, Pull Request section?
  • [ ] Did you make sure your PR does only one thing, instead of bundling different changes together?
  • [ ] Did you make sure to update the documentation with your changes?
  • [ ] Did you write any new necessary tests? [not needed for typos/docs]
  • [ ] Did you verify new and existing tests pass locally with your changes?
  • [ ] If you made a notable change (that affects users), did you update the CHANGELOG?

PR review

  • [ ] Is this pull request ready for review? (if not, please submit in draft mode)

Anyone in the community is free to review the PR once the tests have passed. If we didn't discuss your PR in Github issues there's a high chance it will not be merged.

Did you have fun?

Make sure you had fun coding 🙃

krshrimali avatar Aug 02 '22 11:08 krshrimali

Codecov Report

Merging #1409 (733777a) into master (2657315) will increase coverage by 0.34%. The diff coverage is n/a.

@@            Coverage Diff             @@
##           master    #1409      +/-   ##
==========================================
+ Coverage   91.79%   92.13%   +0.34%     
==========================================
  Files         286      286              
  Lines       12861    12861              
==========================================
+ Hits        11806    11850      +44     
+ Misses       1055     1011      -44     
Flag Coverage Δ
unittests 92.13% <ø> (+0.34%) :arrow_up:

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
flash/audio/classification/data.py 100.00% <ø> (+50.00%) :arrow_up:
flash/audio/speech_recognition/data.py 100.00% <ø> (+20.00%) :arrow_up:
flash/core/data/utilities/loading.py 98.52% <ø> (+23.52%) :arrow_up:
flash/graph/classification/input.py 45.45% <0.00%> (-54.55%) :arrow_down:
flash/graph/classification/cli.py 38.46% <0.00%> (-53.85%) :arrow_down:
flash/graph/collate.py 50.00% <0.00%> (-50.00%) :arrow_down:
flash/graph/classification/model.py 42.62% <0.00%> (-49.19%) :arrow_down:
flash/graph/embedding/model.py 54.83% <0.00%> (-45.17%) :arrow_down:
flash/graph/backbones.py 64.28% <0.00%> (-35.72%) :arrow_down:
flash/graph/classification/input_transform.py 66.66% <0.00%> (-33.34%) :arrow_down:
... and 15 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

codecov[bot] avatar Aug 02 '22 11:08 codecov[bot]

Seems like the error is only for '.sd2' files. Should we not just drop that format from support?

Yeah, let's do that. I agree 💯 I don't see any audio dataset having sd2 file extensions as well. Is it okay if I do this in this PR?

krshrimali avatar Aug 02 '22 12:08 krshrimali