diff options
author | Jehan <jehan@mygengo.com> | 2011-11-25 06:31:18 +0400 |
---|---|---|
committer | Jehan <jehan@mygengo.com> | 2011-11-25 06:31:18 +0400 |
commit | 78ccb137fb69f5ed5377ae04d16b9e0e5438e9c9 (patch) | |
tree | 9ed10ff1e7be8714f70b5d1565d26000d836b046 /scripts/recaser | |
parent | 5841aea6aa2a368661148130dda23b8cbf8b13a7 (diff) |
- Coding style fix: use the upstream coding style.
Diffstat (limited to 'scripts/recaser')
-rwxr-xr-x | scripts/recaser/train-recaser.perl | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/scripts/recaser/train-recaser.perl b/scripts/recaser/train-recaser.perl index 82277f8ce..8a2b17ede 100755 --- a/scripts/recaser/train-recaser.perl +++ b/scripts/recaser/train-recaser.perl @@ -51,12 +51,10 @@ sub truecase { sub train_lm { print STDERR "(2) Train language model on cased data @ ".`date`; my $cmd = ""; - if (uc $LM eq "IRSTLM") - { + if (uc $LM eq "IRSTLM") { $cmd = "$BUILD_LM -t /tmp -i $CORPUS -n 3 -o $DIR/cased.irstlm.gz"; } - else - { + else { $LM = "SRILM"; $cmd = "$NGRAM_COUNT -text $CORPUS -lm $DIR/cased.srilm.gz -interpolate -kndiscount"; } @@ -103,12 +101,10 @@ sub train_recase_model { $first = 4 if $first < 4; print STDERR "\n(4) Training recasing model @ ".`date`; my $cmd = "$TRAIN_SCRIPT --root-dir $DIR --model-dir $DIR --first-step $first --alignment a --corpus $DIR/aligned --f lowercased --e cased --max-phrase-length $MAX_LEN"; - if (uc $LM eq "IRSTLM") - { + if (uc $LM eq "IRSTLM") { $cmd .= " --lm 0:3:$DIR/cased.irstlm.gz:1"; } - else - { + else { $cmd .= " --lm 0:3:$DIR/cased.srilm.gz:0"; } $cmd .= " -scripts-root-dir $SCRIPTS_ROOT_DIR" if $SCRIPTS_ROOT_DIR; |