summaryrefslogtreecommitdiff
path: root/gi/pf/pyp_tm.h
diff options
context:
space:
mode:
authorChris Dyer <cdyer@cs.cmu.edu>2012-03-10 16:42:12 -0500
committerChris Dyer <cdyer@cs.cmu.edu>2012-03-10 16:42:12 -0500
commitdfbc278c1057555fda9312291c8024049e00b7d8 (patch)
treee922651d48b1c9f73857f0dabd31c55a3ce8a74b /gi/pf/pyp_tm.h
parent289f96779e665ba24adca3461a624c68aa37bd99 (diff)
frequency-based binning
Diffstat (limited to 'gi/pf/pyp_tm.h')
-rw-r--r--gi/pf/pyp_tm.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/gi/pf/pyp_tm.h b/gi/pf/pyp_tm.h
index fa0fb28f..63e7c96d 100644
--- a/gi/pf/pyp_tm.h
+++ b/gi/pf/pyp_tm.h
@@ -5,10 +5,11 @@
#include "wordid.h"
#include "prob.h"
#include "sampler.h"
+#include "freqdict.h"
-struct TRule;
+struct FreqBinner;
struct PYPWordModel;
-template <typename T> struct ConditionalPYPWordModel;
+template <typename T, class B> struct ConditionalPYPWordModel;
struct PYPLexicalTranslation {
explicit PYPLexicalTranslation(const std::vector<std::vector<WordID> >& lets,
@@ -26,7 +27,7 @@ struct PYPLexicalTranslation {
private:
const std::vector<std::vector<WordID> >& letters; // spelling dictionary
PYPWordModel* up0; // base distribuction (model English word)
- ConditionalPYPWordModel<PYPWordModel>* tmodel; // translation distributions
+ ConditionalPYPWordModel<PYPWordModel, FreqBinner>* tmodel; // translation distributions
// (model English word | French word)
const WordID kX;
};