<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/python-packages/numpy.git/numpy/core/_internal.py, branch meson</title>
<subtitle>github.com: numpy/numpy.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/python-packages/numpy.git/'/>
<entry>
<title>PERF: Eliminate slow check for pypy during numpy import (#22163)</title>
<updated>2022-08-23T06:55:56+00:00</updated>
<author>
<name>Pieter Eendebak</name>
<email>pieter.eendebak@gmail.com</email>
</author>
<published>2022-08-23T06:55:56+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/python-packages/numpy.git/commit/?id=acdd0e3ffff0db9f45951c6b51887937ca31935e'/>
<id>acdd0e3ffff0db9f45951c6b51887937ca31935e</id>
<content type='text'>
This PR replaces the import of platform and a call to platform.python_implementation() with a check using sys.implementation.name to improve the numpy import time. The improvement is about 5-10 ms (system dependent).

Also see #22061

Co-authored-by: Matti Picus &lt;matti.picus@gmail.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This PR replaces the import of platform and a call to platform.python_implementation() with a check using sys.implementation.name to improve the numpy import time. The improvement is about 5-10 ms (system dependent).

Also see #22061

Co-authored-by: Matti Picus &lt;matti.picus@gmail.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>MAINT,ENH: Adjust metadata preservation, preserving it for identical structured dtypes</title>
<updated>2022-05-09T15:13:13+00:00</updated>
<author>
<name>Sebastian Berg</name>
<email>sebastian@sipsolutions.net</email>
</author>
<published>2022-05-05T11:11:40+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/python-packages/numpy.git/commit/?id=59b7afee1fa088760233060297172df6da3bde63'/>
<id>59b7afee1fa088760233060297172df6da3bde63</id>
<content type='text'>
Identical means here that the promotion is between the same dtype *and* promoting it
does not modify any of the included dtypes *and* does not modify the offset layout
or itemsize.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Identical means here that the promotion is between the same dtype *and* promoting it
does not modify any of the included dtypes *and* does not modify the offset layout
or itemsize.
</pre>
</div>
</content>
</entry>
<entry>
<title>API: Fix structured dtype cast-safety, promotion, and comparison</title>
<updated>2022-05-09T15:13:13+00:00</updated>
<author>
<name>Sebastian Berg</name>
<email>sebastian@sipsolutions.net</email>
</author>
<published>2021-06-11T23:21:54+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/python-packages/numpy.git/commit/?id=a0c2e826738daa0cbd83aba85852405b73878f5b'/>
<id>a0c2e826738daa0cbd83aba85852405b73878f5b</id>
<content type='text'>
This PR replaces the old gh-15509 implementing proper type promotion
for structured voids.  It further fixes the casting safety to consider
casts with equivalent field number and matching order as "safe"
and if the names, titles, and offsets match as "equiv".

The change perculates into the void comparison, and since it fixes
the order, it removes the current FutureWarning there as well.

This addresses https://github.com/liberfa/pyerfa/issues/77
and replaces gh-15509 (the implementation has changed too much).

Fixes gh-15494  (and probably a few more)

Co-authored-by: Allan Haldane &lt;allan.haldane@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This PR replaces the old gh-15509 implementing proper type promotion
for structured voids.  It further fixes the casting safety to consider
casts with equivalent field number and matching order as "safe"
and if the names, titles, and offsets match as "equiv".

The change perculates into the void comparison, and since it fixes
the order, it removes the current FutureWarning there as well.

This addresses https://github.com/liberfa/pyerfa/issues/77
and replaces gh-15509 (the implementation has changed too much).

Fixes gh-15494  (and probably a few more)

Co-authored-by: Allan Haldane &lt;allan.haldane@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>PERF: Avoid using `@recursive`.</title>
<updated>2021-08-03T18:37:57+00:00</updated>
<author>
<name>Antony Lee</name>
<email>anntzer.lee@gmail.com</email>
</author>
<published>2021-08-02T18:37:30+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/python-packages/numpy.git/commit/?id=557bb33ff71c6aae64a85e58d2b78b2c8877a0f5'/>
<id>557bb33ff71c6aae64a85e58d2b78b2c8877a0f5</id>
<content type='text'>
None of the functions decorated with `@recursive` actually need to close
over internal variables, so they can be lifted to become toplevel
recursive functions which avoid the need for an `@recursive` decorator.
(No change was made to the logic of any of the functions.)

As it turns out, the `@recursive` decorator adds a lot of overhead:
`python runtests.py --bench bench_io` reports a ~15-20% perf gain(!)
for `loadtxt` from this PR.  (`_recursive_mask_or` seems less likely to
matter performance-wise, but I also lifted it out for good measure...
and just deleted the decorator's implementation.)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
None of the functions decorated with `@recursive` actually need to close
over internal variables, so they can be lifted to become toplevel
recursive functions which avoid the need for an `@recursive` decorator.
(No change was made to the logic of any of the functions.)

As it turns out, the `@recursive` decorator adds a lot of overhead:
`python runtests.py --bench bench_io` reports a ~15-20% perf gain(!)
for `loadtxt` from this PR.  (`_recursive_mask_or` seems less likely to
matter performance-wise, but I also lifted it out for good measure...
and just deleted the decorator's implementation.)
</pre>
</div>
</content>
</entry>
<entry>
<title>DOC: Add documentation for `np.ctypeslib.c_intp`</title>
<updated>2021-06-22T15:55:35+00:00</updated>
<author>
<name>Bas van Beek</name>
<email>b.f.van.beek@vu.nl</email>
</author>
<published>2021-06-22T15:26:41+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/python-packages/numpy.git/commit/?id=a42f9a23a2c7957f20347df4b131c4c9bc2f340d'/>
<id>a42f9a23a2c7957f20347df4b131c4c9bc2f340d</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>DOC: Add the `axis` and `axes` keywords to gufunc signatures</title>
<updated>2021-05-20T15:05:14+00:00</updated>
<author>
<name>Bas van Beek</name>
<email>b.f.van.beek@vu.nl</email>
</author>
<published>2021-05-20T14:51:05+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/python-packages/numpy.git/commit/?id=81f528ae968830fc837543b2741786ba699a2d3c'/>
<id>81f528ae968830fc837543b2741786ba699a2d3c</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>DEP: Deprecate 4 `ndarray.ctypes` methods (#19031)</title>
<updated>2021-05-18T20:53:29+00:00</updated>
<author>
<name>Bas van Beek</name>
<email>43369155+BvB93@users.noreply.github.com</email>
</author>
<published>2021-05-18T20:53:29+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/python-packages/numpy.git/commit/?id=39110f34ebc5e445ebea59833e621e4404c38be4'/>
<id>39110f34ebc5e445ebea59833e621e4404c38be4</id>
<content type='text'>
* DEP: Deprecate 4 `ndarray.ctypes` methods

* `get_data`
* `get_shape`
* `get_strides`
* `get_as_parameter`

* TST: Add deprecation tests for 4 `ndarray.ctypes` methods

* DOC: Add a release note for the `ndarray.ctypes` method deprecation

* MAINT: Deprecate via `__getattr__` instead of `__getattribute__

Co-Authored-By: Sebastian Berg &lt;sebastian@sipsolutions.net&gt;

* MAINT: Deprecate the methods via proper function definitions

Co-Authored-By: Eric Wieser &lt;425260+eric-wieser@users.noreply.github.com&gt;

* DOC: Added a missing "the"

* DOC: typo fix: property -&gt; properties

Co-Authored-By: Eric Wieser &lt;425260+eric-wieser@users.noreply.github.com&gt;

Co-authored-by: Sebastian Berg &lt;sebastian@sipsolutions.net&gt;
Co-authored-by: Eric Wieser &lt;425260+eric-wieser@users.noreply.github.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* DEP: Deprecate 4 `ndarray.ctypes` methods

* `get_data`
* `get_shape`
* `get_strides`
* `get_as_parameter`

* TST: Add deprecation tests for 4 `ndarray.ctypes` methods

* DOC: Add a release note for the `ndarray.ctypes` method deprecation

* MAINT: Deprecate via `__getattr__` instead of `__getattribute__

Co-Authored-By: Sebastian Berg &lt;sebastian@sipsolutions.net&gt;

* MAINT: Deprecate the methods via proper function definitions

Co-Authored-By: Eric Wieser &lt;425260+eric-wieser@users.noreply.github.com&gt;

* DOC: Added a missing "the"

* DOC: typo fix: property -&gt; properties

Co-Authored-By: Eric Wieser &lt;425260+eric-wieser@users.noreply.github.com&gt;

Co-authored-by: Sebastian Berg &lt;sebastian@sipsolutions.net&gt;
Co-authored-by: Eric Wieser &lt;425260+eric-wieser@users.noreply.github.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>STY: core._internal</title>
<updated>2020-08-11T08:31:11+00:00</updated>
<author>
<name>danielhrisca</name>
<email>daniel.hrisca@gmail.com</email>
</author>
<published>2020-08-11T08:28:38+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/python-packages/numpy.git/commit/?id=49eaea7184cf524ff21ca9d88e806247577be543'/>
<id>49eaea7184cf524ff21ca9d88e806247577be543</id>
<content type='text'>
* removed redundant parenthesis
* use f-strings
* use dict.items in _makenames_list
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* removed redundant parenthesis
* use f-strings
* use dict.items in _makenames_list
</pre>
</div>
</content>
</entry>
<entry>
<title>MAINT: Chaining exceptions in numpy/core/_internal.py</title>
<updated>2020-07-04T09:38:54+00:00</updated>
<author>
<name>tabhi0797</name>
<email>abhinav071197@gmail.com</email>
</author>
<published>2020-07-04T09:38:54+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/python-packages/numpy.git/commit/?id=f808a633c671bcac8aa57dd0409a7dccdf72c5ff'/>
<id>f808a633c671bcac8aa57dd0409a7dccdf72c5ff</id>
<content type='text'>
- chaining exceptions from None
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- chaining exceptions from None
</pre>
</div>
</content>
</entry>
<entry>
<title>MAINT: Chaining exceptions in numpy/core/_internal.py</title>
<updated>2020-07-04T06:36:51+00:00</updated>
<author>
<name>tabhi0797</name>
<email>abhinav071197@gmail.com</email>
</author>
<published>2020-07-04T06:36:51+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/python-packages/numpy.git/commit/?id=0cd387c6513f2b5b514898c3a06947af7dd919dc'/>
<id>0cd387c6513f2b5b514898c3a06947af7dd919dc</id>
<content type='text'>
- updated %formatted string to f strings
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- updated %formatted string to f strings
</pre>
</div>
</content>
</entry>
</feed>
