Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/moses-smt/mosesdecoder.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/training/train-model.perl')
-rwxr-xr-xscripts/training/train-model.perl4
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/training/train-model.perl b/scripts/training/train-model.perl
index 9fae8ec8b..b983f32cb 100755
--- a/scripts/training/train-model.perl
+++ b/scripts/training/train-model.perl
@@ -1680,7 +1680,7 @@ sub score_phrase_phrase_extract {
# distinguish between score and consolidation options
my $ONLY_DIRECT = (defined($_SCORE_OPTIONS) && $_SCORE_OPTIONS =~ /OnlyDirect/);
- my $PHRASE_COUNT = (!defined($_SCORE_OPTIONS) || $_SCORE_OPTIONS !~ /NoPhraseCount/);
+ my $PHRASE_COUNT = (defined($_SCORE_OPTIONS) && $_SCORE_OPTIONS =~ /PhraseCount/);
my $LOW_COUNT = (defined($_SCORE_OPTIONS) && $_SCORE_OPTIONS =~ /LowCountFeature/);
my ($SPARSE_COUNT_BIN,$COUNT_BIN,$DOMAIN) = ("","","");
$SPARSE_COUNT_BIN = $1 if defined($_SCORE_OPTIONS) && $_SCORE_OPTIONS =~ /SparseCountBinFeature ([\s\d]*\d)/;
@@ -1814,7 +1814,7 @@ sub score_phrase_phrase_extract {
$cmd .= " --LogProb" if $LOG_PROB;
$cmd .= " --NegLogProb" if $NEG_LOG_PROB;
$cmd .= " --OnlyDirect" if $ONLY_DIRECT;
- $cmd .= " --NoPhraseCount" unless $PHRASE_COUNT;
+ $cmd .= " --PhraseCount" if $PHRASE_COUNT;
$cmd .= " --LowCountFeature" if $LOW_COUNT;
$cmd .= " --CountBinFeature $COUNT_BIN" if $COUNT_BIN;
$cmd .= " --SparseCountBinFeature $SPARSE_COUNT_BIN" if $SPARSE_COUNT_BIN;