| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Fixes GH3290
With apologies to mwiebe, this rips out most of the time zone parsing from
the datetime64 type.
I think we mostly sorted out the API design in discussions last year, but
I'll be posting this to the mailing list shortly to get feedback.
Old behavior:
# string parsing and printing defaults to your local timezone :(
>>> np.datetime64('2000-01-01T00')
numpy.datetime64('2000-01-01T00:00-0800','h')
New behavior:
# datetime64 is parsed and printed as timezone naive
>>> np.datetime64('2000-01-01T00')
numpy.datetime64('2000-01-01T00','h')
# you can still supply a timezone, but you get a deprecation warning
>>> np.datetime64('2000-01-01T00Z')
DeprecationWarning: parsing timezone aware datetimes is deprecated; this
will raise an error in the future
numpy.datetime64('2000-01-01T00','h')
|
| | | | | |
|
|\ \ \ \ \
| |_|/ / /
|/| | | | |
STY: Wrap some long lines in `cblasfuncs.c`
|
| | | | | |
|
|\ \ \ \ \
| | | | | |
| | | | | | |
Cleanup 6699, BUG: fix issues with signed zeros in scalar math complex division.
|
| |/ / / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
The current algorithm used in scalar math complex division appears to
incorrectly handle signed zeros. This patch duplicates the algorithm
used for complex division in the loops.c.src file into the
scalarmath.c.src file so the algorithms are consistent regardless of
context. Unit tests are added in the scalar context for testing the
correctness of sign when zeros are encountered and also to trip the new
branches in the now consistent algorithm.
|
|\ \ \ \ \
| |/ / / /
|/| | | | |
BUG: Fix divmod
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
This is apropos #6127. The fix is to make the functions floor_division
and remainder consistent, i.e.,
b * floor_division(a, b) + remainder(a, b) == a
Previous to this fix remainder was computed a the C level using the '%'
operator, and the result was not always consistent with the floor
function. The current approach is to compute the remainder using
b * (a/b - floor(a/b))
which is both consistent with the Python '%' operator and numerically
consistent with floor_division implemented using the floor function.
Closes #6127.
|
|\ \ \ \ \
| | | | | |
| | | | | | |
Fix issue #7021
|
| | | | | | |
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
BLD: fix rebuilding after a failed build. Closes gh-5467.
|
| |/ / / / /
| | | | | |
| | | | | |
| | | | | | |
Also remove bench(), does't do anything here after the move to asv.
|
|\ \ \ \ \ \
| |/ / / / /
|/| | | | | |
BLD: build improvements (enable setuptools)
|
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Addresses comments of @pv on gh-6895.
|
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Implements idea suggested in gh-6431.
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
This was triggered by the numpy version string (which is unicde)
being included in metadata. This could also solve other problems
for external users of numpy.distutils.
|
|\ \ \ \ \ \
| |/ / / / /
|/| | | | | |
DEP: Warn MaskedArray will return views of mask when sliced
|
| | | | | | |
|
| | |/ / /
| |/| | |
| | | | |
| | | | | |
behavior of `MaskedArray`'s masks is changing.
|
|\ \ \ \ \
| | | | | |
| | | | | | |
TST, MAINT: Make sure exceptions of `inner` and `dot` match for different cases
|
| |/ / / /
| | | | |
| | | | |
| | | | | |
case.
|
|\ \ \ \ \
| | | | | |
| | | | | | |
DOC, MAINT: Enforce np.ndarray arg for np.put and np.place
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
np.put and np.place do something only when the first argument
is an instance of np.ndarray. These changes will cause a TypeError
to be thrown in either function should that requirement not be
satisfied.
|
| |/ / / /
|/| | | | |
|
|\ \ \ \ \
| | | | | |
| | | | | | |
BUG: Enforce Order Param for MaskedArray Construction
|
| | |/ / /
| |/| | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Adds the 'order' parameter to the __new__ override
in MaskedArray construction, enabling it to be enforced
in methods like np.ma.core.array and np.ma.core.asarray.
Closes gh-6646.
|
|\ \ \ \ \
| |/ / / /
|/| | | | |
DOC: Clean up/fix several references to the "future" 1.10 release
|
| | | | |
| | | | |
| | | | |
| | | | | |
Fixes gh-7010
|
| |/ / /
|/| | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Now, NaT compares like NaN:
- NaT != NaT -> True
- NaT == NaT (and all other comparisons) -> False
We discussed this on the mailing list back in October:
https://mail.scipy.org/pipermail/numpy-discussion/2015-October/073968.html
|
|\ \ \ \
| | | | |
| | | | | |
BUG: fix casting rules for generic datetime64/timedelta64 dtypes
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Fixes GH6452
There are two types of datetime64/timedelta64 objects with generic times
units:
* NaT
* unit-less timedelta64 objects
Both of these should be safely castable to any more specific dtype. However,
more specific dtypes should not be safely castable to generic units.
Otherwise, the result of `np.datetime64('NaT')` or `np.timedelta(1)` is
entirely useless, because they can't be used in any arithmetic operations or
comparisons.
This is a regression from NumPy 1.9, where these sort of operations worked
because the default casting rules with ufuncs were less strict.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
I have found that there are two missing numbers in a sequence in the documentation.
http://docs.scipy.org/doc/numpy/user/misc.html#interfacing-to-c
It goes 1,2,3,5,7,8 with missing 4 and 6.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
empty strings are the default for the new rpath,
extra_compile_args and extra_link_args sections
|
|\ \ \ \ \
| |_|_|/ /
|/| | | |
| | | | |
| | | | | |
gerritholl/structured_multidim_masked_array_fillvalue
BUG/TST: Fix for #6723 including test: force fill_value.ndim==0
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Fix issue #6723. Given an exotic masked structured array, where one of
the fields has a multidimensional dtype, make sure that, when accessing
this field, the fill_value still makes sense. As it stands prior to this
commit, the fill_value will end up being multidimensional, possibly with
a shape incompatible with the mother array, which leads to broadcasting
errors in methods such as .filled(). This commit uses the first element
of this multidimensional fill value as the new fill value. When more
than one unique value existed in fill_value, a warning is issued.
Also add a test to verify that fill_value.ndim remains 0 after indexing.
|
|\ \ \ \ \
| | | | | |
| | | | | | |
BUG: Add more complex trig functions to glibc < 2.16 blacklist.
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Added functions are
- cacos
- cacosf
- cacosl
- cacosh
- cacoshf
- cacoshl
Closes #6063.
|
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
and calls `PyArray_MatrixProduct2`.
|
| | | | | | |
|
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
`PyObject_Repr`. Also, do a better job of handling any errors raised while constructing the error message.
|
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
common type.
|
| |_|_|/ /
|/| | | |
| | | | |
| | | | | |
common type.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
may return something else than one or zero and npy_bool is
unfortunately an int8 not a c99 bool
|
| | | | | |
|
|\ \ \ \ \
| | | | | |
| | | | | | |
ENH: vectorize isinf and isfinite
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
isfinite is especially valuable as its needed to verify inputs are
suitable for lapack.
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
ENH: moveaxis function
|
| | |/ / / /
| |/| | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Fixes GH2039
This function provides a much more intuitive interface than `np.rollaxis`,
which has a confusing behavior with the position of the `start` argument:
http://stackoverflow.com/questions/29891583/reason-why-numpy-rollaxis-is-so-confusing
It was independently suggested several times over the years after discussions
on the mailing list and GitHub (GH2039), but never made it into a pull request:
https://mail.scipy.org/pipermail/numpy-discussion/2010-September/052882.html
My version adds support for a sequence of axis arguments. I find this behavior
to be very useful. It is often more intuitive than supplying a list of
arguments to `transpose` and also nicely generalizes NumPy's existing axis
manipulation routines, e.g.,
def transpose(a, order=None):
if order is None:
order = reversed(range(a.ndim))
return moveaxes(a, order, range(a.ndim))
def swapaxes(a, axis1, axis2):
return moveaxes(a, [axis1, axis2], [axis2, axis1])
def rollaxis(a, axis, start=0):
if axis < start:
start -= 1
return moveaxes(a, axis, start)
|