Skip to content

fix: ⬆️ add compatibility for numpy>2.0 #1

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

Merged
merged 2 commits into from
Jan 14, 2025

Conversation

Wizard-one
Copy link
Contributor

In numpy>2.0 np.complex_ is deprcated please see namespace change

@ehabets
Copy link
Member

ehabets commented Jan 13, 2025

Thank you for the fix. The current requirements.txt file limits the numpy version to >=1.6 and <2.0. Can you please update the requirement file in this fix, too?

@ehabets ehabets requested a review from Copilot January 13, 2025 10:21
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot reviewed 1 out of 1 changed files in this pull request and generated no comments.

due to numpy>2.0 np.complex_ is deprcated
@Wizard-one
Copy link
Contributor Author

Sure, I updated requirements.txt.

@ehabets
Copy link
Member

ehabets commented Jan 13, 2025

The package cannot be successfully built yet. The function coherence_error() must also be updated (complex_ → complex128).

@Wizard-one
Copy link
Contributor Author

Ok, I have fixed all np.complex_ to np.complex128. I have also run the test and built the package locally using Python 3.11. I think there is no problem.

@ehabets ehabets merged commit ee5fb9c into audiolabs:main Jan 14, 2025
5 checks passed
@ehabets
Copy link
Member

ehabets commented Jan 14, 2025

The package can now be built using Python 3.8-3.12. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants