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

Avoid attempt to fill nan on integer array #1

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

themrzmaster
Copy link

@themrzmaster themrzmaster commented Feb 21, 2021

On https://github.com/ratschlab/bnn_priors/blob/main/bnn_priors/exp_utils.py#L523 it fills the array with NaNs, but it fails when the array type is int (https://stackoverflow.com/questions/12708807/numpy-integer-nan). I propose to always save scalars as floats avoiding this exception.

@fortuin fortuin requested a review from rhaps0dy May 10, 2021 15:25
@fortuin
Copy link
Collaborator

fortuin commented May 10, 2021

Sorry, just seeing this. Looks sensible to me, but let's see what @rhaps0dy says.

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