Software to Batch Remove Silence . . .

Discussion in 'Working with Sound' started by tommyzai, Mar 9, 2024.

  1. tommyzai

    tommyzai Platinum Record

    Joined:
    Feb 7, 2012
    Messages:
    724
    Likes Received:
    201
    Can any software batch process to remove silence from the MIDDLE of a sample? I have a great app that will remove from either or both ends, but not from the center. This would be useful as I have many loops that have a long nothingness in the middle.
     
  2.  
  3. clone

    clone Audiosexual

    Joined:
    Feb 5, 2021
    Messages:
    6,788
    Likes Received:
    2,965
    say you mean like on old sample cds. there would be 1 cd track, with 5 or 6 loops in that one cd track, and then silence in between them.

    you want the wave editor to chop each segment of audio into a new loop, and discard those which are silence. So instead of 1 cd track, you would end up with the 5 or 6 audio loops as their own new wav file.

    Waveknife used to be the best for this. But it is for PC only. However, since you are not doing much more than simple batch editing; you really would not encounter some of the usual problems running a Windows program on a Mac, inside a VM. Like your audio interface, etc.

    I think I would try using Parallels Desktop to run Waveknife. You will have considerations like sample and bit rates. Or find another app with similar features.
     
  4. tommyzai

    tommyzai Platinum Record

    Joined:
    Feb 7, 2012
    Messages:
    724
    Likes Received:
    201
    Can Waveknife handle a 1000 samples at once (assuming my Mac can of course)? Can I set it to delete a predetermined amount of silence . . . let's say any silence that is more than 100ms or something???
     
  5. yabiss

    yabiss Platinum Record

    Joined:
    Dec 14, 2013
    Messages:
    647
    Likes Received:
    277
    Location:
    In my pants
    Audacity? Silence finder function
     
  6. BlossomwoodsCollection

    BlossomwoodsCollection Kapellmeister

    Joined:
    Feb 24, 2024
    Messages:
    84
    Likes Received:
    41
    Is that something RX 10 would be able to do? idk
     
  7. JMOUTTON

    JMOUTTON Audiosexual

    Joined:
    Jan 10, 2016
    Messages:
    1,089
    Likes Received:
    897
    Location:
    Virginia
    @BlossomwoodsCollection
    Yes RX__ should be able to handle this as well. Anything with a gate, split at gate and continue in batch mode will do this task.


    If you aren't afraid of using the command line SoX can do this, quickly and granularly. I don't think it's had an update in a while but that shouldn't matter look for it on SourceForge or whatever FOSS resource works for you, should be there.
     
  8. aymat

    aymat Audiosexual

    Joined:
    Dec 21, 2015
    Messages:
    1,352
    Likes Received:
    1,510
    I used Wavelab back in the day to do this. You can do this also with Cubase and Reaper:


     
    • Agree Agree x 1
    • Winner Winner x 1
    • List
  9. mondomorte

    mondomorte Producer

    Joined:
    Nov 24, 2020
    Messages:
    175
    Likes Received:
    127
    Location:
    Grava 4
    Yeah, I do this in Reaper quite often (usually for parsing sample CDs).
    If you try it, the Action you are looking for is 'Item: Auto trim/split items (remove silence)'.

    Running that Action brings up this dialogue so you can tweak the processing:
    Screen Shot 2024-03-09 at 6.50.41 PM.png
     
    • Like Like x 1
    • Agree Agree x 1
    • List
  10. clone

    clone Audiosexual

    Joined:
    Feb 5, 2021
    Messages:
    6,788
    Likes Received:
    2,965
    Is there a way to autosave each sample with an automatically created filename, in the case of chopping up a full cd? OR is there a second easy step? That was always most of the time and effort to do these. I'm not sure I'd want thousands of pre-chopped 16bit 44.1 samples either way. That's a recipe for a failed jog wheel.
     
  11. stopped

    stopped Producer

    Joined:
    Mar 22, 2016
    Messages:
    399
    Likes Received:
    128
    sound forge batch convertor can do this as well
     
    • Interesting Interesting x 1
    • List
  12. fiction

    fiction Audiosexual

    Joined:
    Jun 21, 2011
    Messages:
    1,903
    Likes Received:
    692
    Would you have an example command line using sox please?
    I've read the manual pages and whatever I thought should work didn't split the audio into multiple files, at least not by a reasonable level threshold and cut precision.
     
  13. mondomorte

    mondomorte Producer

    Joined:
    Nov 24, 2020
    Messages:
    175
    Likes Received:
    127
    Location:
    Grava 4
    Yes. In Reaper you would do the previously mentioned strip silence, and then select all items on the timeline (as I have done in the example below).
    From there you would go File -> Render, which brings up this dialogue:
    Screen Shot 2024-03-09 at 8.03.04 PM.png

    At the top of the menu where it says Source, you would choose 'Selected Media Items'.
    Right below that, where the Output section is, you have file name. You can write your own AND add wildcards. The wildcards are tags and naming conventions based on anything from sample rate, parent folder, frame rate, each items position on the timeline, the date and time of day, etc etc etc - you name it.

    It is a very comprehensive list of options:
    Screen Shot 2024-03-09 at 8.10.29 PM.png

    It's all very efficient!
     
    • Like Like x 2
    • Winner Winner x 1
    • List
  14. Utada Hikaru

    Utada Hikaru Producer

    Joined:
    Dec 8, 2015
    Messages:
    130
    Likes Received:
    95
    I also have plenty of sample CD's where I am trying to manage, order and tag them all by myself.
    For the samples inside audio tracks I use Waveknife, a very old but simple and very fast batch editor with parameters to adjust (volume and time thresholds).

    Then I use Bulk Rename Utility, here you can rename all the files you want in just one click, it has so many filters, its very powerful.

    Then what I am looking for is to add to their name files tags that says what kind of sound they are, this is veeery time consuming if you have GBs of samples and have to listen to them one by one, but now there are some very promising programs that are using AI and algorithm stuff. The best I have found is Sononym, it analyses all of your samples and it automatically tags them depending of the type of sound, then you can Batch rename all of them with the new tags. The program is not perfect yet but I would say it is more than 90% accurate at classifying sounds and samples.
     
  15. clone

    clone Audiosexual

    Joined:
    Feb 5, 2021
    Messages:
    6,788
    Likes Received:
    2,965
    oh and then in bottom left corner, you can do "do not render files that are likely silence". "Tracks with mono only media to mono files" is another nice option if you are chopping stuff up for your sampler. REAPER may be best answer for this. Waveknife was the old goto, but I do not think there was a Mac version. REAPER on Mac is probably a better option than screwing around with VM.
     
  16. JMOUTTON

    JMOUTTON Audiosexual

    Joined:
    Jan 10, 2016
    Messages:
    1,089
    Likes Received:
    897
    Location:
    Virginia
    Code:
    sox in.wav out.wav silence 1 0.5 1% 1 5.0 1% : newfile : restart
    This is the article I used to learn this function from a longtime ago. There are some new flags and I found that for best precision it's best to use hysteresis functions and set the gate opening really low than to have the gate open at a higher threshold.

    https://digitalcardboard.com/blog/2009/08/25/the-sox-of-silence/

    it worked pretty well for me though without the hysteresis to ignore short crackles and burst. I was getting too many files or splits in the middle of samples with a zero crossing split during a pause.
     
  17. boomoperator

    boomoperator Rock Star

    Joined:
    Oct 16, 2013
    Messages:
    622
    Likes Received:
    353
    A native Mac software that can also do this is the great batch audio tool 'Myriad' by then Audio file engineering, now Zynaptiq.
    But you can also ask your sister (last mirror).

    Myriad can batch extract at beats or at threshold levels, then create labels at those extraction points.
    I just checked, I couldn't figure out this label creation part, but extraction was very easy.
    For batch renaming I always use 'A Better Finder Rename', I guess the already mentioned Sononym can also be of help.
     
  18. xorome

    xorome Audiosexual

    Joined:
    Sep 28, 2021
    Messages:
    908
    Likes Received:
    688
    Just gonna repeat myself from the 'batch gain change' thread:

    GUI: Reaper
    CLI: Signet
    CLI, but hard mode: SoX or ffmpeg.

    CLI tools can be paired with 'fd' if you want to use all CPU cores.
     
  19. Xupito

    Xupito Audiosexual

    Joined:
    Jan 21, 2012
    Messages:
    7,102
    Likes Received:
    3,930
    Location:
    Europe
  20. tzzsmk

    tzzsmk Audiosexual

    Joined:
    Sep 13, 2016
    Messages:
    3,419
    Likes Received:
    2,092
    Location:
    Heart of Europe
    I don't think Reaper can do such thing comfortably from its batch converter,
    would probably go ffmpeg route this time, although bit tricky to code
     
  21. tzzsmk

    tzzsmk Audiosexual

    Joined:
    Sep 13, 2016
    Messages:
    3,419
    Likes Received:
    2,092
    Location:
    Heart of Europe
    @mondomorte I don't think your way would work very well,
    assuming there's one original item per track, if you split and remove silent areas you end up with multiple items in each track,
    then render would process selected items separately, but not contents of a track at once (unless glued first),
    and for convenience, I haven't seen Reaper being able to render tracks by time bounds of items within track, so it wouldn't be possible to render individual tracks at various lengths
     
Loading...
Loading...