Modify 'Export Multiple'

Is there a way to have a plugin that will modify the export multiple command to add silence to the beginning or end of each track?

For my particular use case, it is language learning. I would like to take a bit of audio, label sections with a translation, and then export 3 different versions of each sentence.

One with padding of silence at the beginning, one at the end, and one with no padding. (for adding these to a playlist and having silence built in so the sentences can be repeated.)

Any ideas about automating that?

I tried using the little utility MP3Trimmer to add silence, but it works with sporadic success on the Audacity-produces mp3 files, though it works error-free with others.

Anyone know of a bug in the mp3 encoding that might cause that? Or another setting to try?

Thanks.

I found a workaround by learning how chains work. It re-encodes the file again, but I don’t care for my case.

I export multiple, and apply a chain a made to the created files that uses the Pauken Nyquist plugin to add the silence and re-export.

I didn’t realize that you could apply a chain to a bunch of files at once. That is pretty cool.

To add silence to the beginning, that plugin doesn’t work, but I just make several different chains for the different durations that I want to add.

I don’t know that plug-in. Where did you get it?

The “Trim / Extend” plug-in will probably do what you want. Missing features - Audacity Support

I got it here
https://forum.audacityteam.org/t/pauken-add-silence-and-repeat-chunk/29659/2

I used the trim/extend plugin to make the versions with silence before, but I’d really like the other one to have the option to put the silence at the beginning because it dynamically sets the amount of silence it adds.

If I knew how to modify the plugin to optionally add the silence at the beginning of the file rather than the end, that would be really awesome. Right now, I have to set up different chains for different durations.

You wouldn’t know of a simple change in the plugin to change where the silence is added do you?

;nyquist plug-in
;version 1
;type process
;name "Pauken - add silence and repeat chunk"
;action "Pauken - add silence and repeat chunk"
;info "Pauken adds silence and multiplies a selected fragment.nIt helps when you learn foreign languages bynlistening and repeating phrases after a speaker.nnby Oleg Parashchenko, olpa@ http://uucode.com/nReleased under GPL v2n"
;control parameters factor-dur n-repeats

;control factor-dur "Silence duration factor" real "1=the same duration, 2=twice longer, etc" 2 0 5
; number of repeats
;control n-repeats "N of repeats" int "" 20 1 40

(defun pauken (sound)
  (setq coeff-dur (1+ factor-dur))
  (setq dur (* (get-duration 1) coeff-dur))
  (setq chunks (cons
                 (s-rest (* coeff-dur n-repeats)) ; expected total duration
                 '()))
  (dotimes (i n-repeats)
    (setq chunks (cons
                   (at-abs (* i dur) (cue sound)) ; repeat at location
                   chunks)))
  (apply #'sim chunks)
  )

(multichan-expand #'pauken s)

I’ve written a new plug-in based on “Pauken” that can repeat the selection and optionally add silence before or after each repeat.
The new plug-in is called “Repeat with gaps…” and is available here: Pauken - add silence and repeat chunk - #7 by steve

For those who want to learn languages by repeating sentences in audio file, here is a procedure that has done the job for me (I know very little about Audacity).

A)Split audio file in sentences

  1. Open file with Audacity
  2. Mark sentences by applying Analyze/Sound Finder, I use option 24DB, 0.24 secs min duration, and 0.12 for each label starting and ending point. Test with other parameters as you may find it fit.
  3. Save each sentence as a separate mp3 file, by using File/Export Multiple and select Name file by numbering before label.
    Now you have all your sentences in separate files.

B)Add silence time at end of each sentence (in this example 1.7 x , adjust as needed)

  1. Download and install latest version of Audacity (at this time 2.1.0)
  2. Download and Install Chanel Mixer plug-in
    2.1) https://wiki.audacityteam.org/w/images/3/3d/Channel-mixer.zip, from https://wiki.audacityteam.org/wiki/Nyquist_Effect_Plug-ins page.
    2.2) Copy .py file into Audacity/Plug-ins directory.
  3. Open audio file with Audacity
  4. Create new Chain, from File Menu/Edit Chains, add, with the following commands:
    4.1) Channel-Mixer Mono Average
    4.2) Stereo-to-Monto
    4.3) Nyquist (choose legacy), Parameter:
    (setq silence-duration (mult 1.7 (get-duration 1)))
    (abs-env
    (seq s (s-rest silence-duration)))
    4.4) Normalize
    4.5) ExportMP3
  5. Test Chain in file
  6. Close file
  7. Choose Chain and apply to files.


    C) Put All Sentences back together into one file
  8. Use Audio Video Converter
  9. Select all files, select merge and convert to selected audio format.