summaryrefslogtreecommitdiff
path: root/numpy
Commit message (Collapse)AuthorAgeFilesLines
...
* | | | | | | | | | DOC: Add examples for isdigit and str_len (#22291)Digya0532022-09-191-0/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Co-authored-by: Sebastian Berg <sebastian@sipsolutions.net>
* | | | | | | | | | DOC: Add `isupper` examples (#22285)Sarah Coffland2022-09-191-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * added examples for isupper * fixed examples for isupper * Update numpy/core/defchararray.py Co-authored-by: Rohit Goswami <r95g10@gmail.com> * Update numpy/core/defchararray.py Co-authored-by: Rohit Goswami <r95g10@gmail.com> * Update numpy/core/defchararray.py Co-authored-by: Rohit Goswami <r95g10@gmail.com> * Update numpy/core/defchararray.py Co-authored-by: Ross Barnowski <rossbar@berkeley.edu> Co-authored-by: Rohit Goswami <r95g10@gmail.com> Co-authored-by: Sebastian Berg <sebastian@sipsolutions.net> Co-authored-by: Ross Barnowski <rossbar@berkeley.edu> Co-authored-by: Charles Harris <charlesr.harris@gmail.com>
* | | | | | | | | | DOC: Correct usage example for np.char.decode docstring (#22309)Brent Tan2022-09-191-9/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The docstring was previously a copy-paste error from `encode` rather than `decode`.
* | | | | | | | | | DOC: Add examples for join and index (#22299)Yunika Bajracharya2022-09-191-0/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add examples for join and index for issue #22267 * DOC: add join, index examples * DOC: update join in np.char Co-authored-by: Brigitta Sipőcz <b.sipocz@gmail.com>
* | | | | | | | | | DOC: add examples to np.char.multiply (#22294)Eric-Shang2022-09-191-1/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | resolves #22267 partially by adding examples to np.char.multiply * DOC: add examples to np.char.mutiply * Update numpy/core/defchararray.py Co-authored-by: Ross Barnowski <rossbar@berkeley.edu> * Update numpy/core/defchararray.py Co-authored-by: Ross Barnowski <rossbar@berkeley.edu> Co-authored-by: Ross Barnowski <rossbar@berkeley.edu>
* | | | | | | | | | DOC: Update for return value of np.ptp() (#22276)Digya0532022-09-191-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Update documentation for return value of np.ptp() * Update integer value to scalar to accomodate other numeric data types * Add examples to np.char.isdigit() * Remove extra space and example Closes gh-18719
* | | | | | | | | | Merge pull request #22295 from tahsinsoha/isupperCharles Harris2022-09-181-0/+7
|\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | DOC: Added an example for isupper() function
| * | | | | | | | | | MAIN: `import numpy as np` is not neededCharles Harris2022-09-181-2/+1
| | | | | | | | | | |
| * | | | | | | | | | Update numpy/core/defchararray.pyCharles Harris2022-09-181-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Co-authored-by: Brigitta Sipőcz <b.sipocz@gmail.com>
| * | | | | | | | | | Added an example for isupper() functionSabiha Tahsin Soha2022-09-161-0/+8
| | |/ / / / / / / / | |/| | | | | | | |
* | | | | | | | | | Merge pull request #22263 from MatteoRaso/finfo_complexMatti Picus2022-09-181-1/+7
|\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | DOC: Clarified how finfo works with complex numbers (#22260)
| * | | | | | | | | | DOC: Clarified how finfo works with complex numbers (#22260)Matteo Raso2022-09-141-1/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There was some confusion about how finfo works with complex numbers, leading to an issue being made requesting that numpy either adds a cinfo function or changes the documentation of finfo. The submitter of that issue also linked to an issue for a seperate repository, which also included conversation about the proposed change. (github.com/data-apis/array-api/issues/433) In both discussions, there was a general concensus that it would be better to change the documentation to explain how finfo works instead of creating a cinfo function. Since this is just a small documentation change, there's no need to run the normal checks. [skip ci]
* | | | | | | | | | | Merge pull request #22272 from Begasus/HaikuMatti Picus2022-09-182-1/+3
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | MAINT, Haiku defines neither __STDC_NO_THREADS__ nor __GLIBC__
| * | | | | | | | | | | MAINT, Haiku defines neither __STDC_NO_THREADS__ nor __GLIBC__begasus2022-09-162-1/+3
| | |/ / / / / / / / / | |/| | | | | | | | |
* | | | | | | | | | | Merge pull request #22296 from clearspear/memleak_nesteditersTyler Reddy2022-09-171-0/+1
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | BUG: Memory leaks in numpy.nested_iters
| * | | | | | | | | | | Adding missing Py_DECREF call on iterSicheng Zeng2022-09-161-0/+1
| |/ / / / / / / / / /
* | | | | | | | | | | Merge pull request #22279 from shreya-singh-tech/shreyaCharles Harris2022-09-171-0/+7
|\ \ \ \ \ \ \ \ \ \ \ | |_|_|_|/ / / / / / / |/| | | | | | | | | | DOC: Add example to msort docstring
| * | | | | | | | | | STY: minor formatting touchups.Ross Barnowski2022-09-161-3/+2
| | | | | | | | | | |
| * | | | | | | | | | DOC: Add examples to msort in lib/function_base.pyShreya2022-09-161-0/+8
| |/ / / / / / / / /
* | | | | | | | | | Merge pull request #22298 from swagatip/swagatipCharles Harris2022-09-171-0/+26
|\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | DOC: add example for ma.unique function
| * | | | | | | | | | BUG: Import ``numpy.ma`` at beginning of examples.Charles Harris2022-09-171-0/+1
| | | | | | | | | | |
| * | | | | | | | | | DOC: add example for ma.unique functionswagatip2022-09-161-0/+25
| |/ / / / / / / / /
* | | | | | | | | | DOC: Update notes with API linkBrigitta Sipőcz2022-09-161-84/+138
| | | | | | | | | |
* | | | | | | | | | DOC: clarify docs that inform that one should use a GeneratorMonika Kubek2022-09-161-42/+42
| | | | | | | | | |
* | | | | | | | | | DOC: Add example for findYunika Bajracharya2022-09-161-0/+6
|/ / / / / / / / /
* | | | | | | | | Merge pull request #22240 from sterrettm2/SVMLMatti Picus2022-09-135-2/+108
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | ENH: Use SVML for fp32 and fp64 power and arctan2
| * | | | | | | | | Fixed linter errorsMatthew Sterrett2022-09-091-4/+5
| | | | | | | | | |
| * | | | | | | | | TST: Adds some tests for power involving infinitiesMatthew Sterrett2022-09-091-0/+7
| | | | | | | | | |
| * | | | | | | | | ENH: Added support for SVML vectorization of power and arctan2Matthew Sterrett2022-09-094-2/+100
| | | | | | | | | |
* | | | | | | | | | TST: Move new `asarray` test to a more appropriate place. (#22251)M. Eric Irrgang2022-09-132-66/+68
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As noted at #21995 (comment), the new test from #21995 was placed in a directory intended for the Array API, and unrelated to the change. * Consolidate test_dtype_identity into an existing test file. Remove `test_asarray.py`. Create a new `TestAsArray` suite in `test_array_coercion.py` * Linting. Wrap some comments that got too long after function became a method (with additional indentation).
* | | | | | | | | | DOC: Update concatenate exception message.Ross Barnowski2022-09-122-2/+2
| |/ / / / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add missing word to correct exception message when concatenate axes don't match.
* | | | | | | | | MAINT: random: remove `get_info` from "extending with Cython" exampleRalf Gommers2022-09-111-6/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | xref gh-21431
* | | | | | | | | BLD: add back stdlib.h include in pcg64.hChristoph Reiter2022-09-111-1/+4
|/ / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This seems to have been removed by accident in #21887 stdlib.h is required for _rotr64() further down. Fixes: error: call to undeclared function '_rotr64'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
* | | | | | | | Merge pull request #22228 from bsipocz/ma_cleanup_old_deprecationsSebastian Berg2022-09-092-87/+2
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | MAINT: Remove long deprecated functionality from np.ma
| * | | | | | | | Remove long deprecated functionality from np.maBrigitta Sipőcz2022-09-082-87/+2
| | | | | | | | |
* | | | | | | | | BUG: Fix incorrect refcounting in new `asarray` pathSebastian Berg2022-09-091-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The new path to preserve dtypes provided by creating a view got the reference counting wrong, because it also hit the incref path that was needed for returning the identity. This fixes up gh-21995 Closes gh-22233
* | | | | | | | | Merge pull request #21507 from ganesh-k13/bug_div_overflowSebastian Berg2022-09-083-37/+282
|\ \ \ \ \ \ \ \ \ | |/ / / / / / / / |/| | | | | | | | BUG: Better report integer division overflow
| * | | | | | | | TST: Add unsigned integers to integer divide-by-zero testSebastian Berg2022-07-061-1/+1
| | | | | | | | |
| * | | | | | | | MAINT: Remove nested NPY_UNLIKELY in division pathsSebastian Berg2022-07-061-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I am not certain the unlikely cases make much sense to begin with, but they are certainly not helpful within an unlikely block.
| * | | | | | | | TST: Add additional tests for division-by-zero and integer overflowSebastian Berg2022-07-061-4/+104
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This introduces a helper to iterate through "interesting" array cases that could maybe be used in other places. Keep the other test intact, it adds a check for mixed types (which is just casts currently, but cannot hurt) and is otherwise thorough.
| * | | | | | | | TST: Changed `raise` to `warns`ganesh-k132022-07-011-7/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Changed `raise` to `warns` and test for `RuntimeWarning` * Added results check back
| * | | | | | | | TST: Removed eval | Fixed raises casesganesh-k132022-07-011-22/+26
| | | | | | | | |
| * | | | | | | | SIMD: Removed cvtozeroganesh-k132022-07-011-6/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Co-authored-by: Rafael Cardoso Fernandes Sousa <rafaelcfsousa@ibm.com>
| * | | | | | | | TST: New tests for overflow in division operationsganesh-k132022-07-011-0/+79
| | | | | | | | |
| * | | | | | | | BUG, SIMD: Handle overflow errorsganesh-k132022-07-012-32/+84
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Overflows for remainder/divmod/fmod * If a types minimum value is divided by -1, an overflow will be raised and result will be set to minimum * Handle overflow and return 0 in case of mod related operations
* | | | | | | | | Merge pull request #21995 from eirrgang/mei-1468Matti Picus2022-09-073-3/+86
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | BUG: Distinguish exact vs. equivalent dtype for C type aliases.
| * | | | | | | | | Add release note and further clarify tests.M. Eric Irrgang2022-07-171-12/+31
| | | | | | | | | |
| * | | | | | | | | Lint.M. Eric Irrgang2022-07-171-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Shorten some lines.
| * | | | | | | | | Expand test_asarray.py.M. Eric Irrgang2022-07-171-13/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Improve comments/docs. * Improve descriptiveness of variable names. * Add additional test expressions that would not pass without this patch.
| * | | | | | | | | Update comment and obey formatting requirements.M. Eric Irrgang2022-07-161-2/+2
| | | | | | | | | |