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

Explicitly set posinf and neginf in nan_to_num so they stay infinite. #173

Merged

Conversation

jpivarski
Copy link
Member

If you don't set posinf and neginf in np.nan_to_num, infinite (non-NaN) values get replaced by extreme finite values, and that wasn't my intention. I only wanted to set the NaN values with the nan argument.

@Saransh-cpp
Copy link
Member

I think this is ready for merging now, @jpivarski.

@jpivarski
Copy link
Member Author

Great, thanks!

@jpivarski jpivarski merged commit da67139 into main Jul 6, 2022
@jpivarski jpivarski deleted the jpivarski/explicitly-set-posinf-neginf-in-nan_to_num branch July 6, 2022 17:16
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