running praat vocal toolkit with parselmouth

54 views
Skip to first unread message

Rafael Valle

unread,
Oct 15, 2021, 1:20:44 PM10/15/21
to Parselmouth
hi all!

does anybody know how to run functions in praat's vocal toolkit through parselmouth?
the code below doesn't seem to work :-| 

import parselmouth
from parselmouth.praat import call
sound = parselmouth.Sound(y, sampling_frequency=sr)
sound_alt = call(sound, "Whisper")

yannick...@gmail.com

unread,
Oct 28, 2021, 1:47:16 PM10/28/21
to Parselmouth
Hi! Sorry for the delay in replying; I had somehow missed this email!

You should be able to find a script file with the name `Whisper.praat` in the Praat plugin folder. If you know the path, you can pass that to `parselmouth.praat.run_file(sound, "the/path/of/the/plugin's/Whisper.praat")`.
I've looked into actually loading extensions into Parselmouth, but Praat crashed (and it would also do that in "batch mode" from the command line; so there's not a lot Parselmouth can do about it).

If you're curious about the details and the bug I logged to Praat, see https://github.com/praat/praat/issues/1583
So, translating their workaround to Parselmouth, you should go through `parselmouth.praat.run_file` :-)

If this somehow doesn't work, please let me know!
Reply all
Reply to author
Forward
0 new messages