Re: Search and remove audio sections

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Nov 17, 2020 at 03:52:52PM +0000, Dani wrote:
> I have a bunch of old MP3 podcasts that have ads in them, at the beginning and the end. These are short bits of podcasts (up to 10 minutes each), and the ads are quite distracting.
> The ads are about 30 seconds long and usually have a small familiar jingle before they start and after they end. 
> I was wondering if there is an ability using SoX (or other tool) to do a "search and remove" on these, in a batch format - that would apply to hundreds of these files.
> Something in the form of:
> %jingle% -> the familiar jingle at the start and end of the ad, so... mimicking a made-up wildcard/regex search:
> Search for:  (%jingle% * %jingle%) ( * ) (%jingle% * %jingle%)
> Replace: ($2) - meaning - I leave only the center part.
> Is that something that can be done with audio?

I am very interested in comparing recordings and in searching sound
samples in recordings. I managed to work quite a lot on this last year
and my work may be sufficient for my purposes but is unfinished and I
have not tried to use it since a year. So it is not a ready solution but
something you can try to work on and improve. It should not be very
difficult to fit it to your purposes but more work is needed to make it
universal.

How it works. I really miss MPEG-7 in sox. There are even no beginnings
of it there so I have used mpeg7ease ease program to extract audio
spectrum envelopes of sound (aselnb script) and my program to compare or
search extracts. 

Generating ASEs (FILE may be any sound or video file understandable by
ffmpeg, eventually we use audio only):
	aselnb FILE…

Then we can compare various ~/.ease/cache/*.ease files and get a
positive result and time shift between them or negative one:
	aselnbcmp -v -c "$name1" "$name2"
	aselnbcmp -v -c -P 16 -S 8 "$name1" "$name2"

… or search one in another:
	aselnbcmp -v -s ~/.ease/cache/needle.ease ~/.ease/cache/haystack.ease

The software I have used or have written may be found in:
ftp://ftp.icm.edu.pl/private/rzm/patches/ase/

R.
-- 
„Walczy on z całym zapamiętaniem przeciwko intelektowi” - z akt personalnych prof. A. Baeumlera


_______________________________________________
Sox-users mailing list
Sox-users@xxxxxxxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/sox-users




[Index of Archives]     [Linux Sound]     [ALSA Users]     [ALSA Devel]     [Linux Audio Users]     [Linux Media]     [Kernel]     [Photo Sharing]     [Gimp]     [Yosemite News]     [Linux Media]

  Powered by Linux