-
Notifications
You must be signed in to change notification settings - Fork 532
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Categorical Naive Bayes #4150
Add Categorical Naive Bayes #4150
Conversation
@lowener can you include the steps taken for the timings in your benchmark chart? I'm mostly interested in whether these timings are only for training or if they also include the likelihoods. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Your implementaiton looks great overall. This algorithm is immensely popular on sparse inputs / bigraphs, though, so we should strive to support sparse inputs and, as a result, assume a significantly large upper-bound on the number of features.
I added support for sparse inputs and removed the loops over For the benchmark previously posted I was only timing the CategoricalNB().fit(X, Y).predict(X) And we can see that the removal of the loop over |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The changes look really good and the benchmarks are super impressive. Just one little cleanup opportunity remains.
Codecov Report
@@ Coverage Diff @@
## branch-21.10 #4150 +/- ##
===============================================
Coverage ? 86.07%
===============================================
Files ? 231
Lines ? 18637
Branches ? 0
===============================================
Hits ? 16042
Misses ? 2595
Partials ? 0
Flags with carried forward coverage won't be shown. Click here to find out more. Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@gpucibot merge |
This is a continuation of PR rapidsai#1763, rapidsai#4053, and rapidsai#4079, to add Categorical Naive Bayes. This is supposed to be merged after rapidsai#4079. Linking issue rapidsai#1666. Authors: - Micka (https://github.com/lowener) Approvers: - Corey J. Nolet (https://github.com/cjnolet) URL: rapidsai#4150
This is a continuation of PR #1763, #4053, and #4079, to add Categorical Naive Bayes.
This is supposed to be merged after #4079.
Linking issue #1666.