diff options
author | Patrick Simianer <simianer@cl.uni-heidelberg.de> | 2012-06-13 14:42:07 +0200 |
---|---|---|
committer | Patrick Simianer <simianer@cl.uni-heidelberg.de> | 2012-06-13 14:42:07 +0200 |
commit | e6d3c25191873ca0cf99db8e89702ed91d65277c (patch) | |
tree | b0697ece6f5e4a8229915758c68750793a23f776 /python/src/kbest.pxd | |
parent | 62c805c90c5347b844f92574e240db5c65578e12 (diff) | |
parent | 3acdf1e4b37637d6df86a7b54fb0f1b0464c172b (diff) |
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'python/src/kbest.pxd')
-rw-r--r-- | python/src/kbest.pxd | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/python/src/kbest.pxd b/python/src/kbest.pxd new file mode 100644 index 00000000..e339714a --- /dev/null +++ b/python/src/kbest.pxd @@ -0,0 +1,16 @@ +from libcpp.vector cimport vector +from utils cimport WordID +cimport hypergraph + +cdef extern from "decoder/viterbi.h": + cdef cppclass ESentenceTraversal: + pass + cdef cppclass ETreeTraversal: + pass + +cdef extern from "decoder/kbest.h" namespace "KBest": + cdef cppclass KBestDerivations[T, Traversal]: + cppclass Derivation: + T _yield "yield" + KBestDerivations(hypergraph.Hypergraph hg, unsigned k) + Derivation* LazyKthBest(unsigned v, unsigned k) |