Skip to content

Import scipy.ndimage functions directly (drop removed measurements na… - #3406

Merged
C-Achard merged 1 commit into
DeepLabCut:external/hwang-misc-fixesfrom
Denny-Hwang:fix/scipy-ndimage-measurements
Jul 16, 2026
Merged

Import scipy.ndimage functions directly (drop removed measurements na…#3406
C-Achard merged 1 commit into
DeepLabCut:external/hwang-misc-fixesfrom
Denny-Hwang:fix/scipy-ndimage-measurements

Conversation

@Denny-Hwang

Copy link
Copy Markdown
Contributor

…mespace)

predict_multianimal.py imported 'from scipy.ndimage import measurements'. The scipy.ndimage.measurements submodule was deprecated in scipy 1.8 and removed in scipy 1.14; since the project pins scipy>=1.9 with no upper bound, a fresh install resolves a scipy where this import raises ImportError at module load. Because the module is imported at the top of the TensorFlow multi-animal inference path, analyze_videos on a TF maDLC project failed immediately on import.

Import label and center_of_mass directly from scipy.ndimage (their canonical public location) and call them without the measurements prefix.

…mespace)

predict_multianimal.py imported 'from scipy.ndimage import
measurements'. The scipy.ndimage.measurements submodule was deprecated
in scipy 1.8 and removed in scipy 1.14; since the project pins
scipy>=1.9 with no upper bound, a fresh install resolves a scipy where
this import raises ImportError at module load. Because the module is
imported at the top of the TensorFlow multi-animal inference path,
analyze_videos on a TF maDLC project failed immediately on import.

Import label and center_of_mass directly from scipy.ndimage (their
canonical public location) and call them without the measurements
prefix.
@C-Achard
C-Achard changed the base branch from main to external/hwang-misc-fixes July 16, 2026 07:23
@C-Achard
C-Achard merged commit cffb979 into DeepLabCut:external/hwang-misc-fixes Jul 16, 2026
10 checks passed
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.

4 participants