Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/numpy/numpy
/ functions
Functions
17,008 in github.com/numpy/numpy
⨍
Functions
17,008
◇
Types & classes
2,137
↳
Endpoints
358
↓ 1,812 callers
Function
assert_equal
Raises an AssertionError if two objects are not equal. Given two objects (scalars, lists, tuples, dictionaries or numpy arrays), check t
numpy/testing/_private/utils.py:212
↓ 1,225 callers
Function
assert_
Assert that works in release mode. Accepts callable msg to allow deferring evaluation until failure. The Python built-in ``assert`` does
numpy/testing/_private/utils.py:71
↓ 951 callers
Function
assert_array_equal
Raises an AssertionError if two array_like objects are not equal. Given two array_like objects, check that the shape is equal and all el
numpy/testing/_private/utils.py:808
↓ 936 callers
Function
assert_raises
assert_raises(exception_class, callable, *args, **kwargs) assert_raises(exception_class) Fail unless an exception of class exception_cla
numpy/testing/_private/utils.py:1269
↓ 539 callers
Function
assert_equal
Asserts that two items are equal.
numpy/ma/testutils.py:108
↓ 497 callers
Method
dtype
(self)
numpy/ma/core.py:3418
↓ 496 callers
Method
reshape
Give a new shape to the array without changing its data. Returns a masked array containing the same data, but with a new shape.
numpy/ma/core.py:4686
↓ 416 callers
Method
astype
(self, typecode)
numpy/lib/user_array.py:238
↓ 393 callers
Function
max
(obj, axis=None, out=None, fill_value=None, keepdims=np._NoValue)
numpy/ma/core.py:6814
↓ 377 callers
Method
view
Return a view of the MaskedArray data. Parameters ---------- dtype : data-type or ndarray sub-class, optional
numpy/ma/core.py:3127
↓ 304 callers
Function
assert_almost_equal
Raises an AssertionError if two items are not equal up to desired precision. .. note:: It is recommended to use one of `assert_allclose`
numpy/testing/_private/utils.py:414
↓ 291 callers
Method
join
Return a string which is the concatenation of the strings in the sequence `seq`. See Also -------- char.join
numpy/core/defchararray.py:2453
↓ 253 callers
Function
print
numpy/linalg/umath_linalg.cpp:615
↓ 247 callers
Function
array
Shortcut to MaskedArray. The options are in a different order for convenience and backwards compatibility.
numpy/ma/core.py:6660
↓ 229 callers
Function
min
(obj, axis=None, out=None, fill_value=None, keepdims=np._NoValue)
numpy/ma/core.py:6802
↓ 220 callers
Function
lsame_
numpy/linalg/lapack_lite/f2c_config.c:999
↓ 217 callers
Function
assert_array_almost_equal
Raises an AssertionError if two objects are not equal up to desired precision. .. note:: It is recommended to use one of `assert_allclos
numpy/testing/_private/utils.py:926
↓ 210 callers
Method
all
Returns True if all elements evaluate to True. The output array is masked where all the values along the given axis are mask
numpy/ma/core.py:4908
↓ 196 callers
Function
open
Open `path` with `mode` and return the file object. If ``path`` is an URL, it will be downloaded, stored in the `DataSource` `destpath`
numpy/lib/_datasource.py:155
↓ 194 callers
Method
split
For each element in `self`, return a list of the words in the string, using `sep` as the delimiter string. See Also
numpy/core/defchararray.py:2594
↓ 192 callers
Function
PyArray_DESCR
numpy/core/include/numpy/ndarraytypes.h:1552
↓ 171 callers
Function
PyArray_NDIM
numpy/core/include/numpy/ndarraytypes.h:1504
↓ 164 callers
Method
_new
This is a private method for initializing the array API Array object. Functions outside of the array_api submodule should no
numpy/array_api/_array_object.py:65
↓ 160 callers
Method
join
(argv)
numpy/distutils/_shell_utils.py:80
↓ 157 callers
Method
copy
numpy/core/src/common/numpy_tag.h:235
↓ 149 callers
Method
get
Returns the C #definition name of docstring according to ufunc place. C #definitions are generated by generate_umath_doc.py i
numpy/core/code_generators/generate_umath.py:25
↓ 146 callers
Function
sqrt
Compute the square root of x. For negative input elements, a complex value is returned (unlike `numpy.sqrt` which returns NaN). Par
numpy/lib/scimath.py:199
↓ 139 callers
Method
startswith
Returns a boolean array which is `True` where the string element in `self` starts with `prefix`, otherwise `False`. See Also
numpy/core/defchararray.py:2618
↓ 137 callers
Method
warn
(self, message)
numpy/distutils/misc_util.py:889
↓ 136 callers
Function
f
(x)
numpy/polynomial/tests/test_classes.py:146
↓ 126 callers
Function
arange
Array API compatible wrapper for :py:func:`np.arange <numpy.arange>`. See its docstring for more information.
numpy/array_api/_creation_functions.py:75
↓ 125 callers
Function
abs
Array API compatible wrapper for :py:func:`np.abs <numpy.abs>`. See its docstring for more information.
numpy/array_api/_elementwise_functions.py:19
↓ 119 callers
Function
ilaenv_
numpy/linalg/lapack_lite/f2c_lapack.c:472
↓ 113 callers
Function
PyArray_DATA
numpy/core/include/numpy/ndarraytypes.h:1510
↓ 110 callers
Method
strip
For each element in `self`, return a copy with the leading and trailing characters removed. See Also --------
numpy/core/defchararray.py:2630
↓ 108 callers
Method
replace
For each element in `self`, return a copy of the string with all occurrences of substring `old` replaced by `new`. See Also
numpy/core/defchararray.py:2511
↓ 107 callers
Method
linspace
Return x, y values at equally spaced points in domain. Returns the x, y values at `n` linearly spaced points across the domain. Here
numpy/polynomial/_polybase.py:923
↓ 106 callers
Method
add
(self, line)
numpy/linalg/lapack_lite/clapack_scrub.py:114
↓ 98 callers
Function
func
(self, other)
numpy/lib/mixins.py:18
↓ 96 callers
Function
assert_allclose
Raises an AssertionError if two objects are not equal up to desired tolerance. Given two array_like objects, check that their shapes and
numpy/testing/_private/utils.py:1438
↓ 96 callers
Method
dtype
(self)
numpy/lib/tests/test_type_check.py:217
↓ 96 callers
Method
seek
(self, off, whence=0)
numpy/lib/tests/test_io.py:2671
↓ 95 callers
Method
dot
a.dot(b, out=None) Masked dot product of two arrays. Note that `out` and `strict` are located in different positions than in
numpy/ma/core.py:5091
↓ 95 callers
Method
random
Returns a randomly-shuffled array.
benchmarks/benchmarks/bench_function_base.py:150
↓ 94 callers
Method
any
Returns True if any of the elements of `a` evaluate to True. Masked values are considered as False during computation. Refe
numpy/ma/core.py:4948
↓ 93 callers
Method
ravel
Returns a 1D version of self, as a view. Parameters ---------- order : {'C', 'F', 'A', 'K'}, optional Th
numpy/ma/core.py:4624
↓ 93 callers
Method
sort
Sort the array, in-place Parameters ---------- a : array_like Array to be sorted. axis : int, op
numpy/ma/core.py:5677
↓ 92 callers
Method
get
(self, name, default=None)
numpy/distutils/fcompiler/environment.py:42
↓ 92 callers
Method
keys
Return the keys of currently supported file openers. Parameters ---------- None Returns -------
numpy/lib/_datasource.py:130
↓ 90 callers
Method
copy
Copy is a no-op on the maskedconstant, as it is a scalar
numpy/ma/core.py:6631
↓ 86 callers
Function
PyArray_DIMS
numpy/core/include/numpy/ndarraytypes.h:1522
↓ 85 callers
Method
reduce
Reduce target along the given axis.
numpy/ma/core.py:6754
↓ 79 callers
Method
write
(self, v)
numpy/lib/npyio.py:1530
↓ 76 callers
Method
compile
Compile the wrapper.
numpy/f2py/_backends/_backend.py:44
↓ 75 callers
Method
sum
Return the sum of the array elements over the given axis. Masked elements are set to 0 internally. Refer to `numpy.sum` for
numpy/ma/core.py:5130
↓ 73 callers
Function
asarray
Convert the input to a masked array of the given data-type. No copy is performed if the input is already an `ndarray`. If `a` is a subcl
numpy/ma/core.py:8204
↓ 72 callers
Method
split
(cmd)
numpy/distutils/_shell_utils.py:84
↓ 71 callers
Method
read
(self, n)
numpy/lib/tests/test_io.py:2668
↓ 68 callers
Function
assert_raises_regex
assert_raises_regex(exception_class, expected_regexp, callable, *args, **kwargs) assert_raises_regex(exception_class,
numpy/testing/_private/utils.py:1298
↓ 67 callers
Function
PyArray_STRIDES
numpy/core/include/numpy/ndarraytypes.h:1528
↓ 65 callers
Function
assert_warns
Fail unless the given callable throws the specified warning. A warning of class warning_class should be thrown by the callable when invo
numpy/testing/_private/utils.py:1726
↓ 64 callers
Method
exists
Test if path exists. Test if `path` exists as (and in this order): - a local file. - a remote URL that has been dow
numpy/lib/_datasource.py:431
↓ 64 callers
Function
getmask
Return the mask of a masked array, or nomask. Return the mask of `a` as an ndarray if `a` is a `MaskedArray` and the mask is not `nomask
numpy/ma/core.py:1362
↓ 63 callers
Method
close
Close the file.
numpy/lib/npyio.py:212
↓ 63 callers
Method
lower
Return an array with the elements of `self` converted to lowercase. See Also -------- char.lower
numpy/core/defchararray.py:2477
↓ 60 callers
Method
clip
(self, a, m, M, out=None)
numpy/core/tests/test_numeric.py:1842
↓ 58 callers
Method
item
(self)
tools/npy_tempita/_looper.py:84
↓ 57 callers
Method
abspath
Return absolute path of file in the DataSource directory. If `path` is an URL, then `abspath` will return either the location
numpy/lib/_datasource.py:375
↓ 57 callers
Function
less
Return (x1 < x2) element-wise. Unlike `numpy.greater`, this comparison is performed by first stripping whitespace characters from the en
numpy/core/defchararray.py:236
↓ 56 callers
Function
log
Compute the natural logarithm of `x`. Return the "principal value" (for a description of this, see `numpy.log`) of :math:`log_e(x)`. For
numpy/lib/scimath.py:252
↓ 55 callers
Method
info
(self, message)
numpy/distutils/misc_util.py:885
↓ 55 callers
Function
slamch_
numpy/linalg/lapack_lite/f2c_config.c:1107
↓ 54 callers
Method
filter
Add a new suppressing filter or apply it if the state is entered. Parameters ---------- category : class, optional
numpy/testing/_private/utils.py:2125
↓ 53 callers
Method
filled
Return a copy with masked fields filled with a given value. Parameters ---------- fill_value : array_like, optional
numpy/ma/core.py:6432
↓ 52 callers
Method
_normalize_two_args
Normalize inputs to two arg functions to fix type promotion rules NumPy deviates from the spec type promotion rules in cases where o
numpy/array_api/_array_object.py:223
↓ 52 callers
Method
endswith
Returns a boolean array which is `True` where the string element in `self` ends with `suffix`, otherwise `False`. See Also
numpy/core/defchararray.py:2317
↓ 51 callers
Function
asanyarray
Convert the input to a masked array, conserving subclasses. If `a` is a subclass of `MaskedArray`, its class is conserved. No copy is pe
numpy/ma/core.py:8253
↓ 51 callers
Method
write
(self, s)
numpy/lib/tests/test_io.py:45
↓ 50 callers
Function
PyArray_NewFromDescr
NUMPY_API * Generic new array creation routine. * * steals a reference to descr. On failure or when dtype->subarray is * true, dtype will be decre
numpy/core/src/multiarray/ctors.c:979
↓ 50 callers
Function
array
Construct a record array from a wide-variety of objects. A general-purpose record array constructor that dispatches to the appropriate `
numpy/core/records.py:954
↓ 50 callers
Method
decode
Calls ``bytes.decode`` element-wise. See Also -------- char.decode
numpy/core/defchararray.py:2295
↓ 49 callers
Function
PyArray_FLAGS
numpy/core/include/numpy/ndarraytypes.h:1558
↓ 49 callers
Function
PyArray_ITEMSIZE
numpy/core/include/numpy/ndarraytypes.h:1564
↓ 48 callers
Method
assert_deprecated
Test if DeprecationWarnings are given and raised. This first checks if the function when called gives `num` DeprecationWarnings, afte
numpy/core/tests/test_deprecations.py:52
↓ 48 callers
Method
set_info
(self, **info)
numpy/distutils/system_info.py:784
↓ 47 callers
Method
sum
(self, axis=None, dtype=None, out=None)
numpy/core/tests/test_numeric.py:3570
↓ 46 callers
Function
PyArray_DIM
numpy/core/include/numpy/ndarraytypes.h:1534
↓ 45 callers
Method
_check_allowed_dtypes
Helper function for operators to only allow specific input dtypes Use like other = self._check_allowed_dtypes(other, 'n
numpy/array_api/_array_object.py:130
↓ 44 callers
Function
_vec_string
numpy/core/src/multiarray/multiarraymodule.c:4205
↓ 44 callers
Method
tolist
Transforms the mvoid object into a tuple. Masked fields are replaced by None. Returns ------- returned_tuple Tuple of f
numpy/ma/core.py:6456
↓ 43 callers
Function
all
Test whether all array elements along a given axis evaluate to True. Parameters ---------- a : array_like Input array or obj
numpy/core/fromnumeric.py:2422
↓ 43 callers
Method
index
Like `find`, but raises `ValueError` when the substring is not found. See Also -------- char.index
numpy/core/defchararray.py:2353
↓ 43 callers
Method
prod
Return the product of the array elements over the given axis. Masked elements are set to 1 internally for computation. Refe
numpy/ma/core.py:5233
↓ 43 callers
Function
temppath
Context manager for temporary files. Context manager that returns the path to a closed temporary file. Its parameters are the same as for tem
numpy/testing/_private/utils.py:1917
↓ 42 callers
Method
update
Set StringConverter attributes directly. Parameters ---------- func : function Conversion function.
numpy/lib/_iotools.py:764
↓ 41 callers
Function
PyArray_BYTES
numpy/core/include/numpy/ndarraytypes.h:1516
↓ 40 callers
Method
upper
Return an array with the elements of `self` converted to uppercase. See Also -------- char.upper
numpy/core/defchararray.py:2681
↓ 39 callers
Method
nonzero
Return the indices of unmasked elements that are not zero. Returns a tuple of arrays, one for each dimension, containing the
numpy/ma/core.py:4978
↓ 39 callers
Method
uniform
Returns an array that has the same value everywhere.
benchmarks/benchmarks/bench_function_base.py:176
↓ 38 callers
Function
asarray
Convert the input to a `chararray`, copying the data only if necessary. Versus a regular NumPy array of type `str` or `unicode`, this
numpy/core/defchararray.py:2865
next →
1–100 of 17,008, ranked by callers