scipy: BUG: scipy 1.10.0 crashes when using a large float in skellam distr on apple silicon

Describe your issue.

Scipy 1.10.0 is crashing my script if I use a large float as a parameter for the skellam distribution on apple silicon.

Reproducing Code Example

from scipy.stats import skellam

skellam.pmf(0, 1.0, 4820232647677555.0)
# or skellam.cdf(0, 1.0, 4820232647677555.0)

Error message

libc++abi: terminating with uncaught exception of type boost::wrapexcept<boost::math::rounding_error>: Error in function boost::math::itrunc<double>(double): Value 4820232647677555 can not be represented in the target integer type.
zsh: abort      /usr/bin/python3 /Users/japoco/Programming/model/test.py

SciPy/NumPy/Python version information

blas_mkl_info: NOT AVAILABLE blis_info: NOT AVAILABLE openblas_info: libraries = ['openblas', 'openblas'] library_dirs = ['/opt/arm64-builds/lib'] language = c define_macros = [('HAVE_CBLAS', None)] runtime_library_dirs = ['/opt/arm64-builds/lib'] blas_opt_info: libraries = ['openblas', 'openblas'] library_dirs = ['/opt/arm64-builds/lib'] language = c define_macros = [('HAVE_CBLAS', None)] runtime_library_dirs = ['/opt/arm64-builds/lib'] lapack_mkl_info: NOT AVAILABLE openblas_lapack_info: libraries = ['openblas', 'openblas'] library_dirs = ['/opt/arm64-builds/lib'] language = c define_macros = [('HAVE_CBLAS', None)] runtime_library_dirs = ['/opt/arm64-builds/lib'] lapack_opt_info: libraries = ['openblas', 'openblas'] library_dirs = ['/opt/arm64-builds/lib'] language = c define_macros = [('HAVE_CBLAS', None)] runtime_library_dirs = ['/opt/arm64-builds/lib']

About this issue

  • Original URL
  • State: closed
  • Created a year ago
  • Comments: 26 (15 by maintainers)

Commits related to this issue

Most upvoted comments

I was using Pingouin to do statistical tests, but in one case a pair of samples had almost zero variance, such that the effect size was some huge number. I’ll also file an issue with them to maybe check whether the variance is too low when calculating effect size.