Class ScoreCollector

Inheritance Relationships

Derived Type

Class Documentation

class ScoreCollector

Subclassed by marian::ScoreCollectorNBest

Public Functions

ScoreCollector(const Ptr<Options> &options)
virtual ~ScoreCollector()
void Write(long id, const std::string &message)
void Write(long id, float score, const data::SoftAlignment &align = {}, const std::vector<float> &wordScores = {})

Protected Types

typedef std::map<long, std::string> Outputs

Protected Functions

std::string getAlignment(const data::SoftAlignment &align)
float getAlignmentThreshold(const std::string &str)

Protected Attributes

long nextId_ = {0}
UPtr<std::ostream> outStrm_
std::mutex mutex_
Outputs outputs_
std::string alignment_
float alignmentThreshold_ = {0.f}