Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

FIX: remove __array__ method on BasicUnit#28744

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
tacaswell wants to merge3 commits intomatplotlib:main
base:main
Choose a base branch
Loading
fromtacaswell:np21_unit_example

Conversation

tacaswell
Copy link
Member

The presence of this method causes the numpy floatmul to use it in numpy 2.1 which results in the units not being tagged as expected and the example failing.

PR summary

PR checklist

The presence of this method causes the numpy float __mul__ to use itin numpy 2.1 which results in the units not being tagged as expected andthe example failing.
@tacaswelltacaswell added this to thev3.9-doc milestoneAug 21, 2024
@github-actionsgithub-actionsbot added the Documentation: examplesfiles in galleries/examples labelAug 21, 2024
@tacaswell
Copy link
MemberAuthor

Sorry, I did this a while ago but forgot to actually open the PR!

Copy link
Member

@QuLogicQuLogic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

This breaks the docs with NumPy 2.0.1.

@QuLogic
Copy link
Member

QuLogic commentedAug 21, 2024
edited
Loading

So the bisect points this tonumpy/numpy@682cd04 vianumpy/numpy#26904.

Reading through the array API docs, it seems like setting__array_priority__ higher (default is 0) may also work, in order to ensure that our__array_wrap__ method is called regardless of version, and we don't end up with a bare array. Alternatively, we could implement__array_ufunc and/or__array_function__.

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@QuLogicQuLogicQuLogic requested changes

@timhoffmtimhoffmtimhoffm approved these changes

Requested changes must be addressed to merge this pull request.

Assignees
No one assigned
Labels
Projects
None yet
Milestone
v3.10-doc
Development

Successfully merging this pull request may close these issues.

4 participants
@tacaswell@QuLogic@timhoffm@ksunden

[8]ページ先頭

©2009-2025 Movatter.jp