diff options
author | Chris Dyer <redpony@gmail.com> | 2009-12-07 16:53:07 -0500 |
---|---|---|
committer | Chris Dyer <redpony@gmail.com> | 2009-12-07 16:53:07 -0500 |
commit | 289bff46b5695c89786ae5dc823479af9d9e7272 (patch) | |
tree | ad2b59b7e3e4e9c6362d5c5b71c6ec6d4fdf2368 /src | |
parent | 476d09e1df52cba0be8e5f50d52bf5f32795288f (diff) |
add compound splitter
Diffstat (limited to 'src')
-rw-r--r-- | src/cdec.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/cdec.cc b/src/cdec.cc index f9634a7d..6185c79b 100644 --- a/src/cdec.cc +++ b/src/cdec.cc @@ -179,7 +179,8 @@ void DumpKBest(const int sent_id, const Hypergraph& forest, const int k, const b const KBest::KBestDerivations<vector<WordID>, ESentenceTraversal, KBest::FilterUnique>::Derivation* d = kbest.LazyKthBest(forest.nodes_.size() - 1, i); if (!d) break; - cout << sent_id << " ||| " << TD::GetString(d->yield) << " ||| " << d->feature_values << endl; + cout << sent_id << " ||| " << TD::GetString(d->yield) << " ||| " + << d->feature_values << " ||| " << log(d->score) << endl; } } else { KBest::KBestDerivations<vector<WordID>, ESentenceTraversal> kbest(forest, k); @@ -187,7 +188,8 @@ void DumpKBest(const int sent_id, const Hypergraph& forest, const int k, const b const KBest::KBestDerivations<vector<WordID>, ESentenceTraversal>::Derivation* d = kbest.LazyKthBest(forest.nodes_.size() - 1, i); if (!d) break; - cout << sent_id << " ||| " << TD::GetString(d->yield) << " ||| " << d->feature_values << endl; + cout << sent_id << " ||| " << TD::GetString(d->yield) << " ||| " + << d->feature_values << " ||| " << log(d->score) << endl; } } } |