Macro - export sound as separated clips with macro

Help for Audacity on macOS.
Forum rules
ImageThis forum is for Audacity on macOS 10.4 and later.
Please state which version of macOS you are using,
and the exact three-section version number of Audacity from "Audacity menu > About Audacity".


Audacity 1.2.x and 1.3.x are obsolete and no longer supported. If you still have those versions, please upgrade at https://www.audacityteam.org/download/.
The old forums for those versions are now closed, but you can still read the archives of the 1.2.x and 1.3.x forums.
Post Reply
mikesa8
Posts: 2
Joined: Sat Dec 19, 2020 3:05 am
Operating System: macOS 10.15 Catalina or later

Macro - export sound as separated clips with macro

Post by mikesa8 » Sat Dec 19, 2020 3:14 am

Hi, I have been looking at various places on how to export individual clips on macro, but I am having difficulties...

I have several audio files and I would like to apply sound finder, and then export the founded sound as individual clips.

e.g.) audio-1.mp3, audio-2.mp3, audio-3.mp3 each has 5 sounds separated by sound finder, and I would like to export them as individual clips. (For this example, it's 5 sound, but each audio files have various number of sounds.

audio-1.mp3 → audio-1-1.mp3, audio-1-2.mp3, audio-1-3.mp3, audio-1-4.mp3, audio-1-5.mp3
audio-2.mp3 → audio-2-1.mp3, audio-2-2.mp3, audio-2-3.mp3, audio-2-4.mp3, audio-2-5.mp3
audio-3.mp3 → audio-3-1.mp3, audio-3-2.mp3, audio-3-3.mp3, audio-3-4.mp3, audio-3-5.mp3

jademan
Forum Crew
Posts: 1171
Joined: Fri Jul 17, 2009 10:11 pm
Operating System: Please select

Re: Macro - export sound as separated clips with macro

Post by jademan » Sat Dec 19, 2020 12:50 pm

mikesa8 wrote:
Sat Dec 19, 2020 3:14 am
e.g.) audio-1.mp3, audio-2.mp3, audio-3.mp3 each has 5 sounds separated by sound finder, and I would like to export them as individual clips. (For this example, it's 5 sound, but each audio files have various number of sounds.
You could make 5 copies of each file, and have the first macro find the first sound, etc. :D

For the general case I do not think you can do this with macros. The "Export as MP3" command does not take parameters and is going to export to the "macro-output" subdirectory using the filename of your original file, so there is going to be a one-to-one relationship. Also, currently you cannot loop within macros.

I am not sure, but you might be able to do this with nyquist or with mod-script-pipes. Good luck !

I hope this helps. :D

steve
Site Admin
Posts: 80697
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: Macro - export sound as separated clips with macro

Post by steve » Sat Dec 19, 2020 10:45 pm

mikesa8 wrote:
Sat Dec 19, 2020 3:14 am
I have several audio files and I would like to apply sound finder, and then export the founded sound as individual clips.

e.g.) audio-1.mp3, audio-2.mp3, audio-3.mp3 each has 5 sounds separated by sound finder, and I would like to export them as individual clips. (For this example, it's 5 sound, but each audio files have various number of sounds.
Can't you just use "Export Multiple" rather than a Macro? https://manual.audacityteam.org/man/exp ... tiple.html
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

mikesa8
Posts: 2
Joined: Sat Dec 19, 2020 3:05 am
Operating System: macOS 10.15 Catalina or later

Re: Macro - export sound as separated clips with macro

Post by mikesa8 » Sun Dec 20, 2020 12:28 am

steve wrote:
Sat Dec 19, 2020 10:45 pm
mikesa8 wrote:
Sat Dec 19, 2020 3:14 am
I have several audio files and I would like to apply sound finder, and then export the founded sound as individual clips.

e.g.) audio-1.mp3, audio-2.mp3, audio-3.mp3 each has 5 sounds separated by sound finder, and I would like to export them as individual clips. (For this example, it's 5 sound, but each audio files have various number of sounds.
Can't you just use "Export Multiple" rather than a Macro? https://manual.audacityteam.org/man/exp ... tiple.html
Thank you. Yes. I could do it individually manually, but I have more than 1000 files so, macro/automation is something I am looking for.

steve
Site Admin
Posts: 80697
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: Macro - export sound as separated clips with macro

Post by steve » Sun Dec 20, 2020 3:49 pm

mikesa8 wrote:
Sun Dec 20, 2020 12:28 am
Thank you. Yes. I could do it individually manually, but I have more than 1000 files so, macro/automation is something I am looking for.
Unfortunately, "Export Multiple" is not yet supported by Macros - if it were this would be easy.

Do all of the files have exactly 5 sounds that can be detected by sound finder?
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

Post Reply