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

DATA: update sum check #874

Merged
merged 1 commit into from
Jul 24, 2019
Merged

DATA: update sum check #874

merged 1 commit into from
Jul 24, 2019

Conversation

yueguoguo
Copy link
Collaborator

Description

sum of floating numbers is approximate and there is loss of precision. This causes issues in the "ratio sum to 1" check in the Python random splitter.

Using math.fsum to resolve the issue.

Related Issues

#866

Checklist:

  • I have followed the contribution guidelines and code style for this project.
  • I have added tests covering my contributions.
  • I have updated the documentation accordingly.

Copy link
Collaborator

@miguelgfierro miguelgfierro left a comment

Choose a reason for hiding this comment

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

LGTM

@miguelgfierro
Copy link
Collaborator

there is a spark test that timed out. Do you know why?

@yueguoguo
Copy link
Collaborator Author

yueguoguo commented Jul 24, 2019

@miguelgfierro no idea... Re-run the test was successful Ah no I think the problem is from the build agent.

@miguelgfierro miguelgfierro merged commit 199170c into staging Jul 24, 2019
@miguelgfierro miguelgfierro deleted the le_python_split_fix branch July 24, 2019 08:12
yueguoguo pushed a commit that referenced this pull request Sep 9, 2019
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