diff options
author | Chris Dyer <cdyer@cs.cmu.edu> | 2012-06-06 15:04:49 -0400 |
---|---|---|
committer | Chris Dyer <cdyer@cs.cmu.edu> | 2012-06-06 15:04:49 -0400 |
commit | dbce625fffe2f052304bb85749809c0fbb2a9132 (patch) | |
tree | 9dec7755f703f0d6735826f24e5f274c639a6b7a /python/src/lattice.pxd | |
parent | 23c7a1ed9f4d2360f8e1183539e3569fdbf60b48 (diff) | |
parent | 34c2c129a376abfc79e76cf2fa1282b89ef605b6 (diff) |
Merge branch 'master' of github.com:redpony/cdec
Diffstat (limited to 'python/src/lattice.pxd')
-rw-r--r-- | python/src/lattice.pxd | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/python/src/lattice.pxd b/python/src/lattice.pxd new file mode 100644 index 00000000..bdfaba80 --- /dev/null +++ b/python/src/lattice.pxd @@ -0,0 +1,16 @@ +from libcpp.vector cimport vector +from utils cimport WordID + +cdef extern from "decoder/lattice.h": + cdef cppclass LatticeArc: + WordID label + double cost + int dist2next + LatticeArc() + LatticeArc(WordID w, double c, int i) + + cdef cppclass Lattice: # (vector[vector[LatticeArc]]) + Lattice() + Lattice(unsigned t) + Lattice(unsigned t, vector[LatticeArc] v) + bint IsSentence() |