PVAna: can't use in a -do?


I’m trying to use PVAna in a -do but i get weird results.
It only outputs either the last created file or a couple files.

I’m doing:

	var pvana = PVAna(path.fullPath);

It outputs the last file (in my case 15th), then if i evaluate again, it outputs the 10th one, then 15th again, another one close to 10 like 12th or 13th and so on…

Seems also that it’s accumulating packets on the server and freezes my computer.

Or anyone else have published a working code that converts audio files to .scpv by folder?

Multiple NRT servers running in the background… might do something strange. Under the hood, the Score:NRT render command takes an action to perform when the NRT render is finished. I could provide a similar thing in the .ana method that you can fire off when each analysis is done, then you can use a Condition to cue up the next process.
For now, you can wrap all of this in a Routine or Task, and after your pvana.ana call, add a small wait time … maybe 5.wait; ? It isn’t ideal, but that can get you moving today while I think about how best to fix this up.

1 Like

Oh ok i see… that’s where the OSC messages in the post window were going to and incrementing!
The Routine and -wait solution isn’t much of a pain, will do that.

Thanks and also thanks for this excellent pv library :slight_smile:

Great! and glad you find it of use.

1 Like

Forgot to mention that it worked perfectly down to 1.wait!