PermutationScorer Class Reference

#include <PermutationScorer.h>

Inheritance diagram for PermutationScorer:

Inheritance graph
[legend]
Collaboration diagram for PermutationScorer:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 PermutationScorer (const std::string &distanceMetric="HAMMING", const std::string &config=std::string())
void setReferenceFiles (const std::vector< std::string > &referenceFiles)
void prepareStats (size_t sid, const std::string &text, ScoreStats &entry)
size_t NumberOfScores () const
bool useAlignment () const

Static Public Attributes

static const int SCORE_PRECISION = 5

Protected Member Functions

statscore_t calculateScore (const std::vector< int > &scores) const
 PermutationScorer (const PermutationScorer &)
 ~PermutationScorer ()
PermutationScoreroperator= (const PermutationScorer &)
int getNumberWords (const std::string &line) const

Protected Attributes

distanceMetricReferenceChoice_t m_refChoiceStrategy
distanceMetric_t m_distanceMetric
std::vector< std::vector
< Permutation > > 
m_referencePerms
std::vector< size_t > m_sourceLengths
std::vector< std::string > m_referenceAlignments


Detailed Description

Permutation

Definition at line 23 of file PermutationScorer.h.


Constructor & Destructor Documentation

PermutationScorer::PermutationScorer ( const std::string &  distanceMetric = "HAMMING",
const std::string &  config = std::string() 
)

PermutationScorer::PermutationScorer ( const PermutationScorer  )  [protected]

PermutationScorer::~PermutationScorer (  )  [inline, protected]

Definition at line 46 of file PermutationScorer.h.


Member Function Documentation

statscore_t PermutationScorer::calculateScore ( const std::vector< int > &  totals  )  const [protected, virtual]

Calculate the actual score.

Implements StatisticsBasedScorer.

int PermutationScorer::getNumberWords ( const std::string &  line  )  const [protected]

size_t PermutationScorer::NumberOfScores (  )  const [inline, virtual]

Return the number of statistics needed for the computation of the score.

Implements Scorer.

Definition at line 33 of file PermutationScorer.h.

PermutationScorer& PermutationScorer::operator= ( const PermutationScorer  )  [protected]

void PermutationScorer::prepareStats ( size_t  sid,
const std::string &  text,
ScoreStats entry 
)

void PermutationScorer::setReferenceFiles ( const std::vector< std::string > &  referenceFiles  )  [virtual]

Set the reference files. This must be called before prepareStats().

Reimplemented from Scorer.

bool PermutationScorer::useAlignment (  )  const [inline]

Definition at line 37 of file PermutationScorer.h.


Member Data Documentation

Definition at line 51 of file PermutationScorer.h.

Definition at line 50 of file PermutationScorer.h.

std::vector<std::string> PermutationScorer::m_referenceAlignments [protected]

Definition at line 57 of file PermutationScorer.h.

std::vector< std::vector<Permutation> > PermutationScorer::m_referencePerms [protected]

Definition at line 55 of file PermutationScorer.h.

std::vector<size_t> PermutationScorer::m_sourceLengths [protected]

Definition at line 56 of file PermutationScorer.h.

const int PermutationScorer::SCORE_PRECISION = 5 [static]

Definition at line 31 of file PermutationScorer.h.


The documentation for this class was generated from the following files:

Generated on Sat Jun 30 00:30:12 2012 for Moses by  doxygen 1.5.9