[CLAM] Questions about SMSTools (Frame Segmentation).
Matthias Geier
matthias.geier at gmail.com
Mon Feb 20 07:51:30 PST 2006
Moltes gràcies!
Thanks very much for the quick and helpful answer.
OK, the first frame I get from the SDIF file (using sdif-matlab
http://recherche.ircam.fr/equipes/analyse-synthese/sdif/download/sdif-matlab/)
has indeed centerTime = 0 sec.
> The center times should be multiples of the HopSize indeed. If you look at
> the SMSAnalysis.cxx file (around line 146) this is the formulation:
>
> TTime frameCenterTime=frameIndex*step/samplingRate;
>
> (http://clam.iua.upf.es/CLAM-doxygen/SMSAnalysis_8cxx-source.html)
Thanks for the link. I wouldn't have found it by myself ...
But now to the initial problem with the number of frames:
It occurred when I was analyzing a soundfile with 19200 samples.
I would have split that (using the standard values Hopsize=256 and
FrameLength=2049) into 75 frames, but SMSTools splits it into 76
frames!
Wouldn't that mean, that the sample in the center of the 76th frame is zero?
A soundfile with 19201 samples, however, is split into 76 frames by
both me and SMSTools. We also agree on splitting 19199 samples into 75
frames.
I also tried that on 2048 samples and maybe its the same for all
integer multiples of the HopSize?
Now please tell me:
Am I calculating correctly?
Is there a bug in SMSTools?
Or a feature which I don't recognize as such?
Maybe the relevant part is in the very same Function as mentioned
above around line 154:
if(frameCenterTime>in.GetAudio().GetDuration()*0.001)
return false;
why doesn't it say the following?
if(frameIndex*step>in.GetAudio().GetSize())
return false;
Or something similar? I don't really know C++, so I don't know if that
would work.
Greetings,
Matthias
More information about the clam-users
mailing list