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

Python Package Issue: Error with Affinity Matrix Containing NaN or Inf Values #115

Open
y0ungeunii opened this issue Feb 23, 2024 · 1 comment

Comments

@y0ungeunii
Copy link

I attempted to generate gradients using mpc_dm() and plot them onto the brain mask using plot_hemispheres(). However, I encountered an error message: ValueError: Affinity matrix contains NaN or Inf values. Common causes of this include NaNs/Infs or rows of zeros in the input matrix.

I tried running the same code on another workstation, and it worked without any issues. The only difference between the workstations was the version of some Python packages, such as pandas and nibabel. For instance, on the workstation with pandas version 1.4.4, nibabel version 4.0.2, and seaborn version 0.11.2, the code worked fine. However, on the workstation with pandas version 2.0.3, nibabel version 5.1.0, and seaborn version 0.13.0, the code didn't work, despite having higher versions of Python packages.

According to your website, there were no specific requirements mentioned for �those Python packages. So, do we need specific requirements for those Python packages? Also, I'm curious about the cause of the error. Thank you!

@nimzodisaster
Copy link

I am getting this too.

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

No branches or pull requests

2 participants