|
From: <jgr...@us...> - 2003-07-09 21:53:22
|
Update of /cvsroot/popfile/engine/Classifier
In directory sc8-pr-cvs1:/tmp/cvs-serv18322/Classifier
Modified Files:
Bayes.pm MailParse.pm
Log Message:
Finally, and totally by chance, discovered the reason why some users sometimes report that a message has the right classification but the wrong XTC or subject modification. Fixed.
Index: Bayes.pm
===================================================================
RCS file: /cvsroot/popfile/engine/Classifier/Bayes.pm,v
retrieving revision 1.162
retrieving revision 1.163
diff -C2 -d -r1.162 -r1.163
*** Bayes.pm 9 Jul 2003 18:18:11 -0000 1.162
--- Bayes.pm 9 Jul 2003 21:53:19 -0000 1.163
***************
*** 690,693 ****
--- 690,695 ----
my $total = 0;
+ $self->log_( "Base score is $base_score for $ranking[0]" );
+
# Compute the total of all the scores to generate the normalized scores and probability
# estimate. $total is always 1 after the first loop iteration, so any additional term
***************
*** 845,849 ****
{
my ( $self, $dcount, $mcount, $ext, $path) = @_;
!
$path = 0 if (!defined($path));
--- 847,851 ----
{
my ( $self, $dcount, $mcount, $ext, $path) = @_;
!
$path = 0 if (!defined($path));
***************
*** 1010,1015 ****
my $temp_file = $self->history_filename($dcount,$mcount, ".msg",1);
! my $nopath_temp_file = $self->history_filename($dcount,$mcount,".msg",0);
!
# Get the class-file info without the path, since we'd just need to strip it
my $class_file = $self->history_filename($dcount,$mcount, ".cls",0);
--- 1012,1017 ----
my $temp_file = $self->history_filename($dcount,$mcount, ".msg",1);
! my $nopath_temp_file = $self->history_filename($dcount,$mcount,".msg",0);
!
# Get the class-file info without the path, since we'd just need to strip it
my $class_file = $self->history_filename($dcount,$mcount, ".cls",0);
Index: MailParse.pm
===================================================================
RCS file: /cvsroot/popfile/engine/Classifier/MailParse.pm,v
retrieving revision 1.142
retrieving revision 1.143
diff -C2 -d -r1.142 -r1.143
*** MailParse.pm 9 Jul 2003 18:18:14 -0000 1.142
--- MailParse.pm 9 Jul 2003 21:53:19 -0000 1.143
***************
*** 1079,1083 ****
# For the Mac we do further splitting of the line at the CR characters
! while ( $read =~ s/(.*?[\r\n]+)// ) {
my $line = $1;
--- 1079,1083 ----
# For the Mac we do further splitting of the line at the CR characters
! while ( $read =~ s/(.*?)[\r\n]+// ) {
my $line = $1;
|