[CLAM] There may be a bug in "audio.cxx"

Neediss Gu neediss at gmail.com
Wed Jul 19 06:23:57 PDT 2006


Hi Xavier and all,
   I am a student of Tongji University. Recently I am focus on Voice
Conversion research and find CLAM is my best choice to pilot HNM. But I find
that CLAM uses a few extern libs. That makes me hard to rebuild CLAM on
windows, and the released Windows version always crash in my laptop. So I am
now going to implement HNM in C code step by step, and reference on CLAM. I
have readed your thesis and know that you have implemented a matlab
prototype. If that matlab prototype can be released out, it will be
excellent even in matlab's ".p" type.
    Now let's back to the shadiness code.

1.
In "SpectrualAnalysis.cxx", line 136,
in.GetAudioChunk(0,in.GetSize()-1 ,mAudioFrame,true );
If the endIndex is non-inclusive, the why in.GetSize()-1? Is that because
the windows length is odd and throw the last sample?

nBytesToCopy=(endIndex-beginIndex+1)*sizeof(double);
It is my modification, not a different version of CLAM.

2.
In the papers of Xavier et al ( there are two Xavier, opps ), the window
length is pitch-synchronized, but CLAM code seems not do that.

3.
I want to do Voice Conversion. Could anyone help me to generate some
Analysis -> Transform -> Synthesis example output?
"Elvis.wav" is too special. Two of my samples are in the following URL.
http://neediss.googlepages.com/female.wav
http://neediss.googlepages.com/aboutit.wav

4.
Does anyone has console version of SMS? How can I get it?

5.
Congratulation on the win of ACM MM06 Open Souce Award.


////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
2006/7/19, Xavier Amatriain <xamat at iua.upf.edu>:
>
> Hi Gu,
>
> Nice way to introduce yourself to the list, with a bug in the guts of
> CLAM :)
>
> This code is rather obscure, I have problems  guessing it myself, but as
> far as I can
> tell there is no such bug.
>
> The issue is that the last index is non-inclusive. So if you  have
> beginIndex=0 and endIndex=10
> it means that you want to copy from 0 to 9, but not 10 (I know we should
> look for a better name
> for the argument).
>
> You say that in your code you have:
>
> nBytesToCopy=(endIndex-beginIndex+1)*sizeof(double);
>
> but in my local file I see:
>
> nBytesToCopy=(endIndex-beginIndex)*sizeof(double);
>
> Maybe you have a different version of CLAM?
>
> In any case, thanks for the feedback and we will look further into it.
>
> Neediss Gu wrote:
> > line 163:
> > //////////////////////////
> > if(endIndex>=GetSize())
> >  {
> >   TSize ending=endIndex-GetSize();
> >   memset(chunk.GetBuffer().GetPtr()+GetSize()-beginIndex
> > ,0,ending*sizeof(TData));
> >   endIndex=GetSize();
> >  }
> >
> > nBytesToCopy=(endIndex-beginIndex+1)*sizeof(double);
> > //////////////////////////
> > Maybe it should be changed to the following
> >
> > if(endIndex>=GetSize())
> >  {
> >   TSize ending=endIndex-GetSize()+1;
> >   memset(chunk.GetBuffer().GetPtr()+GetSize()-beginIndex
> > +offset,0,ending*sizeof(TData));
> >   endIndex=GetSize();
> >  }
> >
> > and  : size=endIndex-beginIndex; -> size=endIndex-beginIndex+1.
> >
> > --
> > Gu Renmin (Charles Neediss)
> > Image, Graph, Video, Speech, Audio, ...
> > CS Dept. of Tongji University, Shanghai, China
> > Cell:   +(86) 13816064123
> > Work hard, work smart!!!
> >
>
>


-- 
Gu Renmin (Charles Neediss)
Image, Graph, Video, Speech, Audio, ...
CS Dept. of Tongji University, Shanghai, China
Cell:   +(086) 013816064123
Work hard, work smart!!!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.clam-project.org/pipermail/clam-users-clam-project.org/attachments/20060719/49f501a7/attachment.html>


More information about the clam-users mailing list