| Commit message (Collapse) | Author | Age | Files | Lines |
|\
| |
| | |
BUG: Make iscomplexobj compatible with custom dtypes again
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This change makes iscomplexobj compatible with custom array types
using custom dtypes, that are not fully compatible to Numpys dtypes,
which can nevertheless be coerced to a numpy array with asarray
again, as has been the behaviour before PR #7936.
Fixes #8601
|
|/
|
|
| |
Fixes #8588
|
|\
| |
| | |
MAINT: Remove __setslice__ and __getslice__
|
| |
| |
| |
| |
| | |
This code was only here for Python 2.5 compatibility, but numpy requires 2.7
at minimum
|
|\ \
| | |
| | | |
DOC: fix several typos #8537.
|
| |/
| |
| |
| | |
[ci skip]
|
| |
| |
| |
| |
| |
| |
| | |
Make sure that value shapes and dtypes are the same as the original
calculated values from the MachAr class.
Closes #8585
|
|/
|
|
|
|
|
|
|
| |
representation size
This is for PyPy3 compatibility: sys.getsizeof() is CPython-specific and
there doesn't seem to be a pure-Python way of getting the size of the
internal PEP393 Unicode representation, so recompute it using documented
invariants.
|
|\
| |
| | |
BUG: fix calling python api with error set and minor leaks
|
| | |
|
| |
| |
| |
| | |
unnecessary since gh-8416
|
| | |
|
| |
| |
| |
| | |
Now we have eps on PPC longdouble, re-enable the tests of float spacing.
|
| |
| |
| |
| |
| |
| | |
On SPARC, longdouble alignment is bigger than that provided by default
allocation. So use a custom allocation method in the test using
dot(out=).
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
* ENH: hard-code finfo parameters for known types
Hard-code the MachAr parameters for float64, float32, 80-bit extended
precision, to save time, and provide skeleton for more difficult types
such as the double double on PPC; see
https://github.com/numpy/numpy/issues/2669
* ENH: add PPC long double finfo
Add parameters for PPC long double, fixing long-standing bug for finfo
on PPC.
* BF: use Python floats for float64 finfo
For some reason (garrgh) np.exp2 with float64 gives a different answer on
Windows than it does on other platforms; use Python floating point
calculations instead, which do appear to be consistent.
* DOC: add release notes for finfo fixes
Add release note describing fixes for PPC long double ``finfo``.
* RF: try using byte string to identify floats
From suggestion by Chuck, and
https//perl5.git.perl.org/perl.git/blob/3118d7d684b56cbeb702af874f4326683c45f045:/Configure
* TST: add tests for reasonable finfo parameters
Check that finfo returns somewhat reasonable parameters for all floating
point types.
* RF: add warning for not-recognized float type
Warn if we don't have a signature for the float type.
* NF: add IEEE float128 type signature
Still needs test on platform with IEEE float128, to check MachAr-like
parameters are correct.
|
| |
| |
| |
| |
| |
| | |
* documenting behaviour of passing `None` to upper or lower interval bounds in `clip()`
* doc: specifying that not more than one of formal parameters `a_min` and `a_max` may be none
|
|\ \
| | |
| | | |
Fixing docstring error in polyvander2d
|
| | |
| | |
| | |
| | |
| | |
| | | |
- Fixes documentation of polynomial types `*vander2d()` methods to give the
correct last index of the pseudo-Vandermonde matrix returned expressed in
terms of x and y.
|
| | | |
|
|/ /
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Without this commit, after an operation like
```
a = np.ma.MaskedArray([1., 2., 3.])
b = np.add(a, 1., out=a)
```
one would have `b is not a`. With this PR, it is guaranteed that
`b is a`.
|
|\ \
| | |
| | | |
DOC: Missing backticks
|
| | | |
|
| | |
| | |
| | | |
Came across this in the online docs
|
|\ \ \
| |/ /
|/| | |
BUG: Fix loss of dimensionality of np.ma.masked in ufunc
|
| | |
| | |
| | |
| | | |
Fixes #8505
|
|\ \ \
| | | |
| | | | |
BUG: core: in dot(), make copies if out has memory overlap with input
|
| | | | |
|
| | | | |
|
| | | | |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
BLAS does not allow aliased inputs. If user-provided out= argument may
overlap in memory with one of the inputs to dot(), put the output to a
temporary work array and copy back after the operation.
|
|\ \ \ \
| | | | |
| | | | | |
BUG: guard against replacing constants without '_' spec
|
| | | | |
| | | | |
| | | | |
| | | | | |
per request from @charris
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
This augments the test in constant_compound.f90 by
using constants without a compound kind spec to
illustrate the case that led to the
reporting of issue #8493
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
This is a test code provided as a patch by @zerothi checking
the compound constant parsing.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
fixes #8493
In the reported problem snippet the attempt to infer the type of
parameter (wasize=maxiterates*2)
leads to a lookup of maxiterates in the logic of get_parameters
which finds and correctly assigns to 'v' the value string '50000'
However, then in the logic proceds to attempt to split off any
underscore-appended precision spec from v_ which yields ['50000']
because there is no underscore.
Finally line
v = ''.join(v_[:-1]).lower().replace(v_[-1].lower(), '')
if not quarded by the newly introduced lengthtest sets v to empty
because [:-1] of a list with one element yields an empty list.
Subsequently the type inference by running eval on an empty string
fails with the error message quoted.
The introduced length check appears to correct this problem.
|
| |/ / /
|/| | |
| | | | |
"it's arguments" should be "its arguments"
|
|\ \ \ \
| | |_|/
| |/| | |
BUG: fix mean for float 16 non-array inputs
|
| | | | |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Previously `bool(dtype(...))` would fallback to the default
implementation of `__nonzero__`, which checks if `len(object) > 0`.
Since `dtype` objects implement `__len__` as the number of record
fields, `bool` of scalar dtypes like `bool(dtype('i8'))` would evaluate
as `False`. This fixes that by implementing `__nonzero__` to always
return True.
Fixes #6294.
|
| | | |
| | | |
| | | | |
MAINT: Fix building extensions with MinGW in WinPython 3.4
|
|\ \ \ \
| | | | |
| | | | | |
ENH: Vectorize packbits with SSE2
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Uses 2KiB of space, but makes unpack bits 8 times faster and comparable
with the vectorized packbits.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
SSE2 has a special instruction to pack bytes into bits,
available as the intrinsic _mm_movemask_epi8. It is significantly faster
than the per byte loop currently being used.
Unfortunately packbits is bitwise "big endian", the most significant bit
is the first in the input byte while _mm_movemask_epi is little endian
so we need to byteswap the input first. But it is still about 8-10 times
faster than the scalar code.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Larger data to account for future vectorization.
Also add benchmarks for packbits and unpackbits
|
| |_|_|/
|/| | | |
|
|\ \ \ \
| | | | |
| | | | | |
BUG: Prevent crash for length-0 input to fromrecords
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
This fixes:
* The case when len(recList) == 0 and dtype is not None
* The case when np.ndim(recList) > 1
In both cases, this would previously IndexError
|
|\ \ \ \ \
| |_|_|_|/
|/| | | | |
DOC: Add example to np.savez_compressed
|
| | | | | |
|