%J5tK d Z g dZddlmc mZ ddlmZ ddlZddl Z ddZ
ee
dd dd Z ee
dd dd
Z ee
dd dd Z
dS )
zr
Module of functions that are like ufuncs in acting on arrays and optionally
storing results in an output array.
)fixisneginfisposinf N)array_function_dispatchc
| |fS N )xouts g/builddir/build/BUILD/cloudlinux-venv-1.0.10/venv/lib64/python3.11/site-packages/numpy/lib/ufunclike.py_dispatcherr
s
s8O Fnumpy)verifymodulec t j t j | | }t j | |t j | d }|#t | t j u r|d }|S )aL
Round to nearest integer towards zero.
Round an array of floats element-wise to nearest integer towards zero.
The rounded values are returned as floats.
Parameters
----------
x : array_like
An array of floats to be rounded
out : ndarray, optional
A location into which the result is stored. If provided, it must have
a shape that the input broadcasts to. If not provided or None, a
freshly-allocated array is returned.
Returns
-------
out : ndarray of floats
A float array with the same dimensions as the input.
If second argument is not supplied then a float array is returned
with the rounded values.
If a second argument is supplied the result is stored there.
The return value `out` is then a reference to that array.
See Also
--------
rint, trunc, floor, ceil
around : Round to given number of decimals
Examples
--------
>>> np.fix(3.14)
3.0
>>> np.fix(3)
3.0
>>> np.fix([2.1, 2.9, -2.1, -2.9])
array([ 2., 2., -2., -2.])
)r r )r whereNr )nx
asanyarrayceilfloor
greater_equaltypendarray)r
r ress r r r sm V
-s+++
,
,C
(1#R%5a%;%;
<
<