From df5b25f73c12ef03482bd902ee0155a56789e6b9 Mon Sep 17 00:00:00 2001 From: Kenneth Heafield Date: Wed, 14 Nov 2012 04:11:03 -0800 Subject: Short-circuit search when generating hypergraphs. --- decoder/decoder.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/decoder/decoder.cc b/decoder/decoder.cc index b5f4b9b6..31e6dc46 100644 --- a/decoder/decoder.cc +++ b/decoder/decoder.cc @@ -832,11 +832,13 @@ bool DecoderImpl::Decode(const string& input, DecoderObserver* o) { abort(); } - if (conf.count("show_target_graph")) + if (conf.count("show_target_graph")) { HypergraphIO::WriteTarget(conf["show_target_graph"].as(), sent_id, forest); - + } if (conf.count("incremental_search")) { incremental->Search(pop_limit, forest); + } + if (conf.count("show_target_graph") || conf.count("incremental_search")) { o->NotifyDecodingComplete(smeta); return true; } -- cgit v1.2.3