Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/moses-smt/mosesdecoder.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHieu Hoang <hieuhoang@gmail.com>2015-11-03 23:56:37 +0300
committerHieu Hoang <hieuhoang@gmail.com>2015-11-03 23:56:37 +0300
commitb5d914134accaf5cdf39a94f61c581545e5803f6 (patch)
tree3b43f84243bac7e9cc86b7cf19736e14c28db265 /moses/Hypothesis.cpp
parentc5c08993dec4dcc14e418136fa04d1a2ca08ccad (diff)
move beats() out of #ifdef region
Diffstat (limited to 'moses/Hypothesis.cpp')
-rw-r--r--moses/Hypothesis.cpp33
1 files changed, 16 insertions, 17 deletions
diff --git a/moses/Hypothesis.cpp b/moses/Hypothesis.cpp
index 4c8598638..c26889275 100644
--- a/moses/Hypothesis.cpp
+++ b/moses/Hypothesis.cpp
@@ -600,6 +600,22 @@ bool Hypothesis::operator==(const Hypothesis& other) const
return true;
}
+bool
+Hypothesis::
+beats(Hypothesis const& b) const
+{
+ if (m_totalScore != b.m_totalScore)
+ return m_totalScore > b.m_totalScore;
+ else if (m_futureScore != b.m_futureScore)
+ return m_futureScore > b.m_futureScore;
+ else if (m_prevHypo)
+ return b.m_prevHypo ? m_prevHypo->beats(*b.m_prevHypo) : true;
+ else return false;
+ // TO DO: add more tie breaking here
+ // results. We should compare other property of the hypos here.
+ // On the other hand, how likely is this going to happen?
+}
+
#ifdef HAVE_XMLRPC_C
void
Hypothesis::
@@ -632,23 +648,6 @@ OutputWordAlignment(vector<xmlrpc_c::value>& out) const
tmp[i]->OutputLocalWordAlignment(out);
}
-bool
-Hypothesis::
-beats(Hypothesis const& b) const
-{
- if (m_totalScore != b.m_totalScore)
- return m_totalScore > b.m_totalScore;
- else if (m_futureScore != b.m_futureScore)
- return m_futureScore > b.m_futureScore;
- else if (m_prevHypo)
- return b.m_prevHypo ? m_prevHypo->beats(*b.m_prevHypo) : true;
- else return false;
- // TO DO: add more tie breaking here
- // results. We should compare other property of the hypos here.
- // On the other hand, how likely is this going to happen?
-}
-
-
#endif