Questions tagged [sox]

SoX (Sound eXchange) is a computer program for audio manipulation. Questions about interactive use of the command line tool should be asked on Super User.

Sound eXchange, abbreviated SoX, is a free cross-platform digital audio editor, licensed under the GNU General Public License.

It can read and write many audio formats, including AU, WAV, AIFF, MP3 (via an external LAME MP3 encoder), Ogg Vorbis and FLAC. Some random features :

  • Editing via concatenate, trim, pad, repeat, reverse, volume, fade, splice, normalise
  • Recording and playing audio (on many systems); playing via URL (internet file or stream)
  • Processing via chorus, flanger, echo, phaser, compressor, delay, filter (high-pass, low-pass, shelving, etc.)
  • Adjustment of speed (pitch and tempo), pitch (without tempo), tempo (without pitch), and sample-rate
  • Noise removal using frequency profiling
  • Silent passage removal
  • Multi-file merging, multi-file and multi-track mixing.
563 questions
0
votes
1 answer

windows SOX MP4/FFMPEG support

i'm trying to use SOX to cut certain mp3s, convert them to different formats and add fade in-out to the files. It works fine with mp3 to mp3 but when i try to convert it from an MP3 to an m4r i get the error: "sox FAIL formats: no handler for file…
user1125562
  • 11
  • 2
  • 4
0
votes
1 answer

sox multiple pad while mixing

here is a solution to pad a track while mixing with another track. Sox : merge two audio files with a pad $ sox short.ogg -p pad 6 0 | sox - -m long.ogg output.ogg How to use this command mixing multiple tracks? For example audio1.wav (no…
Michele
  • 1,468
  • 3
  • 24
  • 54
0
votes
1 answer

What to do with *.h.cmake file

I'm trying to build pysox (module to use SoX in Python). But mingw32-gcc show the error: "soxstdint.h: No such file". The SoX source code doesn't distribute a "soxstdint.h", only a "soxstdint.h.cmake". What do I have to do with it? I couldn't figure…
rynd
  • 1,865
  • 5
  • 22
  • 24
-1
votes
1 answer

To support decoding 'mp3' audio files, please install 'sox'

I'm trying to work on an ASR model using transfer learning on wav2vec 2 model. Anyway when I ever I wan't to show or modifiy an audio file I get this problem def prepare_dataset(batch): audio = batch["audio"] # batched output is…
FOXASDF
  • 43
  • 3
-1
votes
1 answer

SoX batch convert adding white noise

I'm trying to add white noise to hundreds of files. I find a command but don't know how to adapt it. There is a source folder with files and an empty destination folder. Could someone help me with the right command? I'm using…
b0h1
  • 3
  • 2
-1
votes
1 answer

Randomly silencing part of input audio in real time

My machine is running Ubuntu 20 LTS. I want to manipulate the input live audio in real-time. I have achieved pitch shifting using sox. The command being - sox -t pulseaudio default -t pulseaudio null pitch +1000 and then routing the audio from…
Nobody
  • 99
  • 1
  • 9
-1
votes
1 answer

How to use sox to record audio from command line

I want to record audio with this code: sox -d test.wav trim 0 20 but the problem is that it says: sox FAIL sox: Sorry, there is no default audio device configured and if I try some other sox codes it gives me help of sox. There is no other way to…
Sepehr Movasat
  • 49
  • 1
  • 10
-1
votes
1 answer

Multicast waveform generator

I'm working with a DAQ device that samples 32 analog channels and send it over udp using multicast. I'm saving all data using a Ubuntu linux laptop. For development purpose, I want to create a sine wave generator that emulates the DAQ device in…
Marco
  • 1
  • 3
-1
votes
1 answer

How can I remove gaps of 0.1 seconds in sox?

im use this command but i dont know how I could change the values for 0.1 seconds sox spokenxh.wav spokenx.wav silence 1 0.2 0.5% -1 0.2 0.5% please help me
MIGHTDUY
  • 49
  • 2
  • 10
-1
votes
1 answer

How to trim sound files in subfolders by using sox in Mac terminal?

I have got over 1000 folders, and each folder contains one .wav file and one .txt file (example of the folders). The text file contains the time interval, and I need to trim the .wav file into clips based on the time interval that each text file…
Bruce Wang
  • 33
  • 3
-1
votes
2 answers

play stat -freq What does the output mean?

What does the output of play $file stat -freq mean? I recently ran the command, here's a sample of the output: $ play 44100Hz/3660/6517/3660-6517-0024.flac stat -freq 44100Hz/3660/6517/3660-6517-0024.flac: File Size: 214k Bit Rate: 325k …
theonlygusti
  • 11,032
  • 11
  • 64
  • 119
-1
votes
1 answer

I need some slightly basic BASH help - find + execdir + sox

Ok, hello. I have some scripts that I use on the command line to rip mp3s from .wav and .aif files. Lately I've been playing with this sampler that wants only mono wav files. WAIT - I promise this is a programming question. I want to run a command…
-1
votes
1 answer

Layering 2 Audio Files at Set Times in Node.js

Just typed a massive question and realised I was wasting space and time, so I shortened it, will answer any questions of context if needed: PROBLEM I have a short audio file "name.mp3" and a long audio file "Vocals.mp3", and i'm trying to make an…
Tom Rowe
  • 1
  • 7
-1
votes
4 answers

Call an external command in Python

How can I call an external command (as if I'd typed it at the Unix shell) from within a Python script? I tried this code: from subprocess import call call(["ls", "-l"]) and it works. But when I try this code in a Python script: from subprocess…
Mat
  • 51
  • 1
  • 7
-1
votes
1 answer

SoX: What is the correct method to trim, pipe and concatenate audio files together?

I use the following code to trim, pipe and concatenate my audio files. sox "|sox audio.wav -p trim 0.000 =15.000" "|sox audio.wav -p trim 15.000" concatenated.wav One would expect that concatenated.wav will sound identical compared to…
Schinizer
  • 306
  • 3
  • 9
1 2 3
37
38