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

Support compression level in i/o dispatcher backend #3662

Merged
merged 1 commit into from
Oct 19, 2023

Conversation

hwangjeff
Copy link
Contributor

Differential Revision: D50367721

@hwangjeff hwangjeff requested a review from a team as a code owner October 17, 2023 15:32
@pytorch-bot
Copy link

pytorch-bot bot commented Oct 17, 2023

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/audio/3662

Note: Links to docs will display an error until the docs builds have been completed.

✅ No Failures

As of commit 2192ce6 with merge base 671261c (image):
💚 Looks good so far! There are no failures yet. 💚

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D50367721

@@ -304,7 +306,13 @@ def save(
encoding: Optional[str] = None,
bits_per_sample: Optional[int] = None,
buffer_size: int = 4096,
compression: Optional[Union[torchaudio.io.CodecConfig, int]] = None,
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think that the compression type for sox should be float.

https://sox.sourceforge.net/soxformat.html

In order to squeeze the selection of VBR into the the −C value float we use negative numbers to select VRR. -4.2 would select default VBR encoding (size) with high quality (speed). One special case is 0, which is a valid VBR encoding parameter but not a valid bitrate. Compression value of 0 is always treated as a high quality vbr, as a result both -0.2 and 0.2 are treated as highest quality VBR (size) and high quality (speed).

hwangjeff added a commit to hwangjeff/audio that referenced this pull request Oct 17, 2023
Summary: Pull Request resolved: pytorch#3662

Differential Revision: D50367721
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D50367721

hwangjeff added a commit to hwangjeff/audio that referenced this pull request Oct 17, 2023
Summary: Pull Request resolved: pytorch#3662

Differential Revision: D50367721
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D50367721

hwangjeff added a commit to hwangjeff/audio that referenced this pull request Oct 18, 2023
Summary: Pull Request resolved: pytorch#3662

Differential Revision: D50367721
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D50367721

1 similar comment
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D50367721

hwangjeff added a commit to hwangjeff/audio that referenced this pull request Oct 18, 2023
Summary: Pull Request resolved: pytorch#3662

Differential Revision: D50367721

fbshipit-source-id: fbb6d62a6bdf6a55c98a8e94d08e344b8377f1dc
Summary: Pull Request resolved: pytorch#3662

Differential Revision: D50367721
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D50367721

@facebook-github-bot facebook-github-bot merged commit 7ea108f into pytorch:main Oct 19, 2023
47 of 48 checks passed
@github-actions
Copy link

Hey @None.
You merged this PR, but labels were not properly added. Please add a primary and secondary label (See https://github.com/pytorch/audio/blob/main/.github/process_commit.py).


Some guidance:

Use 'module: ops' for operations under 'torchaudio/{transforms, functional}', and ML-related components under 'torchaudio/csrc' (e.g. RNN-T loss).

Things in "examples" directory:

  • 'recipe' is applicable to training recipes under the 'examples' folder,
  • 'tutorial' is applicable to tutorials under the “examples/tutorials” folder
  • 'example' is applicable to everything else (e.g. C++ examples)
  • 'module: docs' is applicable to code documentations (not to tutorials).

Regarding examples in code documentations, please also use 'module: docs'.

Please use 'other' tag only when you’re sure the changes are not much relevant to users, or when all other tags are not applicable. Try not to use it often, in order to minimize efforts required when we prepare release notes.


When preparing release notes, please make sure 'documentation' and 'tutorials' occur as the last sub-categories under each primary category like 'new feature', 'improvements' or 'prototype'.

Things related to build are by default excluded from the release note, except when it impacts users. For example:
* Drop support of Python 3.7.
* Add support of Python 3.X.
* Change the way a third party library is bound (so that user needs to install it separately).

mthrok pushed a commit to mthrok/audio that referenced this pull request Oct 19, 2023
Differential Revision: D50367721

Pull Request resolved: pytorch#3662
mthrok pushed a commit to mthrok/audio that referenced this pull request Oct 19, 2023
Differential Revision: D50367721

Pull Request resolved: pytorch#3662
mthrok added a commit that referenced this pull request Oct 20, 2023
Differential Revision: D50367721

Pull Request resolved: #3662
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants