Skip to content

Fix warnings #196

@mgeier

Description

@mgeier

I don't know if those are in any way harmful to us, but it's probably good to have a look.

E.g. at https://github.com/sfstoolbox/sfs-python/actions/runs/17990398126/job/51178925090:

/home/runner/work/sfs-python/sfs-python/sfs/fd/esa.py:134: RuntimeWarning: invalid value encountered in divide
  d = d + 1/epsilon[m] * _np.exp(1j*nu*_np.pi/2) * _np.sin(nu*phi_s) \
/home/runner/work/sfs-python/sfs-python/sfs/fd/esa.py:134: RuntimeWarning: divide by zero encountered in divide
  d = d + 1/epsilon[m] * _np.exp(1j*nu*_np.pi/2) * _np.sin(nu*phi_s) \
/home/runner/work/sfs-python/sfs-python/sfs/fd/esa.py:134: RuntimeWarning: invalid value encountered in multiply
  d = d + 1/epsilon[m] * _np.exp(1j*nu*_np.pi/2) * _np.sin(nu*phi_s) \
/home/runner/work/sfs-python/sfs-python/sfs/fd/esa.py:294: RuntimeWarning: invalid value encountered in divide
  f = 1/epsilon[m] * _np.sin(nu*phi_s) * _np.cos(nu*phi) * nu/r
/home/runner/work/sfs-python/sfs-python/sfs/fd/esa.py:294: RuntimeWarning: divide by zero encountered in divide
  f = 1/epsilon[m] * _np.sin(nu*phi_s) * _np.cos(nu*phi) * nu/r
/home/runner/work/sfs-python/sfs-python/sfs/fd/esa.py:295: RuntimeWarning: invalid value encountered in multiply
  d[idx] = d[idx] + f[idx] * _jn(nu, k*r[idx]) * _hankel2(nu, k*r_s)
/home/runner/work/sfs-python/sfs-python/sfs/fd/esa.py:294: RuntimeWarning: invalid value encountered in divide
  f = 1/epsilon[m] * _np.sin(nu*phi_s) * _np.cos(nu*phi) * nu/r
/home/runner/work/sfs-python/sfs-python/sfs/fd/esa.py:294: RuntimeWarning: divide by zero encountered in divide
  f = 1/epsilon[m] * _np.sin(nu*phi_s) * _np.cos(nu*phi) * nu/r
/home/runner/work/sfs-python/sfs-python/sfs/fd/esa.py:295: RuntimeWarning: invalid value encountered in multiply
  d[idx] = d[idx] + f[idx] * _jn(nu, k*r[idx]) * _hankel2(nu, k*r_s)
 /home/runner/work/sfs-python/sfs-python/doc/examples/animations_pulsating_sphere.py:20: DeprecationWarning: __array_wrap__ must accept context and return_scalar arguments (positionally) in the future. (Deprecated NumPy 2.0)
  scat = sfs.plot2d.particles(grid + displacement, **kwargs)
/home/runner/work/sfs-python/sfs-python/doc/examples/animations_pulsating_sphere.py:23: DeprecationWarning: __array_wrap__ must accept context and return_scalar arguments (positionally) in the future. (Deprecated NumPy 2.0)
  position = np.real((grid + displacement * phasor**i))
MovieWriter imagemagick unavailable; using Pillow instead.
/home/runner/work/sfs-python/sfs-python/doc/examples/animations_pulsating_sphere.py:23: DeprecationWarning: __array_wrap__ must accept context and return_scalar arguments (positionally) in the future. (Deprecated NumPy 2.0)
  position = np.real((grid + displacement * phasor**i))
/home/runner/work/sfs-python/sfs-python/doc/examples/animations_pulsating_sphere.py:48: DeprecationWarning: __array_wrap__ must accept context and return_scalar arguments (positionally) in the future. (Deprecated NumPy 2.0)
  np.real(quiv.set_UVC(*(velocity[:2] * phasor**i)))
MovieWriter imagemagick unavailable; using Pillow instead.
/home/runner/work/sfs-python/sfs-python/doc/examples/animations_pulsating_sphere.py:48: DeprecationWarning: __array_wrap__ must accept context and return_scalar arguments (positionally) in the future. (Deprecated NumPy 2.0)
  np.real(quiv.set_UVC(*(velocity[:2] * phasor**i)))

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions