Coverage for /pythoncovmergedfiles/medio/medio/usr/local/lib/python3.8/site-packages/scipy/sparse/sputils.py: 70%
10 statements
« prev ^ index » next coverage.py v7.3.2, created at 2023-12-12 06:31 +0000
« prev ^ index » next coverage.py v7.3.2, created at 2023-12-12 06:31 +0000
1# This file is not meant for public use and will be removed in SciPy v2.0.0.
2# Use the `scipy.sparse` namespace for importing the functions
3# included below.
5import warnings
6from . import _sputils
9__all__ = [ # noqa: F822
10 'asmatrix',
11 'check_reshape_kwargs',
12 'check_shape',
13 'downcast_intp_index',
14 'get_index_dtype',
15 'get_sum_dtype',
16 'getdata',
17 'getdtype',
18 'is_pydata_spmatrix',
19 'isdense',
20 'isintlike',
21 'ismatrix',
22 'isscalarlike',
23 'issequence',
24 'isshape',
25 'matrix',
26 'operator',
27 'prod',
28 'supported_dtypes',
29 'sys',
30 'to_native',
31 'upcast',
32 'upcast_char',
33 'upcast_scalar',
34 'validateaxis',
35]
38def __dir__():
39 return __all__
42def __getattr__(name):
43 if name not in __all__:
44 raise AttributeError(
45 "scipy.sparse.sputils is deprecated and has no attribute "
46 f"{name}. Try looking in scipy.sparse instead.")
48 warnings.warn(f"Please use `{name}` from the `scipy.sparse` namespace, "
49 "the `scipy.sparse.sputils` namespace is deprecated.",
50 category=DeprecationWarning, stacklevel=2)
52 return getattr(_sputils, name)