diff options
author | redpony <redpony@ec762483-ff6d-05da-a07a-a48fb63a330f> | 2010-11-15 20:22:22 +0000 |
---|---|---|
committer | redpony <redpony@ec762483-ff6d-05da-a07a-a48fb63a330f> | 2010-11-15 20:22:22 +0000 |
commit | c8c315a4f78c464636ea5e3fd9a11416b2f966b9 (patch) | |
tree | 763f25d7db1c5b9add1c33d20f8d290c046ff406 /rescore | |
parent | c0afd1924cf0c228a85352b3584c64a5e00b88c7 (diff) |
rescoring working
git-svn-id: https://ws10smt.googlecode.com/svn/trunk@726 ec762483-ff6d-05da-a07a-a48fb63a330f
Diffstat (limited to 'rescore')
-rwxr-xr-x | rescore/rescore_with_cdec_model.pl | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/rescore/rescore_with_cdec_model.pl b/rescore/rescore_with_cdec_model.pl index 6553fe56..cdd8c217 100755 --- a/rescore/rescore_with_cdec_model.pl +++ b/rescore/rescore_with_cdec_model.pl @@ -46,7 +46,7 @@ if (defined $weights_file) { die "Can't read $weights_file" unless -f $weights_file; $weights = "-w $weights_file"; } -my $decoder_command = "$decoder -c $cdec_ini --quiet $weights --show_partition_as_translation"; +my $decoder_command = "$decoder -c $cdec_ini --quiet $weights --show_conditional_prob"; print STDERR "DECODER COMMAND: $decoder_command\n"; my $cdec_pid = open2(\*CDEC_IN, \*CDEC_OUT, $decoder_command) or die "Couldn't run $decoder: $!"; @@ -108,8 +108,7 @@ sub rescore { my $score = <CDEC_IN>; chomp $score; my @words = split /\s+/, $hyps[$i]; - my $norm_score = $score / scalar @words; - print "$id ||| $hyps[$i] ||| $feats[$i] $feature_name=$score ${feature_name}_norm=$norm_score\n"; + print "$id ||| $hyps[$i] ||| $feats[$i] $feature_name=$score\n"; } } |