Moses::PCFG::Pcfg Class Reference

#include <pcfg.h>

List of all members.

Public Types

typedef std::vector< std::size_t > Key
typedef std::map< Key, double > Map
typedef Map::iterator iterator
typedef Map::const_iterator const_iterator

Public Member Functions

 Pcfg ()
iterator begin ()
const_iterator begin () const
iterator end ()
const_iterator end () const
void Add (const Key &, double)
bool Lookup (const Key &, double &) const
void Read (std::istream &, Vocabulary &)
void Write (const Vocabulary &, std::ostream &) const


Detailed Description

Definition at line 36 of file pcfg.h.


Member Typedef Documentation

typedef Map::const_iterator Moses::PCFG::Pcfg::const_iterator

Definition at line 42 of file pcfg.h.

typedef Map::iterator Moses::PCFG::Pcfg::iterator

Definition at line 41 of file pcfg.h.

typedef std::vector<std::size_t> Moses::PCFG::Pcfg::Key

Definition at line 39 of file pcfg.h.

typedef std::map<Key, double> Moses::PCFG::Pcfg::Map

Definition at line 40 of file pcfg.h.


Constructor & Destructor Documentation

Moses::PCFG::Pcfg::Pcfg (  )  [inline]

Definition at line 44 of file pcfg.h.


Member Function Documentation

void Moses::PCFG::Pcfg::Add ( const Key key,
double  score 
)

Definition at line 32 of file pcfg.cc.

Referenced by Moses::PCFG::RuleCollection::CreatePcfg(), and Read().

Here is the caller graph for this function:

const_iterator Moses::PCFG::Pcfg::begin (  )  const [inline]

Definition at line 49 of file pcfg.h.

iterator Moses::PCFG::Pcfg::begin (  )  [inline]

Definition at line 46 of file pcfg.h.

Referenced by Read(), and Write().

Here is the caller graph for this function:

const_iterator Moses::PCFG::Pcfg::end (  )  const [inline]

Definition at line 56 of file pcfg.h.

iterator Moses::PCFG::Pcfg::end (  )  [inline]

Definition at line 53 of file pcfg.h.

Referenced by Write().

Here is the caller graph for this function:

bool Moses::PCFG::Pcfg::Lookup ( const Key key,
double &  score 
) const

Definition at line 36 of file pcfg.cc.

Referenced by Moses::PCFG::TreeScorer::Score().

Here is the caller graph for this function:

void Moses::PCFG::Pcfg::Read ( std::istream &  input,
Vocabulary vocab 
)

Definition at line 45 of file pcfg.cc.

References Add(), begin(), Moses::PCFG::NumberedSet< T, I >::Insert(), key, line, MosesTuning::split(), and trim().

Referenced by Moses::PCFG::PcfgScore::Main().

Here is the call graph for this function:

Here is the caller graph for this function:

void Moses::PCFG::Pcfg::Write ( const Vocabulary vocab,
std::ostream &  output 
) const

Definition at line 91 of file pcfg.cc.

References begin(), end(), key, and Moses::PCFG::NumberedSet< T, I >::Lookup().

Referenced by Moses::PCFG::PcfgExtract::Main().

Here is the call graph for this function:

Here is the caller graph for this function:


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

Generated on Thu Jun 4 00:32:52 2015 for Moses by  doxygen 1.5.9