public class MCepDatagram extends Datagram
| Modifier and Type | Field and Description |
|---|---|
protected float[] |
coeffs |
data, duration, NUM_HEADER_BYTES| Constructor and Description |
|---|
MCepDatagram(ByteBuffer bb,
int order)
Constructor which pops a datagram from a byte buffer.
|
MCepDatagram(long setDuration,
float[] coeffs)
Construct a MCep datagram from a float vector.
|
MCepDatagram(RandomAccessFile raf,
int order)
Constructor which pops a datagram from a random access file.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Datagram other)
Tests if this datagram is equal to another datagram.
|
float |
getCoeff(int i)
Get a particular Mel-Cepstrum coefficient.
|
float[] |
getCoeffs()
Get the array of Mel-Cepstrum coefficients.
|
double[] |
getCoeffsAsDouble()
Get the array of Mel-Cepstrum coefficients.
|
int |
getLength()
Get the length, in bytes, of the datagram's data field.
|
int |
order()
Get the order, i.e.
|
void |
write(DataOutput out)
Write this datagram to a random access file or data output stream.
|
equals, getData, getDuration, setDurationpublic MCepDatagram(long setDuration,
float[] coeffs)
setDuration - the duration, in samples, of the data represented by this datagramcoeffs - the array of Mel-Cepstrum coefficients.public MCepDatagram(RandomAccessFile raf, int order) throws IOException, EOFException
raf - the random access file to pop the datagram from.order - orderIOException - IOExceptionEOFException - EOFExceptionpublic MCepDatagram(ByteBuffer bb, int order) throws IOException, EOFException
bb - the byte buffer to pop the datagram from.order - orderIOException - IOExceptionEOFException - EOFExceptionpublic int getLength()
public int order()
getCoeffs()public float[] getCoeffs()
public double[] getCoeffsAsDouble()
public float getCoeff(int i)
i - ipublic void write(DataOutput out) throws IOException
write in class Datagramout - outIOException - IOExceptionpublic boolean equals(Datagram other)
other - otherCopyright © 2000–2016 DFKI GmbH. All rights reserved.