我正在使用 Audacity 处理一些短音频片段 - 大约 300 个(!!!),所以我真的不想为每个片段手动重复我的步骤。
但是,我似乎找不到创建包含“分离立体声音轨并丢弃右声道”步骤的链条的方法。我束手无策;有什么方法可以做到这一点吗?如果没有,是否有其他程序可以让我以自动化方式完成此操作?
答案1
我建议使用sox
针对这种情况。使用以下命令删除右声道:
sox in.wav out.wav remix 1
为了减少噪音,您需要从文件的静音部分获取噪音配置文件,即如下所示:
sox noisy.wav -n trim 0 1 noiseprof | play noisy.wav noisered
有关 noiseprof 和 noisered 的详细信息请参见下文。
因此,假设录音的第一秒仅包含背景噪音,每个文件的序列看起来会像这样:
sox in.wav -n remix 1 trim 0 1 noiseprof NOISE_PROFILE
sox in.wav out.wav remix 1 noisered NOISE_PROFILE
来自sox
男人:
noiseprof [profile-file]
Calculate a profile of the audio for use in noise reduction. See
the description of the noisered effect for details.
noisered [profile-file [amount]]
Reduce noise in the audio signal by profiling and filtering. This
effect is moderately effective at removing consistent background
noise such as hiss or hum. To use it, first run SoX with the
noiseprof effect on a section of audio that ideally would contain
silence but in fact contains noise - such sections are typically
found at the beginning or the end of a recording. noiseprof will
write out a noise profile to profile-file, or to stdout if no pro-
file-file or if `-' is given. E.g.
sox speech.wav -n trim 0 1.5 noiseprof speech.noise-profile
To actually remove the noise, run SoX again, this time with the
noisered effect; noisered will reduce noise according to a noise
profile (which was generated by noiseprof), from profile-file, or
from stdin if no profile-file or if `-' is given. E.g.
sox speech.wav cleaned.wav noisered speech.noise-profile 0.3
How much noise should be removed is specified by amount-a number
between 0 and 1 with a default of 0.5. Higher numbers will remove
more noise but present a greater likelihood of removing wanted com-
ponents of the audio signal. Before replacing an original record-
ing with a noise-reduced version, experiment with different amount
values to find the optimal one for your audio; use headphones to
check that you are happy with the results, paying particular atten-
tion to quieter sections of the audio.
On most systems, the two stages - profiling and reduction - can be
combined using a pipe, e.g.
sox noisy.wav -n trim 0 1 noiseprof | play noisy.wav noisered
答案2
我有一个可行的想法,但在我写出整个想法之前,先尝试一下:
- 获取 FFMPEG 版本:http://ffmpeg.zeranoe.com/builds/
- 提炼
- 使用以下参数运行 FFMPEG:
ffmpeg -i somefile.mp3 -ac 1 somefile.wav
这将加载 somefile.mp3,将音频通道限制为一个,希望删除正确的音频通道(正确的通道),然后将其吐出为 WAV 文件。
如果这不起作用,我们必须想办法ffmpeg
消除其他渠道。