numpy.split()

numpy.split(ary, indices_or_sections, axis=0) [source] Split an array into multiple sub-arrays. Parameters: ary : ndarray Array to be divided into sub-arrays. indices_or_sections : int or 1-D array If indices_or_sections is an integer, N, the array will be divided into N equal arrays along axis. If such a split is not possible, an error is raised. If indices_or_sections is a 1-D array of sorted integers, the entries indicate where along axis the array is split. For example, [2, 3] would

numpy.source()

numpy.source(object, output=', mode 'w' at 0x402ae078>) [source] Print or write to a file the source code for a Numpy object. The source code is only returned for objects written in Python. Many functions and classes are defined in C and will therefore not return useful information. Parameters: object : numpy object Input object. This can be any object (function, class, module, ...). output : file object, optional If output not supplied then source code is printed to screen (sys.stdo

numpy.sort_complex()

numpy.sort_complex(a) [source] Sort a complex array using the real part first, then the imaginary part. Parameters: a : array_like Input array Returns: out : complex ndarray Always returns a sorted complex array. Examples >>> np.sort_complex([5, 3, 6, 2, 1]) array([ 1.+0.j, 2.+0.j, 3.+0.j, 5.+0.j, 6.+0.j]) >>> np.sort_complex([1 + 2j, 2 - 1j, 3 - 2j, 3 - 3j, 3 + 5j]) array([ 1.+2.j, 2.-1.j, 3.-3.j, 3.-2.j, 3.+5.j])

numpy.sort()

numpy.sort(a, axis=-1, kind='quicksort', order=None) [source] Return a sorted copy of an array. Parameters: a : array_like Array to be sorted. axis : int or None, optional Axis along which to sort. If None, the array is flattened before sorting. The default is -1, which sorts along the last axis. kind : {?quicksort?, ?mergesort?, ?heapsort?}, optional Sorting algorithm. Default is ?quicksort?. order : str or list of str, optional When a is an array with fields defined, this argument

numpy.sinh()

numpy.sinh(x[, out]) = Hyperbolic sine, element-wise. Equivalent to 1/2 * (np.exp(x) - np.exp(-x)) or -1j * np.sin(1j*x). Parameters: x : array_like Input array. out : ndarray, optional Output array of same shape as x. Returns: y : ndarray The corresponding hyperbolic sine values. Raises: ValueError: invalid return array shape if out is provided and out.shape != x.shape (See Examples) Notes If out is provided, the function writes the result into it, and returns a reference to

numpy.sinc()

numpy.sinc(x) [source] Return the sinc function. The sinc function is . Parameters: x : ndarray Array (possibly multi-dimensional) of values for which to to calculate sinc(x). Returns: out : ndarray sinc(x), which has the same shape as the input. Notes sinc(0) is the limit value 1. The name sinc is short for ?sine cardinal? or ?sinus cardinalis?. The sinc function is used in various signal processing applications, including in anti-aliasing, in the construction of a Lanczos resampli

numpy.sin()

numpy.sin(x[, out]) = Trigonometric sine, element-wise. Parameters: x : array_like Angle, in radians ( rad equals 360 degrees). Returns: y : array_like The sine of each element of x. See also arcsin, sinh, cos Notes The sine is one of the fundamental functions of trigonometry (the mathematical study of triangles). Consider a circle of radius 1 centered on the origin. A ray comes in from the axis, makes an angle at the origin (measured counter-clockwise from that axis), and depar

numpy.signbit()

numpy.signbit(x[, out]) = Returns element-wise True where signbit is set (less than zero). Parameters: x : array_like The input value(s). out : ndarray, optional Array into which the output is placed. Its type is preserved and it must be of the right shape to hold the output. See doc.ufuncs. Returns: result : ndarray of bool Output array, or reference to out if that was supplied. Examples >>> np.signbit(-1.2) True >>> np.signbit(np.array([1, -2.3, 2.1])) array([

numpy.sign()

numpy.sign(x[, out]) = Returns an element-wise indication of the sign of a number. The sign function returns -1 if x < 0, 0 if x==0, 1 if x > 0. nan is returned for nan inputs. For complex inputs, the sign function returns sign(x.real) + 0j if x.real != 0 else sign(x.imag) + 0j. complex(nan, 0) is returned for complex nan inputs. Parameters: x : array_like Input values. Returns: y : ndarray The sign of x. Notes There is more than one definition of sign in common use for compl

numpy.shares_memory()

numpy.shares_memory(a, b, max_work=None) Determine if two arrays share memory Parameters: a, b : ndarray Input arrays max_work : int, optional Effort to spend on solving the overlap problem (maximum number of candidate solutions to consider). The following special values are recognized: max_work=MAY_SHARE_EXACT (default) The problem is solved exactly. In this case, the function returns True only if there is an element shared between the arrays. max_work=MAY_SHARE_BOUNDS Only the memo