Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace cfloat with complex128. Modify version constraints on numpy #343

Merged
merged 1 commit into from
Jul 2, 2024

Conversation

toru4838
Copy link
Contributor

@toru4838 toru4838 commented Jul 2, 2024

numpy.cfloat has been removed in the latest numpy (2.0.0), which was released on Jun 16, 2024.
This PR fixes the issue of getting the error ImportError: cannot import name 'cfloat' from 'numpy'.

  • Replaced numpy.cfloat with numpy.complex128
  • Modified the numpy version constraints to exclude 2.0.0 or later

numpy 2.0.0 release note:
https://numpy.org/doc/stable/release/2.0.0-notes.html

Alias np.cfloat has been removed. Use np.complex128 instead.

@toru4838 toru4838 requested a review from dchung0741 July 2, 2024 03:13
Copy link

github-actions bot commented Jul 2, 2024

@github-actions github-actions bot temporarily deployed to pull request July 2, 2024 03:17 Inactive
Copy link
Contributor

@dchung0741 dchung0741 left a comment

Choose a reason for hiding this comment

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

Looks good to me.
Thank you!

@dchung0741 dchung0741 merged commit 62982f8 into main Jul 2, 2024
9 checks passed
@dchung0741 dchung0741 deleted the expired_numpy_cfloat branch July 2, 2024 03:45
@github-actions github-actions bot locked and limited conversation to collaborators Jul 2, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants