| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
Bumps [cython](https://github.com/cython/cython) from 0.29.15 to 0.29.16.
- [Release notes](https://github.com/cython/cython/releases)
- [Changelog](https://github.com/cython/cython/blob/master/CHANGES.rst)
- [Commits](https://github.com/cython/cython/compare/0.29.15...0.29.16)
Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
|
|
|
|
| |
* DOC: fix traceback message to pass refguide_check
* DOC, TST: add refguide_check to circleci
|
|\
| |
| | |
DOC: Fix docstring for _hist_bin_auto.
|
|/
|
|
|
| |
* "bandwidth" -> "bin width"
* Minor grammatical fixes
|
|\
| |
| | |
DOC: First steps towards docs restructuring (NEP 44)
|
| | |
|
|\ \
| | |
| | | |
DOC: fix typo in C-API reference
|
|/ / |
|
|\ \
| | |
| | | |
BUG: Fix IndexError for illegal axis in np.mean
|
| |/
| |
| |
| |
| | |
Catch IndexError in _count_reduce_items used in np.mean and np.var for
illegal axis and reraise as AxisError, see gh-15817.
|
| |
| |
| |
| |
| | |
* DOC: skip f2py fortran and arrays.nditer cython tests for refguide_check
* DOC: fix formatting of doc tests and improper use of nditer
|
| |
| |
| |
| |
| | |
types (#15816)
Cleanup from the dropping of python 2
|
|\ \
| | |
| | | |
BUG: don't add 'public' or 'private' if the other one exists
|
| | |
| | |
| | |
| | |
| | |
| | | |
Currently, setting 'public' or 'private' attribute is adding
one even if the other one already exists because of the else:
part that is always appending.
|
| |/
|/|
| |
| |
| | |
* ENH: improved error message when the dimension of index is larger than the dimension of array, fixed issue #15321
Author: Yilin Li <yilin.lasia@gmail.com>
Co-Authored-By: Eric Wieser <wieser.eric@gmail.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Currently, when writing something like
```
pd.DataFrame({'arr': np.array(1., 2., 3.)})
```
```
ValueError Traceback (most recent call last)
<ipython-input-1-ffdb00ae9b74> in <module>()
1 import numpy as np
2 import pandas as pd
----> 3 pd.DataFrame({'arr': np.array(1., 2., 3.)})
ValueError: only 2 non-keyword arguments accepted
```
This stack trace that doesn't include a frame for the np constructor, because the constructor is generated python code. This may lead users to look elsewhere for the issuer of the ValueError, which may create red-herrings in that folks may look elsewhere.
This changes makes it more obvious where the error is coming from.
* reflects eric-wieser's suggestion about common error messages
* Documents required non-keyword args for np.array
* Update numpy/core/src/multiarray/multiarraymodule.c
Co-Authored-By: Eric Wieser <wieser.eric@gmail.com>
* Update numpy/core/src/multiarray/multiarraymodule.c
Co-Authored-By: Eric Wieser <wieser.eric@gmail.com>
* Update numpy/core/src/multiarray/multiarraymodule.c
Co-Authored-By: Eric Wieser <wieser.eric@gmail.com>
* Update multiarraymodule.c
Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
|
| |
| |
| |
| |
| |
| |
| |
| | |
This expires a deprecation from 1.8.
The corresponding deprecation in `np.insert` has less clear semantics, so has been left to a future patch.
Co-authored-by: Sebastian Berg <sebastian@sipsolutions.net>
Co-authored-by: Warren Weckesser <warren.weckesser@gmail.com>
|
|\ \
| | |
| | | |
TST: Add unit test for out=None of np.einsum
|
| | |
| | |
| | |
| | |
| | | |
Ensure that explicitly stating out=None does not raise an error in
np.einsum, see #15776 and #15256.
|
| | |
| | |
| | |
| | | |
Errors raised when casting some strided arrays are not caught.
See gh-15790.
|
|\ \ \
| | | |
| | | | |
MAINT: pathlib and hashlib are in stdlib in Python 3.5+
|
| | | | |
|
| | | | |
|
|/ / /
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Fix and test conversion of masked element to string in fstring / string interpolation. See PEP 498 for string interpolation (aka fstrings) in Python 3.6 and above.
Fixes #15409.
Original PR gh-15410 by: Stefan Codrescu <ssmmcc1@gmail.com>
Co-authored-by: Stefan Codrescu <ssmmcc1@gmail.com>
Co-authored-by: Stefan <5tefan@users.noreply.github.com>
Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
Co-authored-by: Sebastian Berg <sebastian@sipsolutions.net>
|
|\ \ \
| | | |
| | | | |
BUG: Add error-checking versions of strided casts.
|
| | | |
| | | |
| | | |
| | | | |
Closed gh-15790.
|
| | | |
| | | |
| | | |
| | | |
| | | | |
Errors raised when casting some strided arrays are not caught.
See gh-15790.
|
| | |/
| |/| |
|
|\ \ \
| | | |
| | | | |
DEP: Make `np.insert` and `np.delete` on 0d arrays with an axis an error
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Before this change, the following code worked:
```
>>> some_0d = np.array(1)
>>> np.insert(some_0d, "some nonsense", 10, axis=0)
array(10)
>>> np.insert(some_0d, "some nonsense", 42, axis="some nonsense")
array(42)
```
Now these raise AxisError and TypeError, respectively.
`delete` is exactly the same.
|
|\ \ \ \
| | | | |
| | | | | |
TST: Remove code that is not supposed to warn out of warning assertion
|
| | | | | |
|
|\ \ \ \ \
| |/ / / /
| | | | | |
DEP: Make np.delete on out-of-bounds indices an error
|
| |/ / /
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Note that this only affects lists of indices.
```python
>>> a = np.arange(3)
````
Before:
```python
>>> np.delete(a, 100)
IndexError
>>> np.delete(a, [100])
DeprecationWarning
array([0, 1, 2])
>>> np.delete(a, -1)
array([0, 1])
>>> np.delete(a, [-1])
FutureWarning
array([0, 1, 2])
```
After:
```python
>>> np.delete(a, 100)
IndexError
>>> np.delete(a, [100])
IndexError
>>> np.delete(a, -1)
array([0, 1])
>>> np.delete(a, [-1])
array([0, 1])
```
|
|\ \ \ \
| | | | |
| | | | | |
DEP: Forbid passing non-integral index arrays to `insert` and `delete`
|
| |/ / /
| | | |
| | | |
| | | | |
This expires a deprecation warning from back in 1.9.
|
| | | | |
|
|\ \ \ \
| | | | |
| | | | | |
DOC: correct possible list lengths for `extobj` in ufunc calls
|
|/ / / /
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
According to the docs, the list can be of lengths 1, 2, or 3, but only
length 3 appears to work:
```
>>> import numpy as np
>>> np.sin(1, extobj=[16, 1, lambda: None])
0.8414709848078965
>>> np.sin(1, extobj=[16, 1])
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: UFUNC_PYVALS must be a length 3 list.
>>> np.sin(1, extobj=[16])
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: UFUNC_PYVALS must be a length 3 list.
```
|
|\ \ \ \
| |/ / /
| | | /
| |_|/
|/| | |
MAINT: Cleanups to np.insert and np.delete
|
| | |
| | |
| | |
| | | |
No behavior change here unless someone implements a subclass where `arr.ravel().ndim == 0`, which no sane person would do anyway.
|
| | | |
|
| | | |
|
| | | |
|
| |/
|/|
| |
| |
| |
| |
| |
| |
| |
| | |
This finishes the deprecation started in gh-9505 removing
behaviour that allowed strings/types representing specific dtypes
to behave like their more generic supertypes (e.g. the python
float would map to floating instead of float64 which it typically
maps to).
Co-Authored-By: Eric Wieser <wieser.eric@gmail.com>
|
| |
| |
| | |
* BLD: Added doc_requirements.txt and improve documentation around building docs
|
| |
| |
| | |
* BUG, TST: fix f2py for PyPy, skip one test for PyPy, xfail tests for s390x
|
|/
|
|
|
|
|
|
|
|
|
| |
(#15736)
Currently, in function array_shape_set, ndarray's pointers to dimensions and strides are freed before new array is allocated (Line 71). In case memory error occur, the array is left with dangling pointers. Therefore, we can not recover from such error.
* To guarantee array in valid state when memory error occur
* Fix: Free cache when nd == 0 to avoid memory leak
* Update numpy/core/src/multiarray/getset.c
Co-Authored-By: Eric Wieser <wieser.eric@gmail.com>
|
|\
| |
| | |
MAINT: remove useless `global` statements
|
| |
| |
| |
| |
| |
| |
| | |
`global` is only needed if a variable appears on the left of an assignment.
These variables do not.
Most suffer from the misconception that `var[x] = y` requires `var` to be global, but it does not.
|