summaryrefslogtreecommitdiff
path: root/doc/source/reference/c-api/array.rst
Commit message (Collapse)AuthorAgeFilesLines
* DOC: delete out-of-date description of ResultType algorithmNathan Goldbaum2023-05-161-20/+4
|
* DOC: clarify how inputs of PyArray_ResultType are usedNathan Goldbaum2023-05-161-5/+5
|
* DOC: Fix return type of `PyArray_EinsteinSum` (#23684)Yuki2023-04-291-1/+1
| | | | The return type `PyArray_EinsteinSum` is `PyArrayObject*`, not `PyObject*`
* Merge pull request #23560 from F3eQnxN3RriK/doc-fix-parameter-typeMatti Picus2023-04-091-1/+1
|\ | | | | DOC: Fix parameter type of `PyArray_DiscardWritebackIfCopy`
| * DOC: Fix parameter type of `PyArray_DiscardWritebackIfCopy`yuki2023-04-081-1/+1
| | | | | | | | | | The type of parameter is `PyArrayObject`, not `PyObject`. ref: https://github.com/numpy/numpy/blob/main/numpy/core/include/numpy/ndarrayobject.h#L155-L167
* | DOC: Fix missing punctuation in `array.rst`yuki2023-04-071-1/+1
|/ | | | [skip ci]
* DOC: Fix description of `PyArray_DiscardWritebackIfCopy`yuki2023-04-071-1/+1
| | | | | | If my understanding of this document is correct, `PyArray_DiscardWritebackIfCopy` should be replaced with `PyArray_ResolveWritebackIfCopy`.
* DOC: Fix incorrect operators for member access in `array.rst`yuki2023-04-071-2/+2
| | | | Operators should be `->`, not `.`, for here both `obj` are pointers of C-struct.
* DOC: PyArray_ArrayType doesn't existSebastian Berg2023-03-311-11/+0
|
* DOC: Also delete PyArray_GetArrayParamsFromObjectSebastian Berg2023-03-311-16/+0
|
* DOC: Remove doc for non-existing `PyArray_XDECREF_ERR`Sebastian Berg2023-03-311-12/+0
| | | | The macro was removed, this is just a left over.
* MAINT: Fix a wrong format of referenceyuki2023-03-271-1/+1
|
* ENH: allow using dtype classes in array creation functionsNathan Goldbaum2023-03-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This enables writing np.array(some_object, dtype=type(np.dtype('i'))). This is a follow-on from https://github.com/numpy/numpy/pull/23154, see that PR for more details. I had to add a new include to `ctors.h` to bring in the definition of the `npy_dtype_info` struct. Since `ctors.h` is included in many other files inside numpy, I found that I needed to modify fewer includes across numpy if I moved the definition of `npy_dtype_info` to `common.h` from `descriptor.h`. The new includes of `common.h` are needed to support later includes of `ctors.h` in those files. If anyone has an alternate place to put `npy_dtype_info` that would cause less churn of includes I'd love to hear about it. I spent a bunch of time tweaking the reference counts. I'm reasonably confident this is correct but not 100%, an additional careful pass over the reference count logic from a reviewer would be very appreciated. I could have made `_PyArray_FromAny` and `_PyArray_CheckFromAny` take just a `npy_dtype_info` struct, but I found it made the reference count logic more complicated, since `PyArray_FromAny` and `PyArray_CheckFromAny` steal the reference to the descriptor they are passed and I needed to conserve that behavior. Also both functions support passing in a `NULL` pointer for the descriptor and I needed to maintain that behavior as well. The change to `ucsnarrow.h` fixes a preexisting conflict with the prototype in `ucsnarrow.c` that triggered a compiler error while I was working on this.
* DOC: Fix broken link in C-API array docs (#23117)Ross Barnowski2023-01-271-3/+3
| | | | | | Add link to array iterator example Co-authored-by: arunkumarkota <arunkumarkota@gmail.com> Co-authored-by: Arun Kota <arunkota@Aruns-iMac.local>
* Merge pull request #22411 from DimitriPapadopoulos/python2_docSebastian Berg2022-10-131-8/+8
|\ | | | | DOC: Remove documentation specific to Python 2
| * DOC: Remove documentation specific to Python 2Dimitri Papadopoulos2022-10-081-8/+8
| |
* | DOC: Add reference links and switch to PyCapsuleRohit Goswami2022-10-101-1/+1
| |
* | DOC: Replace CObject with Capsule consistentlyRohit Goswami2022-10-101-1/+1
|/
* MAINT: Fix typos found by codespellDimitri Papadopoulos2022-10-071-1/+1
|
* DOC: Adopt changes as suggested in reviewSebastian Berg2022-07-051-2/+3
| | | | Co-authored-by: Charles Harris <charlesr.harris@gmail.com>
* DOC: Document expectation for object array initializationSebastian Berg2022-06-231-0/+22
| | | | | | | | | | | | | This documents (and thus semi-establishes) that we try to make sure that any array that may be *read* is fully initialized with proper Python objects (not NULL). However, try to write in a way that clearly says that users are not allowed to rely on this. I somewhat suspect there are more code paths where we may to fail fully initializing object arrays... It does promise to regard such things as bugs, if we do not want that, I am happy to just tell users to expect NULLs.
* DOC: RST Titles Underline reordering (#21677)Matthias Bussonnier2022-06-081-30/+30
| | | | | | | | | | | | | | | | | | | | | * ~ not ^ * = skipped for - * swap - and = underline in files they are swapped * * to = in header underline * - to = and * to - for consitency * A few more change * -> ~ * use ~ instead of + * DOC: Fixup `c-api/array.rst` with further ^ with ~ replacement There is still a fourth level here, which remains using " Co-authored-by: Sebastian Berg <sebastian@sipsolutions.net>
* DOC: fix documentation for typedescr argument of PyArray_AsCArrayMarkus Mohrhard2022-05-141-9/+6
| | | | | The PyArray_AsCArray API does not conform to the documentation and document that the call steals a reference to the PyArray_Descr argument.
* DOC: Add PyArray_FailUnlessWriteable to the online C-API docs.warren2021-12-221-0/+11
| | | | | | | The text was copy-edited a bit, and the comments in the C file were updated to match the documentation in the .rst file. Closes gh-20623.
* DEP: remove NPY_ARRAY_UPDATEIFCOPY, deprecated in 1.14 (#20589)Matti Picus2021-12-181-43/+13
| | | | | | | | | | | | | * DEP: remove NPY_ARRAY_UPDATEIFCOPY, deprecated in 1.14 * remove more UPDATEIFCOPY * typo: add missing comma * remove a few more UPDATEIFCOPY * Add release note * remove UPDATEIFCOPY from comment (from review)
* Merge pull request #20195 from WarrenWeckesser/doc-miscSebastian Berg2021-10-271-8/+14
|\ | | | | DOC: Two small changes in array.rst:
| * DOC: Two small changes in array.rst:warren2021-10-261-8/+14
| | | | | | | | | | | | * Include the return values of `PyArray_RegisterCanCast` in the description. * Correct the documentation of `PyArray_Scalar`.
* | MAINT: Only warn for transferred ownership if env variable is set (#20200)Matti Picus2021-10-271-3/+4
|/ | | | | | | | | | | | | Builds on gh-20194. Fixes breakage of SciPy in https://github.com/scipy/scipy/issues/14917 At some point we could flip the default to "warn" instead of "no warning" * make warning conditional on NUMPY_WARN_IF_NO_MEM_POLICY * add test, fix example code * fixes from review * typo
* Add comments to prevent revert.Chiara Marmo2021-09-301-0/+12
|
* Fix scope of some sphinx declarations to avoid warnings.Chiara Marmo2021-09-281-24/+24
|
* Update doc/source/reference/c-api/array.rstCharles Harris2021-09-131-1/+1
| | | Co-authored-by: Melissa Weber Mendonça <melissawm@gmail.com>
* DOC: Added missing C-API functionsMukulika2021-09-081-14/+61
| | | | | | | | 1. PyArray_CopyObject 2. PyArray_MapIterArray 3. PyArray_MapIterSwapAxes 4. PyArray_MapIterNext 5. PyArray_MapIterArrayCopyIfOverlap
* Dedent list of macros.Chiara Marmo2021-08-021-13/+11
|
* Fix scope of c:macro.Chiara Marmo2021-08-011-9/+13
|
* Update doc/source/reference/c-api/array.rstChiara Marmo2021-07-271-1/+1
| | | Co-authored-by: Matti Picus <matti.picus@gmail.com>
* Remove PyArray_MultiIter_SIZE definition. Tentative definition for ↵Chiara Marmo2021-07-271-4/+10
| | | | PyArray_FinalizeFunc.
* Address some comments.Chiara Marmo2021-07-271-11/+10
|
* Fix sphinx warnings in c-info.beyond-basics.Chiara Marmo2021-07-271-0/+12
|
* DOC: NeighborhoodIterator position on creationMarco Aurelio da Costa2021-06-081-1/+7
| | | | | | Document that NeighborhoodIterator will point to the begining of the data instead of the position pointed by iter on creation in the special case where data is contiguous.
* DOC: Fix for buildling with sphinx 3takanori-pskq2020-11-061-47/+43
|
* Update doc/source/reference/c-api/array.rstTakanori H2020-10-271-1/+1
| | | Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
* DOC: Fix some referencestakanori-pskq2020-10-261-4/+4
|
* DOC: Don't use Python highlighting for non-python codeEric Wieser2020-10-251-1/+3
|
* Merge pull request #17627 from takanori-pskq/i13114-array-structMatti Picus2020-10-251-2/+2
|\ | | | | DOC: Fix the references for ``__array_*__``
| * DOC: Fix the references for ``__array_*__``takanori-pskq2020-10-251-2/+2
| |
* | DOC: Add entries for macrostakanori-pskq2020-10-251-3/+29
|/
* DOC: Fix some referencestakanori-pskq2020-10-241-2/+2
|
* Merge pull request #17570 from takanori-pskq/i13114-feature-versionMatti Picus2020-10-221-12/+16
|\ | | | | DOC: Add the entry for ``NPY_FEATURE_VERSION``
| * DOC: Fixuptakanori-pskq2020-10-221-17/+16
| |
| * DOC: Add the entry for ``NPY_FEATURE_VERSION``takanori-pskq2020-10-151-0/+5
| |