21
21
from ._comb import _comb_int
22
22
from ._multiufuncs import (assoc_legendre_p_all ,
23
23
legendre_p_all )
24
+ from scipy ._lib .deprecation import _deprecated
24
25
25
26
26
27
__all__ = [
87
88
]
88
89
89
90
91
+ __DEPRECATION_MSG_1_15 = (
92
+ "`scipy.special.{}` is deprecated as of SciPy 1.15.0 and will be "
93
+ "removed in SciPy 1.17.0. Please use `scipy.special.{}` instead."
94
+ )
95
+
90
96
# mapping k to last n such that factorialk(n, k) < np.iinfo(np.int64).max
91
97
_FACTORIALK_LIMITS_64BITS = {1 : 20 , 2 : 33 , 3 : 44 , 4 : 54 , 5 : 65 ,
92
98
6 : 74 , 7 : 84 , 8 : 93 , 9 : 101 }
@@ -1703,6 +1709,7 @@ def mathieu_odd_coef(m, q):
1703
1709
return fc [:km ]
1704
1710
1705
1711
1712
+ @_deprecated (__DEPRECATION_MSG_1_15 .format ("lpmn" , "assoc_legendre_p_all" ))
1706
1713
def lpmn (m , n , z ):
1707
1714
"""Sequence of associated Legendre functions of the first kind.
1708
1715
@@ -1715,8 +1722,8 @@ def lpmn(m, n, z):
1715
1722
use clpmn instead.
1716
1723
1717
1724
.. deprecated:: 1.15.0
1718
- This function is deprecated and will be removed in a future version .
1719
- Use `scipy.special.assoc_legendre_p_all` instead.
1725
+ This function is deprecated and will be removed in SciPy 1.17.0 .
1726
+ Please `scipy.special.assoc_legendre_p_all` instead.
1720
1727
1721
1728
Parameters
1722
1729
----------
@@ -1782,6 +1789,7 @@ def lpmn(m, n, z):
1782
1789
return p , pd
1783
1790
1784
1791
1792
+ @_deprecated (__DEPRECATION_MSG_1_15 .format ("clpmn" , "assoc_legendre_p_all" ))
1785
1793
def clpmn (m , n , z , type = 3 ):
1786
1794
"""Associated Legendre function of the first kind for complex arguments.
1787
1795
@@ -1791,8 +1799,8 @@ def clpmn(m, n, z, type=3):
1791
1799
``Pmn'(z)`` for all orders from ``0..m`` and degrees from ``0..n``.
1792
1800
1793
1801
.. deprecated:: 1.15.0
1794
- This function is deprecated and will be removed in a future version .
1795
- Use `scipy.special.assoc_legendre_p_all` instead.
1802
+ This function is deprecated and will be removed in SciPy 1.17.0 .
1803
+ Please use `scipy.special.assoc_legendre_p_all` instead.
1796
1804
1797
1805
Parameters
1798
1806
----------
@@ -2033,6 +2041,7 @@ def euler(n):
2033
2041
return _specfun .eulerb (n1 )[:(n + 1 )]
2034
2042
2035
2043
2044
+ @_deprecated (__DEPRECATION_MSG_1_15 .format ("lpn" , "legendre_p_all" ))
2036
2045
def lpn (n , z ):
2037
2046
"""Legendre function of the first kind.
2038
2047
@@ -2042,8 +2051,8 @@ def lpn(n, z):
2042
2051
See also special.legendre for polynomial class.
2043
2052
2044
2053
.. deprecated:: 1.15.0
2045
- This function is deprecated and will be removed in a future version .
2046
- Use `scipy.special.legendre_p_all` instead.
2054
+ This function is deprecated and will be removed in SciPy 1.17.0 .
2055
+ Please use `scipy.special.legendre_p_all` instead.
2047
2056
2048
2057
References
2049
2058
----------
@@ -3464,7 +3473,7 @@ def zeta(x, q=None, out=None):
3464
3473
``None``, complex inputs `x` are supported. If `q` is not ``None``,
3465
3474
then currently only real inputs `x` with ``x >= 1`` are supported,
3466
3475
even when ``q = 1.0`` (corresponding to the Riemann zeta function).
3467
-
3476
+
3468
3477
out : ndarray, optional
3469
3478
Output array for the computed values.
3470
3479
@@ -3530,7 +3539,7 @@ def zeta(x, q=None, out=None):
3530
3539
else :
3531
3540
return _ufuncs ._zeta (x , q , out )
3532
3541
3533
-
3542
+
3534
3543
def softplus (x , ** kwargs ):
3535
3544
r"""
3536
3545
Compute the softplus function element-wise.
@@ -3554,7 +3563,7 @@ def softplus(x, **kwargs):
3554
3563
Examples
3555
3564
--------
3556
3565
>>> from scipy import special
3557
-
3566
+
3558
3567
>>> special.softplus(0)
3559
3568
0.6931471805599453
3560
3569
0 commit comments