summaryrefslogtreecommitdiff
path: root/phrase2_extraction
diff options
context:
space:
mode:
authorPatrick Simianer <p@simianer.de>2015-12-11 16:42:43 +0100
committerPatrick Simianer <p@simianer.de>2015-12-11 16:42:43 +0100
commit7c179958222b95939ff1881a49126e08a38d489e (patch)
treedca972884c712386700259c3aaf10530e2da8509 /phrase2_extraction
parenta2e9792da9188882ae321efd075d3bb8a5783e40 (diff)
minor js cleanup
Diffstat (limited to 'phrase2_extraction')
-rwxr-xr-xphrase2_extraction/phrase2_extraction.rb8
1 files changed, 5 insertions, 3 deletions
diff --git a/phrase2_extraction/phrase2_extraction.rb b/phrase2_extraction/phrase2_extraction.rb
index 6dd044e..8f09a8b 100755
--- a/phrase2_extraction/phrase2_extraction.rb
+++ b/phrase2_extraction/phrase2_extraction.rb
@@ -274,8 +274,10 @@ class Rule
correct_src = r.len_src-new_rule.len_src
correct_tgt = r.len_tgt-new_rule.len_tgt
- STDERR.write "correct_src #{correct_src}\n"
- STDERR.write "correct_tgt #{correct_tgt}\n"
+ if DEBUG
+ STDERR.write "correct_src #{correct_src}\n"
+ STDERR.write "correct_tgt #{correct_tgt}\n"
+ end
start_correct_source = nil
j = 0
@@ -285,7 +287,7 @@ class Rule
fl << new_rule.source_context[i]
else
if i.match(/\[NEWX,\d+\]/)
- STDERR.write "j = #{j}\n"
+ STDERR.write "j = #{j}\n" if DEBUG
start_correct_source = j
end
fl << i