question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Add noisered and ladspa in sox_effects

See original GitHub issue

noisered and ladspa from here are not listed as an effect. Not picked up due to its interface?

>>> from torchaudio.sox_effects.sox_effects import effect_names
>>> torchaudio.__version__
'0.7.0a0+ac17b64'
>>> effect_names()
['allpass', 'band', 'bandpass', 'bandreject', 'bass', 'bend', 'biquad', 'chorus', 'channels', 'compand', 'contrast', 'dcshift', 'deemph', 'delay', 'dither', 'divide', 'downsample', 'earwax', 'echo', 'echos', 'equalizer', 'fade', 'fir', 'firfit', 'flanger', 'gain', 'highpass', 'hilbert', 'loudness', 'lowpass', 'mcompand', 'norm', 'oops', 'overdrive', 'pad', 'phaser', 'pitch', 'rate', 'remix', 'repeat', 'reverb', 'reverse', 'riaa', 'silence', 'sinc', 'speed', 'stat', 'stats', 'stretch', 'swap', 'synth', 'tempo', 'treble', 'tremolo', 'trim', 'upsample', 'vad', 'vol']
>>> 'noisered' in effect_names()
False

It affects facebookresearch/WavAugment#16.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
rien333commented, Aug 5, 2021

@mthrok Thanks for your quick and detailed reply! Following your instructions, I was able to add ladspa support.

1reaction
mthrokcommented, Aug 2, 2021

Hi @rien333

The build process has been changed since the time of above discussion, and ladspa is indeed explicitly disabled. This is because now we only support static build of libsox and because of an issue with in-memory decoding (for file-like object support) and many binary distribution of libsox provided by package manager has the issue. The issue with in-memory decoding has been patched on the latest dev version but there is no release that includes the patch.

I did not know much about ladspa, but according to your finding, the possible way to support is,

  1. install the latest libsox with dynamic linking and ladspa support (if file-like object support matters, otherwise you can use the version from your system’s package manager)
  2. change the way torchaudio is built so that it links to the libsox from step 1.

Step 2. is not straightforward for us because we do not know how many different environments we need to support, and this makes the build process prune to configuration errors. If you would like to try, you can look at the previous version of CMakeLists.txt. You need to make sure that the version of libsox you want to use shows up first in the search path.

Read more comments on GitHub >

github_iconTop Results From Across the Web

sox [global-options] [format-options] infile1
Any distortion introduced by quantisation is decorrelated by adding a small amount of white noise to the signal. In most cases, SoX can...
Read more >
man page soxeffect section 7
noisered [profile-file [amount]] Reduce noise in the audio signal by profiling and filtering. This effect is moderately effective at removing consistent back- ...
Read more >
sox(1) - Linux man page
Introduction. SoX reads and writes audio files in most popular formats and can optionally apply effects to them; it can combine multiple input...
Read more >
How to Install Audio Effects on Linux - VST3 and LADSPA ...
I tried to install a bunch of different 64 bit plugins; some worked, some locked-up as soon as it was added to a...
Read more >
torchaudio.sox_effects - PyTorch
torchaudio.sox_effects. Applying effects. Apply SoX effects chain on torch.Tensor or on file and load as torch.Tensor.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found