Skip to content
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

Fix unbound knn variable in NonIIDIssueManager #709

Merged
merged 2 commits into from
May 11, 2023

Conversation

elisno
Copy link
Member

@elisno elisno commented May 11, 2023

This PR really just fixed one bug where the knn object isn't set within the NonIIDIssuemanager if a knn_graph is already accessible.

It's a simple as just initializing the parameter to None. That's already the expected type for knn when just the knn_graph is used.

Along with this change, I've added some end-to-end tests in Datalab that ensure the summary is updated appropriately with incremental search.
That's how the knn bug was discovered in the first place, because the IssueManagers would otherwise fail silently when calling Datalab.find_issues.

elisno added 2 commits May 11, 2023 00:01
Otherwise, it won't be defined if a pre-existing knn graph is found during the non-iid issue check.
@elisno elisno changed the title Fix unbound knn Fix unbound knn variable in NonIIDIssueManager May 11, 2023
@elisno elisno requested review from huiwengoh and jwmueller May 11, 2023 04:20
@codecov
Copy link

codecov bot commented May 11, 2023

Codecov Report

Merging #709 (7a244ab) into master (6ff06c8) will increase coverage by 0.08%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master     #709      +/-   ##
==========================================
+ Coverage   95.77%   95.86%   +0.08%     
==========================================
  Files          46       46              
  Lines        3648     3649       +1     
  Branches      651      651              
==========================================
+ Hits         3494     3498       +4     
  Misses         79       79              
+ Partials       75       72       -3     
Impacted Files Coverage Δ
cleanlab/datalab/issue_manager/noniid.py 96.40% <100.00%> (+5.44%) ⬆️

... and 1 file with indirect coverage changes

Copy link
Member

@jwmueller jwmueller left a comment

Choose a reason for hiding this comment

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

Good catch!

@jwmueller jwmueller merged commit 7400051 into cleanlab:master May 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants