RE: [Spambayes] big imapfilter.py problem
What's a message database, and where do I find it? OK, I presume spambayes.messageinfo.db is it.
Sorry, yes. I've also confirmed with Tim that this is the cause.
Okay, training worked, but: File "./spambayes/classifier.py", line 301, in probability assert hamcount <= nham AssertionError % What's the problem now?
Hmm - interesting. This is the same problem as Olly was having. This means that the ham/spam count in the spambayes database (hammie.db, probably) is incorrect. My message to him had the two solutions. It's pushing the realms of coincidence a little to say that this has nothing to do with imapfilter. I'll try and see what's causing the count to go wrong.
File "imapfilter.py", line 372, in __cmp__ return cmp(self.name, obj.name) AttributeError: 'str' object has no attribute 'name'%
I should be able to find this easily enough. Odd that it's not always coming up.
File "./spambayes/classifier.py", line 408, in _remove_msg raise ValueError("spam count would go negative!") ValueError: spam count would go negative!
I suspect this is related to the first one. If I had to guess without looking at the code, I'd say that the untraining code is being activated when it shouldn't be. This would cause this one and the ham/spam count to be out.
different-every-time-ly y'rs.
And just when I thought maybe things were going right... =Tony Meyer
"Meyer, Tony" <T.A.Meyer@massey.ac.nz> writes:
I suspect this is related to the first one. If I had to guess without looking at the code, I'd say that the untraining code is being activated when it shouldn't be. This would cause this one and the ham/spam count to be out.
different-every-time-ly y'rs.
And just when I thought maybe things were going right...
OK, now everything worked, sort of: %setenv PYTHONPATH ~/src/email-2.5 %python imapfilter.py -t -c -v Loading database hammie.db... Loading state from hammie.db database hammie.db is a new database Done. Training Training ham folder HamBox 0 trained. Training spam folder SpamBox 0 trained. Training took 51.954687953 seconds, 0 messages were trained Classifying Filtering took 1.34056997299 seconds. But no messages got classified spam or unsure, AFAICT. Even after I move some of the spam training messages into my inbox, they're not classified as spam. -- Dave Abrahams Boost Consulting www.boost-consulting.com
participants (2)
-
David Abrahams -
Meyer, Tony