diff options
author | Chris Dyer <cdyer@cs.cmu.edu> | 2012-02-19 04:27:55 -0500 |
---|---|---|
committer | Chris Dyer <cdyer@cs.cmu.edu> | 2012-02-19 04:27:55 -0500 |
commit | c4ffa6df1fdd89e3db9c6d3829b7b84edac20bcf (patch) | |
tree | 695176a31796d634e81db3274859bad98d58b4c1 /decoder/lattice.cc | |
parent | 0498227db2f45bcf7ac44809106846866a6f85e1 (diff) |
lbl preliminary clean up
Diffstat (limited to 'decoder/lattice.cc')
-rw-r--r-- | decoder/lattice.cc | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/decoder/lattice.cc b/decoder/lattice.cc index e3631e59..89da3cd0 100644 --- a/decoder/lattice.cc +++ b/decoder/lattice.cc @@ -46,6 +46,7 @@ void LatticeTools::ConvertTextToLattice(const string& text, Lattice* pl) { Lattice& l = *pl; vector<WordID> ids; TD::ConvertSentence(text, &ids); + l.clear(); l.resize(ids.size()); for (int i = 0; i < l.size(); ++i) l[i].push_back(LatticeArc(ids[i], 0.0, 1)); |