Author Topic: Can't manage to smooth the pitch of a file with concatenated syllables.  (Read 245 times)

VisitorG

  • Newbie
  • *
  • Posts: 1
    • View Profile
Hi,

I'm new to CDP, and I have come to seek your help, wise men.

I have a project where I need to concatenate syllables.
This is quite complicated for me, I am graphic developer and know nothing about sound technologies.
Still I managed to concatenate and blend the syllables with ffmpeg and filters,
But I have yet to do one task ffmpeg can't handle.

I need to smooth the pitch of what I have generated with ffmpeg.
The exemple I was given is the way Praat does it with the plugin VocalToolkit > Process > Pitch Smoothing.

I know I can actually use Pratt without the GUI, but we have worries regarding stability and efficiency. So it will be a last resort.

So I have looked around for something light that does the trick with command line and CDP seems to be the only one handle this.
Sox can smooth too apparently but for the life of me I couldn't find how to extract the pitch from it...

So here i am trying to use CDP for this, but with the lack of example on the web the best I could produce is this:

Code: [Select]
@echo off

del ~*

echo analyse
pvoc anal 1 .sample.wav ~analysed.ana

echo:
echo get pitch
repitch getpitch 2 ~analysed.ana ~junk1.ana ~pitch.brk
repitch getpitch 1 ~analysed.ana ~junk2.ana ~pitch.frq

echo:
echo smooth pitch
::repitch smooth 1 ~pitch.frq ~smoothedpitch.frq 80
repitch smooth 2 ~pitch.frq ~smoothedtransposition.trn 80

echo:
echo transpose
repitch transpose 4 ~analysed.ana ~smoothedtransposition.trn ~out.ana
::repitch transposef 4 ~analysed.ana ~smoothedtransposition.trn ~out.ana -f100
::repitch transposef 4 ~analysed.ana ~smoothedtransposition.trn ~out.ana -p12

echo:
echo get new pitch
repitch getpitch 2 ~out.ana ~junk3.ana ~repitch.brk

echo:
echo synthetise
pvoc synth ~out.ana ~out.wav

(
for /l %%x in ( 1, 1, 8 ) do (
echo file .sample.wav
echo file ~out.wav
)
)>~playlist.txt

ffplay.exe -hide_banner -loglevel panic -autoexit -volume 10 -exitonkeydown -exitonmousedown -f concat -safe 0 -i ~playlist.txt

As I said, sound programming is not my specialty.
And I just tried randomly with most variables.
But I cannot get anything good.
The .wav is generated and plays fine, and it play, but it is just... well it just sounds bad, I can't even say if the pitch is smoothed in any way (although the values in the .brk files are smoother).

1/ Can I actually achieve what I am trying with CDP?
2/ What am I doing wrong?


Thanks a lot.