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 dataframe index when downloading cleanlab columns #213

Merged
merged 3 commits into from
Apr 9, 2024

Conversation

axl1313
Copy link
Collaborator

@axl1313 axl1313 commented Apr 7, 2024

Description

This PR fixes an issue that could occur when merging cleanlab columns with the original dataset. After sorting cleanlab columns by id column, it was possible for the index of the dataframe to no longer be in sorted order. Adding the ignore_index parameter when sorting the dataframe ensures that the resulting dataframe's index column is of the form 0, 1, ... n-1 so that we can merge with the original dataset using df.merge(cleanlab_columns, left_index=True, right_index=True) properly.

How to test

  • Tabular quickstart tutorial is an example of a tutorial where merging results was broken before this change. Can run this tutorial and check that results are the same as in the Web UI.

@axl1313 axl1313 requested review from sanjanag and ryansingman and removed request for sanjanag April 7, 2024 04:29
@cgnorthcutt cgnorthcutt added bug Something isn't working high-priority labels Apr 9, 2024
Copy link
Member

@ryansingman ryansingman left a comment

Choose a reason for hiding this comment

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

LGTM

@axl1313 axl1313 merged commit a4e1ae4 into main Apr 9, 2024
23 checks passed
@jwmueller jwmueller deleted the fix/cl-cols-index branch April 15, 2024 19:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working high-priority
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants