[Spambayes-checkins] spambayes/spambayes classifier.py,1.24,1.25
Tony Meyer
anadelonbrin at users.sourceforge.net
Mon Jul 19 11:59:01 CEST 2004
Update of /cvsroot/spambayes/spambayes/spambayes
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30623/spambayes
Modified Files:
classifier.py
Log Message:
Add some explanation to a couple of asserts. It's possible for users to see these, if
things have gone terribly wrong. (in the X-Spambayes-Exception header).
Index: classifier.py
===================================================================
RCS file: /cvsroot/spambayes/spambayes/spambayes/classifier.py,v
retrieving revision 1.24
retrieving revision 1.25
diff -C2 -d -r1.24 -r1.25
*** classifier.py 14 Jul 2004 07:11:08 -0000 1.24
--- classifier.py 19 Jul 2004 09:58:59 -0000 1.25
***************
*** 306,313 ****
nspam = float(self.nspam or 1)
! assert hamcount <= nham
hamratio = hamcount / nham
! assert spamcount <= nspam
spamratio = spamcount / nspam
--- 306,313 ----
nspam = float(self.nspam or 1)
! assert hamcount <= nham, "Token seen in more ham than ham trained."
hamratio = hamcount / nham
! assert spamcount <= nspam, "Token seen in more spam than spam trained."
spamratio = spamcount / nspam
More information about the Spambayes-checkins
mailing list