Thanks to visit codestin.com
Credit goes to github.com

Skip to content

DOC Add abstract methods to _BaseDiscreteNB #22596

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

Merged
merged 26 commits into from
Feb 28, 2022

Conversation

avm19
Copy link
Contributor

@avm19 avm19 commented Feb 24, 2022

Reference Issues/PRs

PR #22565 has been split in two. This is the second part.

What does this implement/fix? Explain your changes.

Abstract methods _count and _update_feature_log_prob are added to the abstract class _BaseDiscreteNB, along with a minimal description of what these methods should do. I believe this addition will facilitate understanding and maintenance of the code. Currently, the abstract methods aren't mentioned anywhere in plain English, but they are called, and their effects are expected by concrete methods of the same class.

Any other comments?

Edits by maintainers are allowed.

@avm19 avm19 changed the title Naive bayes abstract 2 Add abstract methods to _BaseDiscreteNB Feb 24, 2022
@avm19 avm19 marked this pull request as ready for review February 24, 2022 01:47
Copy link
Member

@jeremiedbb jeremiedbb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @avm19. Here are a few comments.

avm19 and others added 6 commits February 24, 2022 15:25
jeremiedbb's corrections

Co-authored-by: Jérémie du Boisberranger <[email protected]>
jeremiedbb's corrections

Co-authored-by: Jérémie du Boisberranger <[email protected]>
jeremiedbb's corrections

Co-authored-by: Jérémie du Boisberranger <[email protected]>
jeremiedbb's corrections

Co-authored-by: Jérémie du Boisberranger <[email protected]>
jeremiedbb's corrections

Co-authored-by: Jérémie du Boisberranger <[email protected]>
Copy link
Member

@thomasjpfan thomasjpfan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR!

Copy link
Member

@thomasjpfan thomasjpfan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor comments, otherwise LGTM

@thomasjpfan thomasjpfan changed the title Add abstract methods to _BaseDiscreteNB DOC Add abstract methods to _BaseDiscreteNB Feb 25, 2022
@avm19 avm19 requested a review from jeremiedbb February 27, 2022 01:53
Copy link
Member

@jeremiedbb jeremiedbb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks @avm19

@jeremiedbb jeremiedbb merged commit 1c94c0b into scikit-learn:main Feb 28, 2022
thomasjpfan added a commit to thomasjpfan/scikit-learn that referenced this pull request Mar 1, 2022
Co-authored-by: avm19 <[email protected]>
Co-authored-by: Thomas J. Fan <[email protected]>
Co-authored-by: Jérémie du Boisberranger <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants