Coverage for /pythoncovmergedfiles/medio/medio/usr/local/lib/python3.10/site-packages/numpy/_core/umath.py: 100%

Shortcuts on this page

r m x   toggle line displays

j k   next/prev highlighted chunk

0   (zero) top of page

1   (one) first highlighted chunk

6 statements  

1""" 

2Create the numpy._core.umath namespace for backward compatibility. In v1.16 

3the multiarray and umath c-extension modules were merged into a single 

4_multiarray_umath extension module. So we replicate the old namespace 

5by importing from the extension module. 

6 

7""" 

8 

9import numpy 

10from . import _multiarray_umath 

11from ._multiarray_umath import * # noqa: F403 

12# These imports are needed for backward compatibility, 

13# do not change them. issue gh-11862 

14# _ones_like is semi-public, on purpose not added to __all__ 

15from ._multiarray_umath import ( 

16 _UFUNC_API, _add_newdoc_ufunc, _ones_like, _get_extobj_dict, _make_extobj, 

17 _extobj_contextvar) 

18# These imports are needed for the strip & replace implementations 

19from ._multiarray_umath import ( 

20 _replace, _strip_whitespace, _lstrip_whitespace, _rstrip_whitespace, 

21 _strip_chars, _lstrip_chars, _rstrip_chars, _expandtabs_length, 

22 _expandtabs, _center, _ljust, _rjust, _zfill, _partition, _partition_index, 

23 _rpartition, _rpartition_index) 

24 

25__all__ = [ 

26 'absolute', 'add', 

27 'arccos', 'arccosh', 'arcsin', 'arcsinh', 'arctan', 'arctan2', 'arctanh', 

28 'bitwise_and', 'bitwise_or', 'bitwise_xor', 'cbrt', 'ceil', 'conj', 

29 'conjugate', 'copysign', 'cos', 'cosh', 'bitwise_count', 'deg2rad', 

30 'degrees', 'divide', 'divmod', 'e', 'equal', 'euler_gamma', 'exp', 'exp2', 

31 'expm1', 'fabs', 'floor', 'floor_divide', 'float_power', 'fmax', 'fmin', 

32 'fmod', 'frexp', 'frompyfunc', 'gcd', 'greater', 'greater_equal', 

33 'heaviside', 'hypot', 'invert', 'isfinite', 'isinf', 'isnan', 'isnat', 

34 'lcm', 'ldexp', 'left_shift', 'less', 'less_equal', 'log', 'log10', 

35 'log1p', 'log2', 'logaddexp', 'logaddexp2', 'logical_and', 'logical_not', 

36 'logical_or', 'logical_xor', 'matvec', 'maximum', 'minimum', 'mod', 'modf', 

37 'multiply', 'negative', 'nextafter', 'not_equal', 'pi', 'positive', 

38 'power', 'rad2deg', 'radians', 'reciprocal', 'remainder', 'right_shift', 

39 'rint', 'sign', 'signbit', 'sin', 'sinh', 'spacing', 'sqrt', 'square', 

40 'subtract', 'tan', 'tanh', 'true_divide', 'trunc', 'vecdot', 'vecmat']