21 #ifndef KALDI_ITF_CLUSTERABLE_ITF_H_    22 #define KALDI_ITF_CLUSTERABLE_ITF_H_ 1    58     KALDI_ERR << 
"This Clusterable object does not implement Scale().";
    62   virtual std::string 
Type() 
const = 0;
    65   virtual void Write(std::ostream &os, 
bool binary) 
const = 0;
    96 #endif  // KALDI_ITF_CLUSTERABLE_ITF_H_ virtual void Sub(const Clusterable &other)=0
Subtract other stats. 
 
This code computes Goodness of Pronunciation (GOP) and extracts phone-level pronunciation feature for...
 
virtual void Add(const Clusterable &other)=0
Add other stats. 
 
virtual std::string Type() const =0
Return a string that describes the inherited type. 
 
virtual void SetZero()=0
Set stats to empty. 
 
virtual BaseFloat Objf() const =0
Return the objective function associated with the stats [assuming ML estimation]. ...
 
virtual BaseFloat ObjfMinus(const Clusterable &other) const
Return the objective function of the subtracted object this - other. 
 
virtual Clusterable * Copy() const =0
Return a copy of this object. 
 
virtual BaseFloat Distance(const Clusterable &other) const
Return the objective function decrease from merging the two clusters, negated to be a positive number...
 
virtual void Scale(BaseFloat f)
Scale the stats by a positive number f [not mandatory to supply this]. 
 
virtual BaseFloat ObjfPlus(const Clusterable &other) const
Return the objective function of the combined object this + other. 
 
virtual BaseFloat Normalizer() const =0
Return the normalizer (typically, count) associated with the stats. 
 
virtual Clusterable * ReadNew(std::istream &os, bool binary) const =0
Read data from a stream and return the corresponding object (const function; it's a class member beca...
 
virtual void Write(std::ostream &os, bool binary) const =0
Write data to stream.