Skip to content

Can we upgrade NumPy version from 1.22 to 1.24 or more for Python 3.11? #835

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

Closed
4 tasks done
rinarakaki opened this issue Apr 24, 2023 · 3 comments
Closed
4 tasks done

Comments

@rinarakaki
Copy link

Expected behaviour

numpy==1.22 emits warning: RuntimeWarning: NumPy 1.22.0 may not yet support Python 3.11.

Actual behaviour

NumPy's Python 3.11 support begins from version 1.24.

Steps to reproduce

  • pip3 install opencv-python
Issue submission checklist
  • This is not a generic OpenCV usage question (looking for help for coding, other usage questions, homework etc.)
  • I have read the README of this repository and understand that this repository provides only an automated build toolchain for OpenCV Python packages (there is no actual OpenCV code here)
  • The issue is related to the build scripts in this repository, to the pre-built binaries or is a feature request (such as "please enable this additional dependency")
  • I'm using the latest version of opencv-python
@tomsweeting
Copy link
Contributor

@rnarkk I also encountered this issue today, but instead of installing via pip I was trying to build from source for Python 3.11 with gstreamer support.

I was able to compile by setting the required numpy version 1.24.3, so I have put in a small PR to fix the issue. If you urgently need this to work with Python 3.11, it is possible to clone the repo and build manually as I did by making the same changes.

@asmorkalov
Copy link
Collaborator

According to https://numpy.org/news/ 1.23 is minimal Numpy version that supports Python 3.11.

asmorkalov pushed a commit that referenced this issue May 31, 2023
Fix for issue #835

I encountered the same issue today. By updating to require numpy 1.24.3 I was about to build successfully for my environment (python 3.11.3 / macos ventura arm64 / gstreamer support enabled)
@asmorkalov
Copy link
Collaborator

Upgraded to 1.23.5 as minimal Numpy version for Python 3.11 in #839

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

No branches or pull requests

3 participants