[Spambayes-checkins] spambayes/Outlook2000 manager.py, 1.109, 1.110 train.py, 1.41, 1.42
Mark Hammond
mhammond at users.sourceforge.net
Tue Feb 6 02:16:31 CET 2007
Update of /cvsroot/spambayes/spambayes/Outlook2000
In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv7212
Modified Files:
manager.py train.py
Log Message:
New persistent-stats code failed on a full retrain with bizarre errors
relating to an invalid messageinfo_db. I'm not 100% confident this
will correctly carry stats over after a retrain - but I'm not even sure
what the desired semantics are, and this works better than it did!
Index: manager.py
===================================================================
RCS file: /cvsroot/spambayes/spambayes/Outlook2000/manager.py,v
retrieving revision 1.109
retrieving revision 1.110
diff -C2 -d -r1.109 -r1.110
*** manager.py 22 Apr 2005 06:18:09 -0000 1.109
--- manager.py 6 Feb 2007 01:16:29 -0000 1.110
***************
*** 470,473 ****
--- 470,477 ----
self.classifier_data.message_db)
+ def AdoptClassifierData(self, new_classifier_data):
+ self.classifier_data.Adopt(new_classifier_data)
+ self.stats.messageinfo_db = self.classifier_data.message_db
+
# Logging - this should be somewhere else.
def LogDebug(self, level, *args):
Index: train.py
===================================================================
RCS file: /cvsroot/spambayes/spambayes/Outlook2000/train.py,v
retrieving revision 1.41
retrieving revision 1.42
diff -C2 -d -r1.41 -r1.42
*** train.py 21 Dec 2004 21:48:38 -0000 1.41
--- train.py 6 Feb 2007 01:16:29 -0000 1.42
***************
*** 168,172 ****
if rebuild:
assert mgr.classifier_data is not classifier_data
! mgr.classifier_data.Adopt(classifier_data)
classifier_data = mgr.classifier_data
# If we are rebuilding, then we reset the statistics, too.
--- 168,172 ----
if rebuild:
assert mgr.classifier_data is not classifier_data
! mgr.AdoptClassifierData(classifier_data)
classifier_data = mgr.classifier_data
# If we are rebuilding, then we reset the statistics, too.
More information about the Spambayes-checkins
mailing list