summaryrefslogtreecommitdiff
path: root/klm/search/config.hh
diff options
context:
space:
mode:
authorAvneesh Saluja <asaluja@gmail.com>2013-03-28 18:28:16 -0700
committerAvneesh Saluja <asaluja@gmail.com>2013-03-28 18:28:16 -0700
commit3d8d656fa7911524e0e6885647173474524e0784 (patch)
tree81b1ee2fcb67980376d03f0aa48e42e53abff222 /klm/search/config.hh
parentbe7f57fdd484e063775d7abf083b9fa4c403b610 (diff)
parent96fedabebafe7a38a6d5928be8fff767e411d705 (diff)
fixed conflicts
Diffstat (limited to 'klm/search/config.hh')
-rw-r--r--klm/search/config.hh38
1 files changed, 38 insertions, 0 deletions
diff --git a/klm/search/config.hh b/klm/search/config.hh
new file mode 100644
index 00000000..ba18c09e
--- /dev/null
+++ b/klm/search/config.hh
@@ -0,0 +1,38 @@
+#ifndef SEARCH_CONFIG__
+#define SEARCH_CONFIG__
+
+#include "search/types.hh"
+
+namespace search {
+
+struct NBestConfig {
+ explicit NBestConfig(unsigned int in_size) {
+ keep = in_size;
+ size = in_size;
+ }
+
+ unsigned int keep, size;
+};
+
+class Config {
+ public:
+ Config(Score lm_weight, unsigned int pop_limit, const NBestConfig &nbest) :
+ lm_weight_(lm_weight), pop_limit_(pop_limit), nbest_(nbest) {}
+
+ Score LMWeight() const { return lm_weight_; }
+
+ unsigned int PopLimit() const { return pop_limit_; }
+
+ const NBestConfig &GetNBest() const { return nbest_; }
+
+ private:
+ Score lm_weight_;
+
+ unsigned int pop_limit_;
+
+ NBestConfig nbest_;
+};
+
+} // namespace search
+
+#endif // SEARCH_CONFIG__