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

RuntimeWarning: invalid value encountered in divide #1426

Open
clee162 opened this issue Nov 20, 2024 · 1 comment
Open

RuntimeWarning: invalid value encountered in divide #1426

clee162 opened this issue Nov 20, 2024 · 1 comment

Comments

@clee162
Copy link

clee162 commented Nov 20, 2024

  1. Operating System (Linux, MacOS, Windows): Linux
  2. Hardware type (x86, ARM..) and RAM: x86, 376 GB RAM
  3. Python Version (e.g. 3.9): 3.10.15
  4. Caiman version (e.g. 1.9.12): 1.11.3
    How you installed Caiman (pure conda, conda + compile, colab, ..): conda
  5. Details:

During the CNMF fitting step, the following warnings are printed. Everything continues to run and the results appear to be normal. I am using Scipy version 1.14.1, could this be a version compatibility issue? Thank you for your help!

/usr/local/bin/anaconda3/envs/caiman-1-11-3/lib/python3.10/site-packages/caiman/base/rois.py:60: RuntimeWarning: invalid value encountered in divide
cm = (coor @ A / A.sum(axis=0)).T
/usr/local/bin/anaconda3/envs/caiman-1-11-3/lib/python3.10/site-packages/scipy/ndimage/_measurements.py:1541: RuntimeWarning: invalid value encountered in scalar divide
results = [sum(input * grids[dir].astype(float), labels, index) / normalizer
/usr/local/bin/anaconda3/envs/caiman-1-11-3/lib/python3.10/site-packages/caiman/base/rois.py:60: RuntimeWarning: invalid value encountered in divide
cm = (coor @ A / A.sum(axis=0)).T
/usr/local/bin/anaconda3/envs/caiman-1-11-3/lib/python3.10/site-packages/scipy/ndimage/_measurements.py:1541: RuntimeWarning: invalid value encountered in scalar divide
results = [sum(input * grids[dir].astype(float), labels, index) / normalizer
/usr/local/bin/anaconda3/envs/caiman-1-11-3/lib/python3.10/site-packages/caiman/base/rois.py:60: RuntimeWarning: invalid value encountered in divide
cm = (coor @ A / A.sum(axis=0)).T
/usr/local/bin/anaconda3/envs/caiman-1-11-3/lib/python3.10/site-packages/scipy/ndimage/_measurements.py:1541: RuntimeWarning: invalid value encountered in scalar divide
results = [sum(input * grids[dir].astype(float), labels, index) / normalizer
/usr/local/bin/anaconda3/envs/caiman-1-11-3/lib/python3.10/site-packages/caiman/base/rois.py:60: RuntimeWarning: invalid value encountered in divide
cm = (coor @ A / A.sum(axis=0)).T
/usr/local/bin/anaconda3/envs/caiman-1-11-3/lib/python3.10/site-packages/scipy/ndimage/_measurements.py:1541: RuntimeWarning: invalid value encountered in scalar divide
results = [sum(input * grids[dir].astype(float), labels, index) / normalizer

@kushalkolar
Copy link
Collaborator

that means there's a nan or infinity somewhere in that division, if your results look fine it's probably fine, you can usually ignore warnings.

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