NaiveBayes.jl
NaiveBayes.jl copied to clipboard
`predict_proba` reports unnormalised probabilities
The probabilities reported by this method (actually the log probabilities) are not normalised. Ie, if you exponentiate the reported probabilities and sum over all classes you do not get one.
It would be nice if this (somewhat unexpected) behaviour were documented somewhere, or if normalised probabilities were reported.
Does it hold for all models or for some specific?
The right way would be to fix it and release a new version, but honestly I'm not sure I'll have time to dive into it anytime soon.
The method is in common.jl, so it applies to all models. So you just need to fix that one method.
There is no urgency from our end. We are doing MLJ model implementations for NaiveBayes and, having noticed the problem, we have accounted for it.