#include <PhraseOrientation.h>
Public Types | |
| enum | REO_MODEL_TYPE { REO_MODEL_TYPE_MSD, REO_MODEL_TYPE_MSLR, REO_MODEL_TYPE_MONO } |
| enum | REO_CLASS { REO_CLASS_LEFT, REO_CLASS_RIGHT, REO_CLASS_DLEFT, REO_CLASS_DRIGHT, REO_CLASS_UNKNOWN } |
| enum | REO_DIR { REO_DIR_L2R, REO_DIR_R2L, REO_DIR_BIDIR } |
Public Member Functions | |
| PhraseOrientation () | |
| PhraseOrientation (int sourceSize, int targetSize, const Alignment &alignment) | |
| PhraseOrientation (int sourceSize, int targetSize, const Moses::AlignmentInfo &alignTerm, const Moses::AlignmentInfo &alignNonTerm) | |
| PhraseOrientation (int sourceSize, int targetSize, const std::vector< std::vector< int > > &alignedToT, const std::vector< std::vector< int > > &alignedToS, const std::vector< int > &alignedCountS) | |
| REO_CLASS | GetOrientationInfo (int startF, int endF, REO_DIR direction) const |
| REO_CLASS | GetOrientationInfo (int startF, int startE, int endF, int endE, REO_DIR direction) const |
| const std::string | GetOrientationInfoString (int startF, int endF, REO_DIR direction=REO_DIR_BIDIR) const |
| const std::string | GetOrientationInfoString (int startF, int startE, int endF, int endE, REO_DIR direction=REO_DIR_BIDIR) const |
| void | IncrementPriorCount (REO_DIR direction, REO_CLASS orient, float increment) |
| bool | SourceSpanIsAligned (int index1, int index2) const |
| bool | TargetSpanIsAligned (int index1, int index2) const |
Static Public Member Functions | |
| static const std::string | GetOrientationString (const REO_CLASS orient, const REO_MODEL_TYPE modelType=REO_MODEL_TYPE_MSLR) |
| static void | WriteOrientation (std::ostream &out, const REO_CLASS orient, const REO_MODEL_TYPE modelType=REO_MODEL_TYPE_MSLR) |
| static void | WritePriorCounts (std::ostream &out, const REO_MODEL_TYPE modelType=REO_MODEL_TYPE_MSLR) |
Definition at line 40 of file PhraseOrientation.h.
Definition at line 45 of file PhraseOrientation.h.
Definition at line 46 of file PhraseOrientation.h.
Definition at line 44 of file PhraseOrientation.h.
| MosesTraining::PhraseOrientation::PhraseOrientation | ( | ) | [inline] |
Definition at line 48 of file PhraseOrientation.h.
| MosesTraining::PhraseOrientation::PhraseOrientation | ( | int | sourceSize, | |
| int | targetSize, | |||
| const Alignment & | alignment | |||
| ) |
Definition at line 35 of file PhraseOrientation.cpp.
| MosesTraining::PhraseOrientation::PhraseOrientation | ( | int | sourceSize, | |
| int | targetSize, | |||
| const Moses::AlignmentInfo & | alignTerm, | |||
| const Moses::AlignmentInfo & | alignNonTerm | |||
| ) |
Definition at line 63 of file PhraseOrientation.cpp.
References Moses::AlignmentInfo::begin(), and Moses::AlignmentInfo::end().

| MosesTraining::PhraseOrientation::PhraseOrientation | ( | int | sourceSize, | |
| int | targetSize, | |||
| const std::vector< std::vector< int > > & | alignedToT, | |||
| const std::vector< std::vector< int > > & | alignedToS, | |||
| const std::vector< int > & | alignedCountS | |||
| ) |
Definition at line 99 of file PhraseOrientation.cpp.
| PhraseOrientation::REO_CLASS MosesTraining::PhraseOrientation::GetOrientationInfo | ( | int | startF, | |
| int | startE, | |||
| int | endF, | |||
| int | endE, | |||
| REO_DIR | direction | |||
| ) | const |
Definition at line 293 of file PhraseOrientation.cpp.
References REO_CLASS_UNKNOWN, REO_DIR_L2R, REO_DIR_R2L, and REO_MODEL_TYPE_MSLR.
| PhraseOrientation::REO_CLASS MosesTraining::PhraseOrientation::GetOrientationInfo | ( | int | startF, | |
| int | endF, | |||
| REO_DIR | direction | |||
| ) | const |
Definition at line 271 of file PhraseOrientation.cpp.
Referenced by GetOrientationInfoString().

| const std::string MosesTraining::PhraseOrientation::GetOrientationInfoString | ( | int | startF, | |
| int | startE, | |||
| int | endF, | |||
| int | endE, | |||
| REO_DIR | direction = REO_DIR_BIDIR | |||
| ) | const |
Definition at line 243 of file PhraseOrientation.cpp.
References GetOrientationInfo(), GetOrientationString(), REO_CLASS_UNKNOWN, REO_DIR_BIDIR, REO_DIR_L2R, REO_DIR_R2L, and REO_MODEL_TYPE_MSLR.

| const std::string MosesTraining::PhraseOrientation::GetOrientationInfoString | ( | int | startF, | |
| int | endF, | |||
| REO_DIR | direction = REO_DIR_BIDIR | |||
| ) | const |
Definition at line 221 of file PhraseOrientation.cpp.
| const std::string MosesTraining::PhraseOrientation::GetOrientationString | ( | const REO_CLASS | orient, | |
| const REO_MODEL_TYPE | modelType = REO_MODEL_TYPE_MSLR | |||
| ) | [static] |
Definition at line 388 of file PhraseOrientation.cpp.
References WriteOrientation().
Referenced by GetOrientationInfoString(), and WritePriorCounts().


| bool MosesTraining::PhraseOrientation::SourceSpanIsAligned | ( | int | index1, | |
| int | index2 | |||
| ) | const |
Definition at line 361 of file PhraseOrientation.cpp.
| bool MosesTraining::PhraseOrientation::TargetSpanIsAligned | ( | int | index1, | |
| int | index2 | |||
| ) | const |
Definition at line 366 of file PhraseOrientation.cpp.
| void MosesTraining::PhraseOrientation::WriteOrientation | ( | std::ostream & | out, | |
| const REO_CLASS | orient, | |||
| const REO_MODEL_TYPE | modelType = REO_MODEL_TYPE_MSLR | |||
| ) | [static] |
Definition at line 396 of file PhraseOrientation.cpp.
References REO_CLASS_DLEFT, REO_CLASS_DRIGHT, REO_CLASS_LEFT, REO_CLASS_RIGHT, REO_CLASS_UNKNOWN, REO_MODEL_TYPE_MONO, REO_MODEL_TYPE_MSD, and REO_MODEL_TYPE_MSLR.
Referenced by GetOrientationString().

| void MosesTraining::PhraseOrientation::WritePriorCounts | ( | std::ostream & | out, | |
| const REO_MODEL_TYPE | modelType = REO_MODEL_TYPE_MSLR | |||
| ) | [static] |
Definition at line 461 of file PhraseOrientation.cpp.
References GetOrientationString(), and REO_CLASS_UNKNOWN.
Referenced by MosesTraining::Syntax::GHKM::ExtractGHKM::Main(), and writePhraseOrientationPriors().


1.5.9