|
numpy 2.0.0
|
#include <Python.h>#include "structmember.h"#include "numpy/arrayobject.h"#include "npy_config.h"#include "numpy/npy_3kcompat.h"#include "number.h"Defines | |
| #define | PY_SSIZE_T_CLEAN |
| #define | NPY_NO_DEPRECATED_API |
| #define | _MULTIARRAYMODULE |
| #define | NPY_NO_PREFIX |
| #define | SET(op) |
| #define | GET(op) |
Functions | |
| NPY_NO_EXPORT int | PyArray_SetNumericOps (PyObject *dict) |
| NPY_NO_EXPORT PyObject * | PyArray_GetNumericOps (void) |
| static PyObject * | _get_keywords (int rtype, PyArrayObject *out) |
| NPY_NO_EXPORT PyObject * | PyArray_GenericReduceFunction (PyArrayObject *m1, PyObject *op, int axis, int rtype, PyArrayObject *out) |
| NPY_NO_EXPORT PyObject * | PyArray_GenericAccumulateFunction (PyArrayObject *m1, PyObject *op, int axis, int rtype, PyArrayObject *out) |
| NPY_NO_EXPORT PyObject * | PyArray_GenericBinaryFunction (PyArrayObject *m1, PyObject *m2, PyObject *op) |
| NPY_NO_EXPORT PyObject * | PyArray_GenericUnaryFunction (PyArrayObject *m1, PyObject *op) |
| static PyObject * | PyArray_GenericInplaceBinaryFunction (PyArrayObject *m1, PyObject *m2, PyObject *op) |
| static PyObject * | PyArray_GenericInplaceUnaryFunction (PyArrayObject *m1, PyObject *op) |
| static PyObject * | array_add (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_subtract (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_multiply (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_divide (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_remainder (PyArrayObject *m1, PyObject *m2) |
| static int | array_power_is_scalar (PyObject *o2, double *exp) |
| static PyObject * | fast_scalar_power (PyArrayObject *a1, PyObject *o2, int inplace) |
| static PyObject * | array_power (PyArrayObject *a1, PyObject *o2, PyObject *NPY_UNUSED(modulo)) |
| static PyObject * | array_negative (PyArrayObject *m1) |
| static PyObject * | array_absolute (PyArrayObject *m1) |
| static PyObject * | array_invert (PyArrayObject *m1) |
| static PyObject * | array_left_shift (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_right_shift (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_bitwise_and (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_bitwise_or (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_bitwise_xor (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_inplace_add (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_inplace_subtract (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_inplace_multiply (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_inplace_divide (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_inplace_remainder (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_inplace_power (PyArrayObject *a1, PyObject *o2, PyObject *NPY_UNUSED(modulo)) |
| static PyObject * | array_inplace_left_shift (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_inplace_right_shift (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_inplace_bitwise_and (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_inplace_bitwise_or (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_inplace_bitwise_xor (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_floor_divide (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_true_divide (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_inplace_floor_divide (PyArrayObject *m1, PyObject *m2) |
| static PyObject * | array_inplace_true_divide (PyArrayObject *m1, PyObject *m2) |
| static int | _array_nonzero (PyArrayObject *mp) |
| static PyObject * | array_divmod (PyArrayObject *op1, PyObject *op2) |
| NPY_NO_EXPORT PyObject * | array_int (PyArrayObject *v) |
| static PyObject * | array_float (PyArrayObject *v) |
| static PyObject * | array_long (PyArrayObject *v) |
| static PyObject * | array_oct (PyArrayObject *v) |
| static PyObject * | array_hex (PyArrayObject *v) |
| static PyObject * | _array_copy_nice (PyArrayObject *self) |
Variables | |
| NPY_NO_EXPORT NumericOps | n_ops |
| NPY_NO_EXPORT PyNumberMethods | array_as_number |
| #define _MULTIARRAYMODULE |
| #define GET | ( | op | ) |
| #define NPY_NO_DEPRECATED_API |
| #define NPY_NO_PREFIX |
| #define PY_SSIZE_T_CLEAN |
| #define SET | ( | op | ) |
temp = PyDict_GetItemString(dict, #op); \
if (temp != NULL) { \
if (!(PyCallable_Check(temp))) { \
return -1; \
} \
Py_INCREF(temp); \
Py_XDECREF(n_ops.op); \
n_ops.op = temp; \
}
| static PyObject* _array_copy_nice | ( | PyArrayObject * | self | ) | [static] |
| static int _array_nonzero | ( | PyArrayObject * | mp | ) | [static] |
| static PyObject* _get_keywords | ( | int | rtype, |
| PyArrayObject * | out | ||
| ) | [static] |
Referenced by PyArray_GenericReduceFunction().
| static PyObject* array_absolute | ( | PyArrayObject * | m1 | ) | [static] |
References NumericOps::bitwise_xor, n_ops, and PyArray_GenericBinaryFunction().
| static PyObject* array_add | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
References n_ops, PyArray_GenericBinaryFunction(), and NumericOps::remainder.
| static PyObject* array_bitwise_and | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
References NumericOps::divide, n_ops, and PyArray_GenericInplaceBinaryFunction().
| static PyObject* array_bitwise_or | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
References n_ops, PyArray_GenericInplaceBinaryFunction(), and NumericOps::remainder.
| static PyObject* array_bitwise_xor | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
References fast_scalar_power().
| static PyObject* array_divide | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
References Py_TYPE.
| static PyObject* array_divmod | ( | PyArrayObject * | op1, |
| PyObject * | op2 | ||
| ) | [static] |
| static PyObject* array_float | ( | PyArrayObject * | v | ) | [static] |
References PyArrayObject::data, PyArrayObject::descr, _PyArray_Descr::f, PyArray_ArrFuncs::getitem, Py_TYPE, PyArray_Check, PyArray_DESCR, PyArray_SIZE, and PyDataType_REFCHK.
| static PyObject* array_floor_divide | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
Referenced by array_inplace_floor_divide().
| static PyObject* array_hex | ( | PyArrayObject * | v | ) | [static] |
References PyArrayObject::data, PyArrayObject::descr, _PyArray_Descr::f, PyArray_ArrFuncs::getitem, PyArray_ISINTEGER, and PyArray_SIZE.
| static PyObject* array_inplace_add | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
References n_ops, NumericOps::power, and PyArray_GenericInplaceBinaryFunction().
| static PyObject* array_inplace_bitwise_and | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
References n_ops, PyArray_GenericInplaceBinaryFunction(), and NumericOps::true_divide.
| static PyObject* array_inplace_bitwise_or | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
References PyArray_SIZE.
| static PyObject* array_inplace_bitwise_xor | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
| static PyObject* array_inplace_divide | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
References NumericOps::bitwise_and, n_ops, and PyArray_GenericInplaceBinaryFunction().
| static PyObject* array_inplace_floor_divide | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
References array_floor_divide().
| static PyObject* array_inplace_left_shift | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
| static PyObject* array_inplace_multiply | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
References n_ops, PyArray_GenericInplaceBinaryFunction(), and NumericOps::right_shift.
| static PyObject* array_inplace_power | ( | PyArrayObject * | a1, |
| PyObject * | o2, | ||
| PyObject * | NPY_UNUSEDmodulo | ||
| ) | [static] |
References NumericOps::bitwise_xor, n_ops, and PyArray_GenericInplaceBinaryFunction().
| static PyObject* array_inplace_remainder | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
References NumericOps::bitwise_or, n_ops, and PyArray_GenericInplaceBinaryFunction().
| static PyObject* array_inplace_right_shift | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
| static PyObject* array_inplace_subtract | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
References NumericOps::left_shift, n_ops, and PyArray_GenericInplaceBinaryFunction().
| static PyObject* array_inplace_true_divide | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
| NPY_NO_EXPORT PyObject* array_int | ( | PyArrayObject * | v | ) |
References PyArrayObject::data, PyArrayObject::descr, _PyArray_Descr::f, PyArray_ArrFuncs::getitem, Py_TYPE, PyArray_Check, PyArray_DESCR, PyArray_SIZE, and PyDataType_REFCHK.
| static PyObject* array_invert | ( | PyArrayObject * | m1 | ) | [static] |
References NumericOps::add, n_ops, and PyArray_GenericInplaceBinaryFunction().
| static PyObject* array_left_shift | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
References n_ops, PyArray_GenericInplaceBinaryFunction(), and NumericOps::subtract.
| static PyObject* array_long | ( | PyArrayObject * | v | ) | [static] |
| static PyObject* array_multiply | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
| static PyObject* array_negative | ( | PyArrayObject * | m1 | ) | [static] |
References NumericOps::bitwise_or, n_ops, and PyArray_GenericBinaryFunction().
| static PyObject* array_oct | ( | PyArrayObject * | v | ) | [static] |
| static PyObject* array_power | ( | PyArrayObject * | a1, |
| PyObject * | o2, | ||
| PyObject * | NPY_UNUSEDmodulo | ||
| ) | [static] |
| static int array_power_is_scalar | ( | PyObject * | o2, |
| double * | exp | ||
| ) | [static] |
| static PyObject* array_remainder | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
| static PyObject* array_right_shift | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
References NumericOps::multiply, n_ops, and PyArray_GenericInplaceBinaryFunction().
| static PyObject* array_subtract | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
| static PyObject* array_true_divide | ( | PyArrayObject * | m1, |
| PyObject * | m2 | ||
| ) | [static] |
| static PyObject* fast_scalar_power | ( | PyArrayObject * | a1, |
| PyObject * | o2, | ||
| int | inplace | ||
| ) | [static] |
Referenced by array_bitwise_xor().
| NPY_NO_EXPORT PyObject* PyArray_GenericAccumulateFunction | ( | PyArrayObject * | m1, |
| PyObject * | op, | ||
| int | axis, | ||
| int | rtype, | ||
| PyArrayObject * | out | ||
| ) |
Referenced by PyArray_Prod().
| NPY_NO_EXPORT PyObject* PyArray_GenericBinaryFunction | ( | PyArrayObject * | m1, |
| PyObject * | m2, | ||
| PyObject * | op | ||
| ) |
Referenced by _void_compare(), array_absolute(), array_add(), array_negative(), array_power(), and PyArray_GenericInplaceBinaryFunction().
| static PyObject* PyArray_GenericInplaceBinaryFunction | ( | PyArrayObject * | m1, |
| PyObject * | m2, | ||
| PyObject * | op | ||
| ) | [static] |
References n_ops, PyArray_GenericBinaryFunction(), and NumericOps::subtract.
Referenced by array_bitwise_and(), array_bitwise_or(), array_inplace_add(), array_inplace_bitwise_and(), array_inplace_divide(), array_inplace_multiply(), array_inplace_power(), array_inplace_remainder(), array_inplace_subtract(), array_invert(), array_left_shift(), and array_right_shift().
| static PyObject* PyArray_GenericInplaceUnaryFunction | ( | PyArrayObject * | m1, |
| PyObject * | op | ||
| ) | [static] |
| NPY_NO_EXPORT PyObject* PyArray_GenericReduceFunction | ( | PyArrayObject * | m1, |
| PyObject * | op, | ||
| int | axis, | ||
| int | rtype, | ||
| PyArrayObject * | out | ||
| ) |
References _get_keywords().
Referenced by _strings_richcompare().
| NPY_NO_EXPORT PyObject* PyArray_GenericUnaryFunction | ( | PyArrayObject * | m1, |
| PyObject * | op | ||
| ) |
| NPY_NO_EXPORT PyObject* PyArray_GetNumericOps | ( | void | ) |
| NPY_NO_EXPORT int PyArray_SetNumericOps | ( | PyObject * | dict | ) |
| NPY_NO_EXPORT PyNumberMethods array_as_number |
| NPY_NO_EXPORT NumericOps n_ops |
Referenced by _strings_richcompare(), _void_compare(), array_absolute(), array_add(), array_bitwise_and(), array_bitwise_or(), array_inplace_add(), array_inplace_bitwise_and(), array_inplace_divide(), array_inplace_multiply(), array_inplace_power(), array_inplace_remainder(), array_inplace_subtract(), array_invert(), array_left_shift(), array_negative(), array_power(), array_right_shift(), PyArray_GenericInplaceBinaryFunction(), and PyArray_Prod().