#include <ScoreArray.h>
Public Member Functions | |
ScoreArray () | |
~ScoreArray () | |
void | clear () |
std::string | getIndex () const |
void | setIndex (const std::string &value) |
ScoreStats & | get (std::size_t i) |
const ScoreStats & | get (std::size_t i) const |
void | add (const ScoreStats &e) |
void | swap (std::size_t i, std::size_t j) |
void | resize (std::size_t new_size) |
void | merge (ScoreArray &e) |
std::string | name () const |
void | name (std::string &score_type) |
std::size_t | size () const |
std::size_t | NumberOfScores () const |
void | NumberOfScores (std::size_t v) |
void | savetxt (std::ostream *os, const std::string &score_type) |
void | savebin (std::ostream *os, const std::string &score_type) |
void | save (std::ostream *os, const std::string &score_type, bool bin=false) |
void | save (const std::string &file, const std::string &score_type, bool bin=false) |
void | save (const std::string &score_type, bool bin=false) |
void | loadtxt (std::istream *is, std::size_t n) |
void | loadbin (std::istream *is, std::size_t n) |
void | load (std::istream *is) |
void | load (const std::string &file) |
bool | check_consistency () const |
Definition at line 23 of file ScoreArray.h.
ScoreArray::ScoreArray | ( | ) |
Definition at line 15 of file ScoreArray.cpp.
ScoreArray::~ScoreArray | ( | ) | [inline] |
Definition at line 36 of file ScoreArray.h.
void ScoreArray::add | ( | const ScoreStats & | e | ) | [inline] |
Definition at line 48 of file ScoreArray.h.
Referenced by merge(), and InterpolatedScorer::setScoreData().
bool ScoreArray::check_consistency | ( | ) | const |
Definition at line 150 of file ScoreArray.cpp.
References NumberOfScores().
void ScoreArray::clear | ( | ) | [inline] |
Definition at line 38 of file ScoreArray.h.
const ScoreStats& ScoreArray::get | ( | std::size_t | i | ) | const [inline] |
Definition at line 46 of file ScoreArray.h.
ScoreStats& ScoreArray::get | ( | std::size_t | i | ) | [inline] |
Definition at line 44 of file ScoreArray.h.
Referenced by merge(), Data::removeDuplicates(), StatisticsBasedScorer::score(), and SentenceLevelScorer::score().
std::string ScoreArray::getIndex | ( | ) | const [inline] |
Definition at line 40 of file ScoreArray.h.
Referenced by ScoreData::add().
void ScoreArray::load | ( | const std::string & | file | ) |
void ScoreArray::load | ( | std::istream * | is | ) |
void ScoreArray::loadbin | ( | std::istream * | is, | |
std::size_t | n | |||
) |
void ScoreArray::loadtxt | ( | std::istream * | is, | |
std::size_t | n | |||
) |
void ScoreArray::merge | ( | ScoreArray & | e | ) |
Definition at line 143 of file ScoreArray.cpp.
References add(), get(), and size().
void ScoreArray::name | ( | std::string & | score_type | ) | [inline] |
Definition at line 64 of file ScoreArray.h.
std::string ScoreArray::name | ( | ) | const [inline] |
Definition at line 62 of file ScoreArray.h.
void ScoreArray::NumberOfScores | ( | std::size_t | v | ) | [inline] |
Definition at line 70 of file ScoreArray.h.
std::size_t ScoreArray::NumberOfScores | ( | ) | const [inline] |
Definition at line 68 of file ScoreArray.h.
Referenced by check_consistency().
void ScoreArray::resize | ( | std::size_t | new_size | ) | [inline] |
Definition at line 55 of file ScoreArray.h.
Referenced by Data::removeDuplicates().
void ScoreArray::save | ( | const std::string & | score_type, | |
bool | bin = false | |||
) |
void ScoreArray::save | ( | const std::string & | file, | |
const std::string & | score_type, | |||
bool | bin = false | |||
) |
void ScoreArray::save | ( | std::ostream * | os, | |
const std::string & | score_type, | |||
bool | bin = false | |||
) |
void ScoreArray::savebin | ( | std::ostream * | os, | |
const std::string & | score_type | |||
) |
void ScoreArray::savetxt | ( | std::ostream * | os, | |
const std::string & | score_type | |||
) |
void ScoreArray::setIndex | ( | const std::string & | value | ) | [inline] |
Definition at line 42 of file ScoreArray.h.
Referenced by BOOST_AUTO_TEST_CASE(), and InterpolatedScorer::setScoreData().
std::size_t ScoreArray::size | ( | ) | const [inline] |
Definition at line 66 of file ScoreArray.h.
Referenced by merge(), Data::removeDuplicates(), StatisticsBasedScorer::score(), SentenceLevelScorer::score(), and InterpolatedScorer::setScoreData().
void ScoreArray::swap | ( | std::size_t | i, | |
std::size_t | j | |||
) | [inline] |
Definition at line 51 of file ScoreArray.h.
Referenced by Data::removeDuplicates().