summaryrefslogtreecommitdiff
path: root/decoder/apply_models.h
diff options
context:
space:
mode:
authorChris Dyer <cdyer@cs.cmu.edu>2011-02-10 18:45:13 -0500
committerChris Dyer <cdyer@cs.cmu.edu>2011-02-10 18:45:13 -0500
commit93618c0fcce1544bf948172d04e764f53073cf8a (patch)
tree50e37483ad7e024e77e34e8474ff8d9aafd95a8c /decoder/apply_models.h
parentb81db79949959b77431dda892162989b95bd1e97 (diff)
multipass decoding
Diffstat (limited to 'decoder/apply_models.h')
-rw-r--r--decoder/apply_models.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/decoder/apply_models.h b/decoder/apply_models.h
index 81fa068e..a85694aa 100644
--- a/decoder/apply_models.h
+++ b/decoder/apply_models.h
@@ -1,6 +1,8 @@
#ifndef _APPLY_MODELS_H_
#define _APPLY_MODELS_H_
+#include <iostream>
+
struct ModelSet;
struct Hypergraph;
struct SentenceMetadata;
@@ -20,6 +22,14 @@ enum {
IntersectionConfiguration(exhaustive_t /* t */) : algorithm(0), pop_limit() {}
};
+inline std::ostream& operator<<(std::ostream& os, const IntersectionConfiguration& c) {
+ if (c.algorithm == 0) { os << "FULL"; }
+ else if (c.algorithm == 1) { os << "CUBE:k=" << c.pop_limit; }
+ else if (c.algorithm == 2) { os << "N_ALGORITHMS"; }
+ else os << "OTHER";
+ return os;
+}
+
void ApplyModelSet(const Hypergraph& in,
const SentenceMetadata& smeta,
const ModelSet& models,