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

Add backend module and isolate backend-related functionalities #700

Merged
merged 1 commit into from Jun 8, 2020

Conversation

mthrok
Copy link
Collaborator

@mthrok mthrok commented Jun 5, 2020

This PR introduces torchaudio.backend module so that we can add proper decoupling and abstraction to audio backend.

Before:

torchaudio
├── _backend.py
├── _soundfile_backend.py
├── _sox_backend.py
...

After:

torchaudio
├── backend
│   ├── __init__.py
│   ├── soundfile_backend.py
│   ├── sox_backend.py
│   └── utils.py
...

@mthrok mthrok force-pushed the refactor-backend branch 6 times, most recently from 0139ac1 to ca0cdbc Compare June 8, 2020 21:19
@codecov
Copy link

codecov bot commented Jun 8, 2020

Codecov Report

Merging #700 into master will increase coverage by 0.04%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #700      +/-   ##
==========================================
+ Coverage   89.23%   89.28%   +0.04%     
==========================================
  Files          23       24       +1     
  Lines        2341     2342       +1     
==========================================
+ Hits         2089     2091       +2     
+ Misses        252      251       -1     
Impacted Files Coverage Δ
torchaudio/backend/soundfile_backend.py 97.01% <ø> (ø)
torchaudio/__init__.py 91.30% <100.00%> (-0.70%) ⬇️
torchaudio/backend/__init__.py 100.00% <100.00%> (ø)
torchaudio/backend/sox_backend.py 85.55% <100.00%> (ø)
torchaudio/backend/utils.py 92.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2fd32dd...8fcfb50. Read the comment docs.

@mthrok mthrok marked this pull request as ready for review June 8, 2020 22:18
@mthrok mthrok requested a review from vincentqb June 8, 2020 22:18
@mthrok mthrok changed the title Add backend module and put all the backend logics there Add backend module and isolate backend-related functionalities Jun 8, 2020
Copy link
Contributor

@vincentqb vincentqb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@mthrok mthrok merged commit e364289 into pytorch:master Jun 8, 2020
@mthrok
Copy link
Collaborator Author

mthrok commented Jun 8, 2020

Thanks

@mthrok mthrok deleted the refactor-backend branch June 8, 2020 22:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants