pytorch / pytorch/audio

A Law

Open
#924 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
2.9k
Forks
799
Avg merge
58m
Merged PRs (30d)
3

Description

🚀 Feature

I would like to propose adding of A-Law to torchaudio.transforms

Motivation

A-law is a companding algorithm similar to mu-law (that is already in torchaudio). It is used in European 8-bit PCM systems. By convention, A-law is used for an international connection if at least one country uses it. With these transforms torchaudio would
enable even wider modelling capabilities of telephony audio.

Pitch

I imagine the API could be almost identical to MuLaw with one caveat - the compression parameter A would be an additional parameter. So at the end there would be two additional transforms ALawEncoding and ALawDecoding.

Additional context

I have already written the code and would be happy to open a PR.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in torchaudio.transforms by reading the existing MuLaw transforms, then compare the proposed API with the A-law algorithm described in the linked reference. Done means torchaudio provides ALawEncoding and ALawDecoding with the proposed compression parameter and behavior suitable for telephony audio.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
audio-video-rtc
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.