Handles the standard binary sequence format in HTK.
Inheritance:
Public Fields
-
HTKHeader* header
- Contain the htk header informations
Public Methods
-
IOHTK(const char* filename_, bool one_file_is_one_sequence_=false, int max_load_=-1, bool is_sequential_=false)
- Reads the sequence contained in filename.
-
static void saveSequence(XFile* file, Sequence* sequence, HTKHeader* header_)
- Saves sequence in file using the HTK format
-
char* parmKind2Str(ParmKind kind, char* buf)
- HTK source code
Public Fields
-
int n_sequences
-
int frame_size
Public Methods
-
virtual int getNumberOfFrames(int t)
-
virtual void getSequence(int t, Sequence* sequence)
-
virtual int getTotalNumberOfFrames()
Inherited from Object:
Public Fields
-
Allocator* allocator
Public Methods
-
void addOption(const char* name, int size, void* ptr, const char* help="")
-
void addIOption(const char* name, int* ptr, int init_value, const char* help="")
-
void addROption(const char* name, real* ptr, real init_value, const char* help="")
-
void addBOption(const char* name, bool* ptr, bool init_value, const char* help="")
-
void addOOption(const char* name, Object** ptr, Object* init_value, const char* help="")
-
void setOption(const char* name, void* ptr)
-
void setIOption(const char* name, int option)
-
void setROption(const char* name, real option)
-
void setBOption(const char* name, bool option)
-
void setOOption(const char* name, Object* option)
-
virtual void loadXFile(XFile* file)
-
virtual void saveXFile(XFile* file)
-
void load(const char* filename)
-
void save(const char* filename)
-
void* operator new(size_t size, Allocator* allocator_=NULL)
-
void* operator new(size_t size, Allocator* allocator_, void* ptr_)
-
void operator delete(void* ptr)
Documentation
Handles the standard binary sequence format in HTK.
- HTKHeader* header
- Contain the htk header informations
- IOHTK(const char* filename_, bool one_file_is_one_sequence_=false, int max_load_=-1, bool is_sequential_=false)
- Reads the sequence contained in filename.
If one_file_is_one_sequence is false, getSequence() will return one sequence
with one frame at each call. (If calling getSequence(t, foo),
it will put in the sequence foo the frame corresponding to the line t of the file).
Note also that if one_file_is_one_sequence is false, the access to the IO must be
sequential when calling getSequence() if is_sequential is true. (Sequential mode
is faster).
If max_load_ is positive, it loads only the first max_load_ frames,
if one_file_is_one_sequence is false.
The file will be opened when reading the first sequence, and closed when reading the
last one if is_sequential is true. Otherwise, the file will be opened and closed
each time you call getSequence().
- static void saveSequence(XFile* file, Sequence* sequence, HTKHeader* header_)
- Saves sequence in file using the HTK format
- char* parmKind2Str(ParmKind kind, char* buf)
- HTK source code
- This class has no child classes.
- Author:
- Johnny Mariethoz (Johnny.Mariethoz@idiap.ch)
- See Also:
- IOBin
Alphabetic index HTML hierarchy of classes or Java
This page was generated with the help of DOC++.