diff --git a/.github/workflows/build_wheels_linux.yml b/.github/workflows/build_wheels_linux.yml
index ab377325..746395e4 100644
--- a/.github/workflows/build_wheels_linux.yml
+++ b/.github/workflows/build_wheels_linux.yml
@@ -27,7 +27,7 @@ jobs:
strategy:
fail-fast: false
matrix:
- python-version: ['3.6']
+ python-version: ['3.9']
platform: [x64]
with_contrib: [0, 1]
without_gui: [0, 1]
@@ -41,7 +41,7 @@ jobs:
MB_ML_VER: 2014
TRAVIS_BUILD_DIR: ${{ github.workspace }}
CONFIG_PATH: travis_config.sh
- DOCKER_IMAGE: quay.io/opencv-ci/opencv-python-manylinux2014-x86-64:20220824
+ DOCKER_IMAGE: quay.io/opencv-ci/opencv-python-manylinux2014-x86-64:20240524
USE_CCACHE: 0
UNICODE_WIDTH: 32
PLAT: x86_64
@@ -84,7 +84,7 @@ jobs:
strategy:
fail-fast: false
matrix:
- python-version: ['3.6', '3.7', '3.8', '3.9', '3.10']
+ python-version: ['3.7', '3.8', '3.9', '3.10', '3.11', '3.12']
platform: [x64]
with_contrib: [0, 1]
without_gui: [0, 1]
@@ -93,7 +93,7 @@ jobs:
ACTIONS_ALLOW_UNSECURE_COMMANDS: true
MB_PYTHON_VERSION: ${{ matrix.python-version }}
NP_TEST_DEP: numpy==1.19.4
- NP_TEST_DEP_LATEST: numpy==1.21.2
+ NP_TEST_DEP_LATEST: numpy==2.0.0
CONFIG_PATH: travis_config.sh
PLAT: x86_64
steps:
@@ -106,7 +106,7 @@ jobs:
submodules: true
fetch-depth: 0
- name: Setup Environment variables
- run: if [ "3.10" == "${{ matrix.python-version }}" ]; then echo "TEST_DEPENDS=$(echo $NP_TEST_DEP_LATEST)" >> $GITHUB_ENV; else echo "TEST_DEPENDS=$(echo $NP_TEST_DEP)" >> $GITHUB_ENV; fi
+ run: if [ "3.10" == "${{ matrix.python-version }}" -o "3.11" == "${{ matrix.python-version }}" -o "3.12" == "${{ matrix.python-version }}" ]; then echo "TEST_DEPENDS=$(echo $NP_TEST_DEP_LATEST)" >> $GITHUB_ENV; else echo "TEST_DEPENDS=$(echo $NP_TEST_DEP)" >> $GITHUB_ENV; fi
- name: Download a wheel accordingly to matrix
uses: actions/download-artifact@v3
with:
@@ -139,7 +139,7 @@ jobs:
NP_TEST_DEP: numpy==1.19.4
TRAVIS_BUILD_DIR: ${{ github.workspace }}
CONFIG_PATH: travis_config.sh
- DOCKER_IMAGE: quay.io/opencv-ci/opencv-python-manylinux2014-x86-64:20220628
+ DOCKER_IMAGE: quay.io/opencv-ci/opencv-python-manylinux2014-x86-64:20240524
USE_CCACHE: 1
UNICODE_WIDTH: 32
SDIST: ${{ matrix.build_sdist || 0 }}
diff --git a/.github/workflows/build_wheels_linux_arm.yml b/.github/workflows/build_wheels_linux_arm.yml
index 079efbe1..928ded7d 100644
--- a/.github/workflows/build_wheels_linux_arm.yml
+++ b/.github/workflows/build_wheels_linux_arm.yml
@@ -27,7 +27,7 @@ jobs:
strategy:
fail-fast: false
matrix:
- python-version: ['3.6']
+ python-version: ['3.9']
platform: [x64]
with_contrib: [0, 1]
without_gui: [0, 1]
@@ -42,7 +42,7 @@ jobs:
MB_ML_VER: 2014
TRAVIS_BUILD_DIR: ${{ github.workspace }}
CONFIG_PATH: travis_config.sh
- DOCKER_IMAGE: quay.io/opencv-ci/opencv-python-manylinux2014-aarch64:20220824
+ DOCKER_IMAGE: quay.io/opencv-ci/opencv-python-manylinux2014-aarch64:20240524
USE_CCACHE: 0
UNICODE_WIDTH: 32
SDIST: ${{ matrix.build_sdist || 0 }}
@@ -84,7 +84,7 @@ jobs:
strategy:
fail-fast: false
matrix:
- python-version: ['3.6', '3.7', '3.8', '3.9', '3.10']
+ python-version: ['3.7', '3.8', '3.9', '3.10', '3.11', '3.12']
platform: [x64]
with_contrib: [0, 1]
without_gui: [0, 1]
@@ -94,7 +94,7 @@ jobs:
MB_PYTHON_VERSION: ${{ matrix.python-version }}
PLAT: aarch64
NP_TEST_DEP: numpy==1.19.4
- NP_TEST_DEP_LATEST: numpy==1.21.4
+ NP_TEST_DEP_LATEST: numpy==2.0.0
CONFIG_PATH: travis_config.sh
DOCKER_TEST_IMAGE: multibuild/focal_arm64v8
UNICODE_WIDTH: 32
@@ -108,7 +108,7 @@ jobs:
submodules: true
fetch-depth: 0
- name: Setup Environment variables
- run: if [ "3.10" == "${{ matrix.python-version }}" ]; then echo "TEST_DEPENDS=$(echo $NP_TEST_DEP_LATEST)" >> $GITHUB_ENV; else echo "TEST_DEPENDS=$(echo $NP_TEST_DEP)" >> $GITHUB_ENV; fi
+ run: if [ "3.10" == "${{ matrix.python-version }}" -o "3.11" == "${{ matrix.python-version }}" -o "3.12" == "${{ matrix.python-version }}" ]; then echo "TEST_DEPENDS=$(echo $NP_TEST_DEP_LATEST)" >> $GITHUB_ENV; else echo "TEST_DEPENDS=$(echo $NP_TEST_DEP)" >> $GITHUB_ENV; fi
- name: Download a wheel accordingly to matrix
uses: actions/download-artifact@v3
with:
diff --git a/.github/workflows/build_wheels_macos.yml b/.github/workflows/build_wheels_macos.yml
index 584520b2..97df456e 100644
--- a/.github/workflows/build_wheels_macos.yml
+++ b/.github/workflows/build_wheels_macos.yml
@@ -20,14 +20,14 @@ on:
jobs:
Build:
- runs-on: macos-11
+ runs-on: macos-12
defaults:
run:
shell: bash
strategy:
fail-fast: false
matrix:
- python-version: ['3.6']
+ python-version: ['3.9']
platform: [x64]
with_contrib: [0, 1]
without_gui: [0, 1]
@@ -45,11 +45,9 @@ jobs:
USE_CCACHE: 1
UNICODE_WIDTH: 32
PLAT: x86_64
- FFMPEG_FORMULA_VERSION: '@4'
SDIST: ${{ matrix.build_sdist || 0 }}
ENABLE_HEADLESS: ${{ matrix.without_gui }}
ENABLE_CONTRIB: ${{ matrix.with_contrib }}
- MACOSX_DEPLOYMENT_TARGET: 10.13
steps:
- name: Cleanup
run: find . -mindepth 1 -delete
@@ -59,6 +57,12 @@ jobs:
if [[ "${{ github.event_name }}" == "schedule" || "${{ github.event_name }}" == "workflow_dispatch" ]]; then
echo "ENABLE_ROLLING=1" >> $GITHUB_ENV
fi
+ # hack for image issue on mac: https://github.com/actions/runner-images/issues/6817
+ rm /usr/local/bin/2to3*
+ rm /usr/local/bin/idle3*
+ rm /usr/local/bin/pydoc3*
+ rm /usr/local/bin/python3*
+ # end hack
- name: Checkout
uses: actions/checkout@v3
with:
@@ -94,14 +98,14 @@ jobs:
Test:
needs: [Build]
- runs-on: macos-11
+ runs-on: macos-12
defaults:
run:
shell: bash
strategy:
fail-fast: false
matrix:
- python-version: ['3.6', '3.7', '3.8', '3.9', '3.10']
+ python-version: ['3.7', '3.8', '3.9', '3.10', '3.11', '3.12']
platform: [x64]
with_contrib: [0, 1]
without_gui: [0, 1]
@@ -110,7 +114,7 @@ jobs:
ACTIONS_ALLOW_UNSECURE_COMMANDS: true
MB_PYTHON_VERSION: ${{ matrix.python-version }}
NP_TEST_DEP: numpy==1.19.4
- NP_TEST_DEP_LATEST: numpy==1.21.4
+ NP_TEST_DEP_LATEST: numpy==2.0.0
CONFIG_PATH: travis_config.sh
PLAT: x86_64
OPENCV_TEST_DATA_PATH: ${{ github.workspace }}/opencv_extra/testdata
@@ -130,7 +134,7 @@ jobs:
python-version: ${{ matrix.python-version }}
architecture: ${{ matrix.platform }}
- name: Setup Environment variables
- run: if [ "3.10" == "${{ matrix.python-version }}" ]; then echo "TEST_DEPENDS=$(echo $NP_TEST_DEP_LATEST)" >> $GITHUB_ENV; else echo "TEST_DEPENDS=$(echo $NP_TEST_DEP)" >> $GITHUB_ENV; fi
+ run: if [ "3.10" == "${{ matrix.python-version }}" -o "3.11" == "${{ matrix.python-version }}" -o "3.12" == "${{ matrix.python-version }}" ]; then echo "TEST_DEPENDS=$(echo $NP_TEST_DEP_LATEST)" >> $GITHUB_ENV; else echo "TEST_DEPENDS=$(echo $NP_TEST_DEP)" >> $GITHUB_ENV; fi
- name: Download a wheel accordingly to matrix
uses: actions/download-artifact@v3
with:
@@ -147,7 +151,7 @@ jobs:
python modules/python/test/test.py -v --repo .
- name: Pylint test
run: |
- python -m pip install pylint==2.12.2
+ python -m pip install pylint==2.15.9
cd ${{ github.workspace }}/tests
python -m pylint $PYLINT_TEST_FILE
diff --git a/.github/workflows/build_wheels_macos_m1.yml b/.github/workflows/build_wheels_macos_m1.yml
index b51801ab..a3bcac63 100644
--- a/.github/workflows/build_wheels_macos_m1.yml
+++ b/.github/workflows/build_wheels_macos_m1.yml
@@ -20,11 +20,11 @@ on:
jobs:
Build:
- runs-on: opencv-cn-mac-arm64
+ runs-on: python-macos11-m1
strategy:
fail-fast: false
matrix:
- python-version: ['3.7']
+ python-version: ['3.9']
platform: [x64]
with_contrib: [0, 1]
without_gui: [0, 1]
@@ -34,6 +34,7 @@ jobs:
SDIST: ${{ matrix.build_sdist || 0 }}
ENABLE_HEADLESS: ${{ matrix.without_gui }}
ENABLE_CONTRIB: ${{ matrix.with_contrib }}
+ PIP_INDEX_URL: https://pypi.tuna.tsinghua.edu.cn/simple
steps:
- name: Cleanup
run: find . -mindepth 1 -delete
@@ -54,8 +55,8 @@ jobs:
echo $ENABLE_CONTRIB > contrib.enabled
echo $ENABLE_HEADLESS > headless.enabled
export MACOSX_DEPLOYMENT_TARGET=11.0
- arch -arm64 python${{ matrix.python-version }} -m pip install toml && python${{ matrix.python-version }} -c 'import toml; c = toml.load("pyproject.toml"); print("\n".join(c["build-system"]["requires"]))' | python${{ matrix.python-version }} -m pip install -r /dev/stdin
- arch -arm64 python${{ matrix.python-version }} setup.py bdist_wheel --py-limited-api=cp37 --dist-dir=wheelhouse -v
+ python${{ matrix.python-version }} -m pip install toml && python${{ matrix.python-version }} -c 'import toml; c = toml.load("pyproject.toml"); print("\n".join(c["build-system"]["requires"]))' | python${{ matrix.python-version }} -m pip install -r /dev/stdin
+ python${{ matrix.python-version }} setup.py bdist_wheel --py-limited-api=cp37 --dist-dir=wheelhouse -v
delocate-wheel ${{ github.workspace }}/wheelhouse/opencv*
- name: Saving all wheels
uses: actions/upload-artifact@v3
@@ -74,7 +75,7 @@ jobs:
strategy:
fail-fast: false
matrix:
- python-version: ['3.7', '3.8', '3.9', '3.10']
+ python-version: ['3.7', '3.8', '3.9', '3.10', '3.11', '3.12']
platform: [x64]
with_contrib: [0, 1]
without_gui: [0, 1]
@@ -82,6 +83,7 @@ jobs:
env:
OPENCV_TEST_DATA_PATH: ${{ github.workspace }}/opencv_extra/testdata
PYLINT_TEST_FILE: ${{ github.workspace }}/opencv/samples/python/squares.py
+ PIP_INDEX_URL: https://pypi.tuna.tsinghua.edu.cn/simple
steps:
- name: Cleanup
run: find . -mindepth 1 -delete
@@ -96,20 +98,28 @@ jobs:
with:
name: wheel-${{ matrix.with_contrib }}-${{ matrix.without_gui }}-${{ matrix.build_sdist }}
path: wheelhouse/
+ - name: Create Venv for test
+ run: |
+ test -d "${{ github.workspace }}/opencv_test" && rm -rf "${{ github.workspace }}/opencv_test"
+ python${{ matrix.python-version }} -m venv ${{ github.workspace }}/opencv_test
- name: Package installation
run: |
- arch -arm64 python${{ matrix.python-version }} -m pip install --user --no-cache --force-reinstall wheelhouse/opencv*.whl
+ source ${{ github.workspace }}/opencv_test/bin/activate
+ python${{ matrix.python-version }} -m pip install --upgrade pip
+ python${{ matrix.python-version }} -m pip install --no-cache --force-reinstall wheelhouse/opencv*.whl
cd ${{ github.workspace }}/tests
- arch -arm64 python${{ matrix.python-version }} get_build_info.py
+ python${{ matrix.python-version }} get_build_info.py
- name: Run tests
run: |
+ source ${{ github.workspace }}/opencv_test/bin/activate
cd ${{ github.workspace }}/opencv
- arch -arm64 python${{ matrix.python-version }} modules/python/test/test.py -v --repo .
+ python${{ matrix.python-version }} modules/python/test/test.py -v --repo .
- name: Pylint test
run: |
- arch -arm64 python${{ matrix.python-version }} -m pip install pylint==2.12.2
+ source ${{ github.workspace }}/opencv_test/bin/activate
+ python${{ matrix.python-version }} -m pip install pylint==2.15.9
cd ${{ github.workspace }}/tests
- arch -arm64 python${{ matrix.python-version }} -m pylint $PYLINT_TEST_FILE
+ python${{ matrix.python-version }} -m pylint $PYLINT_TEST_FILE
Release_rolling:
if: ${{ github.event_name == 'schedule' || github.event_name == 'workflow_dispatch' }}
diff --git a/.github/workflows/build_wheels_windows.yml b/.github/workflows/build_wheels_windows.yml
index e6874ffe..d69f17ec 100644
--- a/.github/workflows/build_wheels_windows.yml
+++ b/.github/workflows/build_wheels_windows.yml
@@ -23,7 +23,7 @@ jobs:
strategy:
fail-fast: false
matrix:
- python-version: ['3.6']
+ python-version: ['3.9']
platform: [x86, x64]
with_contrib: [0, 1]
without_gui: [0, 1]
@@ -60,12 +60,14 @@ jobs:
- name: Setup MSBuild.exe
uses: microsoft/setup-msbuild@v1.1
- name: Build a package
+ # CMake 3.25 regression fix. See https://stackoverflow.com/questions/74162633/problem-compiling-from-source-opencv-with-mvsc2019-in-64-bit-version
run: |
python --version
python -m pip install --upgrade pip
python -m pip install --upgrade setuptools
+ python -m pip install cmake==3.24.2
python -m pip install toml && python -c "import toml; c = toml.load('pyproject.toml'); print('\n'.join(c['build-system']['requires']))" >> requirements.txt | python -m pip install -r requirements.txt
- set "CI_BUILD=1" && python setup.py bdist_wheel --py-limited-api=cp36 --dist-dir=%cd%\wheelhouse -v
+ set "CI_BUILD=1" && python setup.py bdist_wheel --py-limited-api=cp37 --dist-dir=%cd%\wheelhouse -v
shell: cmd
- name: Saving all wheels
uses: actions/upload-artifact@v3
@@ -87,7 +89,7 @@ jobs:
strategy:
fail-fast: false
matrix:
- python-version: ['3.6', '3.7', '3.8', '3.9', '3.10']
+ python-version: ['3.7', '3.8', '3.9', '3.10', '3.11', '3.12']
platform: [x86, x64]
with_contrib: [0, 1]
without_gui: [0, 1]
@@ -131,7 +133,7 @@ jobs:
python modules\python\test\test.py -v --repo .
- name: Pylint test
run: |
- python -m pip install pylint==2.12.2
+ python -m pip install pylint==2.15.9
cd ${{ github.workspace }}\tests
python -m pylint $PYLINT_TEST_FILE
diff --git a/LICENSE-3RD-PARTY.txt b/LICENSE-3RD-PARTY.txt
index caeffe51..0462eee3 100644
--- a/LICENSE-3RD-PARTY.txt
+++ b/LICENSE-3RD-PARTY.txt
@@ -304,7 +304,7 @@ modified by someone else and passed on, the recipients should know
that what they have is not the original version, so that the original
author's reputation will not be affected by problems that might be
introduced by others.
-
+
Finally, software patents pose a constant threat to the existence of
any free program. We wish to make sure that a company cannot
effectively restrict the users of a free program by obtaining a
@@ -360,7 +360,7 @@ modification follow. Pay close attention to the difference between a
"work based on the library" and a "work that uses the library". The
former contains code derived from the library, whereas the latter must
be combined with the library in order to run.
-
+
GNU LESSER GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
@@ -407,7 +407,7 @@ Library.
You may charge a fee for the physical act of transferring a copy,
and you may at your option offer warranty protection in exchange for a
fee.
-
+
2. You may modify your copy or copies of the Library or any portion
of it, thus forming a work based on the Library, and copy and
distribute such modifications or work under the terms of Section 1
@@ -465,7 +465,7 @@ instead of to this License. (If a newer version than version 2 of the
ordinary GNU General Public License has appeared, then you can specify
that version instead if you wish.) Do not make any other change in
these notices.
-
+
Once this change is made in a given copy, it is irreversible for
that copy, so the ordinary GNU General Public License applies to all
subsequent copies and derivative works made from that copy.
@@ -516,7 +516,7 @@ Library will still fall under Section 6.)
distribute the object code for the work under the terms of Section 6.
Any executables containing that work also fall under Section 6,
whether or not they are linked directly with the Library itself.
-
+
6. As an exception to the Sections above, you may also combine or
link a "work that uses the Library" with the Library to produce a
work containing portions of the Library, and distribute that work
@@ -578,7 +578,7 @@ restrictions of other proprietary libraries that do not normally
accompany the operating system. Such a contradiction means you cannot
use both them and the Library together in an executable that you
distribute.
-
+
7. You may place library facilities that are a work based on the
Library side-by-side in a single library together with other library
facilities not covered by this License, and distribute such a combined
@@ -619,7 +619,7 @@ subject to these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties with
this License.
-
+
11. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
@@ -671,7 +671,7 @@ conditions either of that version or of any later version published by
the Free Software Foundation. If the Library does not specify a
license version number, you may choose any version ever published by
the Free Software Foundation.
-
+
14. If you wish to incorporate parts of the Library into other free
programs whose distribution conditions are incompatible with these,
write to the author to ask for permission. For software which is
@@ -893,16 +893,16 @@ are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
-2. The origin of this software must not be misrepresented; you must
- not claim that you wrote the original software. If you use this
- software in a product, an acknowledgment in the product
+2. The origin of this software must not be misrepresented; you must
+ not claim that you wrote the original software. If you use this
+ software in a product, an acknowledgment in the product
documentation would be appreciated but is not required.
3. Altered source versions must be plainly marked as such, and must
not be misrepresented as being the original software.
-4. The name of the author may not be used to endorse or promote
- products derived from this software without specific prior written
+4. The name of the author may not be used to endorse or promote
+ products derived from this software without specific prior written
permission.
THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS
@@ -1502,8 +1502,8 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
libopenjp2 is redistributed within opencv-python macOS packages.
This license applies to libopenjp2 binary in the directory cv2/.
-The copyright in this software is being made available under the 2-clauses
-BSD License, included below. This software may be subject to other third
+The copyright in this software is being made available under the 2-clauses
+BSD License, included below. This software may be subject to other third
party and contributor rights, including patent rights, and no such rights
are granted under this license.
@@ -1514,7 +1514,7 @@ Copyright (c) 2003-2009, Francois-Olivier Devaux
Copyright (c) 2005, Herve Drolon, FreeImage Team
Copyright (c) 2002-2003, Yannick Verschueren
Copyright (c) 2001-2003, David Janssens
-Copyright (c) 2011-2012, Centre National d'Etudes Spatiales (CNES), France
+Copyright (c) 2011-2012, Centre National d'Etudes Spatiales (CNES), France
Copyright (c) 2012, CS Systemes d'Information, France
All rights reserved.
@@ -1659,7 +1659,7 @@ This license applies to libspeex binary in the directory cv2/.
Copyright 2002-2008 Xiph.org Foundation
Copyright 2002-2008 Jean-Marc Valin
Copyright 2005-2007 Analog Devices Inc.
-Copyright 2005-2008 Commonwealth Scientific and Industrial Research
+Copyright 2005-2008 Commonwealth Scientific and Industrial Research
Organisation (CSIRO)
Copyright 1993, 2002, 2006 David Rowe
Copyright 2003 EpicGames
@@ -1697,26 +1697,26 @@ libsrt is redistributed within opencv-python macOS packages.
This license applies to libsrt binary in the directory cv2/.
/*
- *
+ *
* Copyright (c) 2001-2017 Cisco Systems, Inc.
* All rights reserved.
- *
+ *
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
- *
+ *
* Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
- *
+ *
* Redistributions in binary form must reproduce the above
* copyright notice, this list of conditions and the following
* disclaimer in the documentation and/or other materials provided
* with the distribution.
- *
+ *
* Neither the name of the Cisco Systems, Inc. nor the names of its
* contributors may be used to endorse or promote products derived
* from this software without specific prior written permission.
- *
+ *
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
@@ -1770,7 +1770,7 @@ This license applies to libsrt binary in the directory cv2/.
means any form of the work other than Source Code Form.
1.7. "Larger Work"
- means a work that combines Covered Software with other material, in
+ means a work that combines Covered Software with other material, in
a separate file or files, that is not Covered Software.
1.8. "License"
@@ -2141,7 +2141,7 @@ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
------------------------------------------------------------------------------
-libwebp and libwebpmux are redistributed within opencv-python macOS packages.
+libwebp and libwebpmux are redistributed within all opencv-python packages.
This license applies to libwebp and libwebpmux binaries in the directory cv2/.
Copyright (c) 2010, Google Inc. All rights reserved.
@@ -2435,4 +2435,656 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Except as contained in this notice, the name of The Open Group shall not be
used in advertising or otherwise to promote the sale, use or other dealings
-in this Software without prior written authorization from The Open Group.
\ No newline at end of file
+in this Software without prior written authorization from The Open Group.
+
+------------------------------------------------------------------------------
+Vulkan headers are redistributed within all opencv-python packages.
+This license applies to Vulkan headers in the directory 3rdparty/include/vulkan.
+
+Copyright (c) 2015-2018 The Khronos Group Inc.
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+
+------------------------------------------------------------------------------
+Libjpeg-turbo is redistributed within all opencv-python packages as build option.
+
+libjpeg-turbo Licenses
+======================
+
+libjpeg-turbo is covered by three compatible BSD-style open source licenses:
+
+- The IJG (Independent JPEG Group) License, which is listed in
+ [README.ijg](README.ijg)
+
+ This license applies to the libjpeg API library and associated programs
+ (any code inherited from libjpeg, and any modifications to that code.)
+
+- The Modified (3-clause) BSD License, which is listed below
+
+ This license covers the TurboJPEG API library and associated programs, as
+ well as the build system.
+
+- The [zlib License](https://opensource.org/licenses/Zlib)
+
+ This license is a subset of the other two, and it covers the libjpeg-turbo
+ SIMD extensions.
+
+
+Complying with the libjpeg-turbo Licenses
+=========================================
+
+This section provides a roll-up of the libjpeg-turbo licensing terms, to the
+best of our understanding.
+
+1. If you are distributing a modified version of the libjpeg-turbo source,
+ then:
+
+ 1. You cannot alter or remove any existing copyright or license notices
+ from the source.
+
+ **Origin**
+ - Clause 1 of the IJG License
+ - Clause 1 of the Modified BSD License
+ - Clauses 1 and 3 of the zlib License
+
+ 2. You must add your own copyright notice to the header of each source
+ file you modified, so others can tell that you modified that file (if
+ there is not an existing copyright header in that file, then you can
+ simply add a notice stating that you modified the file.)
+
+ **Origin**
+ - Clause 1 of the IJG License
+ - Clause 2 of the zlib License
+
+ 3. You must include the IJG README file, and you must not alter any of the
+ copyright or license text in that file.
+
+ **Origin**
+ - Clause 1 of the IJG License
+
+2. If you are distributing only libjpeg-turbo binaries without the source, or
+ if you are distributing an application that statically links with
+ libjpeg-turbo, then:
+
+ 1. Your product documentation must include a message stating:
+
+ This software is based in part on the work of the Independent JPEG
+ Group.
+
+ **Origin**
+ - Clause 2 of the IJG license
+
+ 2. If your binary distribution includes or uses the TurboJPEG API, then
+ your product documentation must include the text of the Modified BSD
+ License (see below.)
+
+ **Origin**
+ - Clause 2 of the Modified BSD License
+
+3. You cannot use the name of the IJG or The libjpeg-turbo Project or the
+ contributors thereof in advertising, publicity, etc.
+
+ **Origin**
+ - IJG License
+ - Clause 3 of the Modified BSD License
+
+4. The IJG and The libjpeg-turbo Project do not warrant libjpeg-turbo to be
+ free of defects, nor do we accept any liability for undesirable
+ consequences resulting from your use of the software.
+
+ **Origin**
+ - IJG License
+ - Modified BSD License
+ - zlib License
+
+
+The Modified (3-clause) BSD License
+===================================
+
+Copyright (C)2009-2022 D. R. Commander. All Rights Reserved.
+Copyright (C)2015 Viktor Szathmáry. All Rights Reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+- Redistributions of source code must retain the above copyright notice,
+ this list of conditions and the following disclaimer.
+- Redistributions in binary form must reproduce the above copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+- Neither the name of the libjpeg-turbo Project nor the names of its
+ contributors may be used to endorse or promote products derived from this
+ software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS",
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE
+LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGE.
+
+
+Why Three Licenses?
+===================
+
+The zlib License could have been used instead of the Modified (3-clause) BSD
+License, and since the IJG License effectively subsumes the distribution
+conditions of the zlib License, this would have effectively placed
+libjpeg-turbo binary distributions under the IJG License. However, the IJG
+License specifically refers to the Independent JPEG Group and does not extend
+attribution and endorsement protections to other entities. Thus, it was
+desirable to choose a license that granted us the same protections for new code
+that were granted to the IJG for code derived from their software.
+
+------------------------------------------------------------------------------
+Libspng is redistributed within all opencv-python packages as build option.
+
+BSD 2-Clause License
+
+Copyright (c) 2018-2022, Randy
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+* Redistributions of source code must retain the above copyright notice, this
+ list of conditions and the following disclaimer.
+
+* Redistributions in binary form must reproduce the above copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
+FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+------------------------------------------------------------------------------
+QUIRC library is redistributed within all opencv-python packages.
+
+quirc -- QR-code recognition library
+Copyright (C) 2010-2012 Daniel Beer
+
+Permission to use, copy, modify, and/or distribute this software for
+any purpose with or without fee is hereby granted, provided that the
+above copyright notice and this permission notice appear in all
+copies.
+
+THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
+WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
+WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
+AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
+DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
+PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
+TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
+PERFORMANCE OF THIS SOFTWARE.
+
+------------------------------------------------------------------------------
+Flatbuffers library is redistributed within all opencv-python packages.
+
+ Apache License
+ Version 2.0, January 2004
+ http://www.apache.org/licenses/
+
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+ 1. Definitions.
+
+ "License" shall mean the terms and conditions for use, reproduction,
+ and distribution as defined by Sections 1 through 9 of this document.
+
+ "Licensor" shall mean the copyright owner or entity authorized by
+ the copyright owner that is granting the License.
+
+ "Legal Entity" shall mean the union of the acting entity and all
+ other entities that control, are controlled by, or are under common
+ control with that entity. For the purposes of this definition,
+ "control" means (i) the power, direct or indirect, to cause the
+ direction or management of such entity, whether by contract or
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
+ outstanding shares, or (iii) beneficial ownership of such entity.
+
+ "You" (or "Your") shall mean an individual or Legal Entity
+ exercising permissions granted by this License.
+
+ "Source" form shall mean the preferred form for making modifications,
+ including but not limited to software source code, documentation
+ source, and configuration files.
+
+ "Object" form shall mean any form resulting from mechanical
+ transformation or translation of a Source form, including but
+ not limited to compiled object code, generated documentation,
+ and conversions to other media types.
+
+ "Work" shall mean the work of authorship, whether in Source or
+ Object form, made available under the License, as indicated by a
+ copyright notice that is included in or attached to the work
+ (an example is provided in the Appendix below).
+
+ "Derivative Works" shall mean any work, whether in Source or Object
+ form, that is based on (or derived from) the Work and for which the
+ editorial revisions, annotations, elaborations, or other modifications
+ represent, as a whole, an original work of authorship. For the purposes
+ of this License, Derivative Works shall not include works that remain
+ separable from, or merely link (or bind by name) to the interfaces of,
+ the Work and Derivative Works thereof.
+
+ "Contribution" shall mean any work of authorship, including
+ the original version of the Work and any modifications or additions
+ to that Work or Derivative Works thereof, that is intentionally
+ submitted to Licensor for inclusion in the Work by the copyright owner
+ or by an individual or Legal Entity authorized to submit on behalf of
+ the copyright owner. For the purposes of this definition, "submitted"
+ means any form of electronic, verbal, or written communication sent
+ to the Licensor or its representatives, including but not limited to
+ communication on electronic mailing lists, source code control systems,
+ and issue tracking systems that are managed by, or on behalf of, the
+ Licensor for the purpose of discussing and improving the Work, but
+ excluding communication that is conspicuously marked or otherwise
+ designated in writing by the copyright owner as "Not a Contribution."
+
+ "Contributor" shall mean Licensor and any individual or Legal Entity
+ on behalf of whom a Contribution has been received by Licensor and
+ subsequently incorporated within the Work.
+
+ 2. Grant of Copyright License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ copyright license to reproduce, prepare Derivative Works of,
+ publicly display, publicly perform, sublicense, and distribute the
+ Work and such Derivative Works in Source or Object form.
+
+ 3. Grant of Patent License. Subject to the terms and conditions of
+ this License, each Contributor hereby grants to You a perpetual,
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+ (except as stated in this section) patent license to make, have made,
+ use, offer to sell, sell, import, and otherwise transfer the Work,
+ where such license applies only to those patent claims licensable
+ by such Contributor that are necessarily infringed by their
+ Contribution(s) alone or by combination of their Contribution(s)
+ with the Work to which such Contribution(s) was submitted. If You
+ institute patent litigation against any entity (including a
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
+ or a Contribution incorporated within the Work constitutes direct
+ or contributory patent infringement, then any patent licenses
+ granted to You under this License for that Work shall terminate
+ as of the date such litigation is filed.
+
+ 4. Redistribution. You may reproduce and distribute copies of the
+ Work or Derivative Works thereof in any medium, with or without
+ modifications, and in Source or Object form, provided that You
+ meet the following conditions:
+
+ (a) You must give any other recipients of the Work or
+ Derivative Works a copy of this License; and
+
+ (b) You must cause any modified files to carry prominent notices
+ stating that You changed the files; and
+
+ (c) You must retain, in the Source form of any Derivative Works
+ that You distribute, all copyright, patent, trademark, and
+ attribution notices from the Source form of the Work,
+ excluding those notices that do not pertain to any part of
+ the Derivative Works; and
+
+ (d) If the Work includes a "NOTICE" text file as part of its
+ distribution, then any Derivative Works that You distribute must
+ include a readable copy of the attribution notices contained
+ within such NOTICE file, excluding those notices that do not
+ pertain to any part of the Derivative Works, in at least one
+ of the following places: within a NOTICE text file distributed
+ as part of the Derivative Works; within the Source form or
+ documentation, if provided along with the Derivative Works; or,
+ within a display generated by the Derivative Works, if and
+ wherever such third-party notices normally appear. The contents
+ of the NOTICE file are for informational purposes only and
+ do not modify the License. You may add Your own attribution
+ notices within Derivative Works that You distribute, alongside
+ or as an addendum to the NOTICE text from the Work, provided
+ that such additional attribution notices cannot be construed
+ as modifying the License.
+
+ You may add Your own copyright statement to Your modifications and
+ may provide additional or different license terms and conditions
+ for use, reproduction, or distribution of Your modifications, or
+ for any such Derivative Works as a whole, provided Your use,
+ reproduction, and distribution of the Work otherwise complies with
+ the conditions stated in this License.
+
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
+ any Contribution intentionally submitted for inclusion in the Work
+ by You to the Licensor shall be under the terms and conditions of
+ this License, without any additional terms or conditions.
+ Notwithstanding the above, nothing herein shall supersede or modify
+ the terms of any separate license agreement you may have executed
+ with Licensor regarding such Contributions.
+
+ 6. Trademarks. This License does not grant permission to use the trade
+ names, trademarks, service marks, or product names of the Licensor,
+ except as required for reasonable and customary use in describing the
+ origin of the Work and reproducing the content of the NOTICE file.
+
+ 7. Disclaimer of Warranty. Unless required by applicable law or
+ agreed to in writing, Licensor provides the Work (and each
+ Contributor provides its Contributions) on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ implied, including, without limitation, any warranties or conditions
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+ PARTICULAR PURPOSE. You are solely responsible for determining the
+ appropriateness of using or redistributing the Work and assume any
+ risks associated with Your exercise of permissions under this License.
+
+ 8. Limitation of Liability. In no event and under no legal theory,
+ whether in tort (including negligence), contract, or otherwise,
+ unless required by applicable law (such as deliberate and grossly
+ negligent acts) or agreed to in writing, shall any Contributor be
+ liable to You for damages, including any direct, indirect, special,
+ incidental, or consequential damages of any character arising as a
+ result of this License or out of the use or inability to use the
+ Work (including but not limited to damages for loss of goodwill,
+ work stoppage, computer failure or malfunction, or any and all
+ other commercial damages or losses), even if such Contributor
+ has been advised of the possibility of such damages.
+
+ 9. Accepting Warranty or Additional Liability. While redistributing
+ the Work or Derivative Works thereof, You may choose to offer,
+ and charge a fee for, acceptance of support, warranty, indemnity,
+ or other liability obligations and/or rights consistent with this
+ License. However, in accepting such obligations, You may act only
+ on Your own behalf and on Your sole responsibility, not on behalf
+ of any other Contributor, and only if You agree to indemnify,
+ defend, and hold each Contributor harmless for any liability
+ incurred by, or claims asserted against, such Contributor by reason
+ of your accepting any such warranty or additional liability.
+
+ END OF TERMS AND CONDITIONS
+
+ APPENDIX: How to apply the Apache License to your work.
+
+ To apply the Apache License to your work, attach the following
+ boilerplate notice, with the fields enclosed by brackets "[]"
+ replaced with your own identifying information. (Don't include
+ the brackets!) The text should be enclosed in the appropriate
+ comment syntax for the file format. We also recommend that a
+ file or class name and description of purpose be included on the
+ same "printed page" as the copyright notice for easier
+ identification within third-party archives.
+
+ Copyright [yyyy] [name of copyright owner]
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+
+------------------------------------------------------------------------------
+Protobuf library is redistributed within all opencv-python packages.
+
+Copyright 2008 Google Inc. All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are
+met:
+
+ * Redistributions of source code must retain the above copyright
+notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above
+copyright notice, this list of conditions and the following disclaimer
+in the documentation and/or other materials provided with the
+distribution.
+ * Neither the name of Google Inc. nor the names of its
+contributors may be used to endorse or promote products derived from
+this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+Code generated by the Protocol Buffer compiler is owned by the owner
+of the input file used when generating it. This code is not
+standalone and requires a support library to be linked with it. This
+support library is itself covered by the above license.
+
+------------------------------------------------------------------------------
+OpenJPEG library is redistributed within all opencv-python packages.
+
+/*
+ * The copyright in this software is being made available under the 2-clauses
+ * BSD License, included below. This software may be subject to other third
+ * party and contributor rights, including patent rights, and no such rights
+ * are granted under this license.
+ *
+ * Copyright (c) 2002-2014, Universite catholique de Louvain (UCL), Belgium
+ * Copyright (c) 2002-2014, Professor Benoit Macq
+ * Copyright (c) 2003-2014, Antonin Descampe
+ * Copyright (c) 2003-2009, Francois-Olivier Devaux
+ * Copyright (c) 2005, Herve Drolon, FreeImage Team
+ * Copyright (c) 2002-2003, Yannick Verschueren
+ * Copyright (c) 2001-2003, David Janssens
+ * Copyright (c) 2011-2012, Centre National d'Etudes Spatiales (CNES), France
+ * Copyright (c) 2012, CS Systemes d'Information, France
+ *
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS `AS IS'
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ */
+
+------------------------------------------------------------------------------
+TIFF library is redistributed within all opencv-python packages.
+
+Copyright (c) 1988-1997 Sam Leffler
+Copyright (c) 1991-1997 Silicon Graphics, Inc.
+
+Permission to use, copy, modify, distribute, and sell this software and
+its documentation for any purpose is hereby granted without fee, provided
+that (i) the above copyright notices and this permission notice appear in
+all copies of the software and related documentation, and (ii) the names of
+Sam Leffler and Silicon Graphics may not be used in any advertising or
+publicity relating to the software without the specific, prior written
+permission of Sam Leffler and Silicon Graphics.
+
+THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND,
+EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
+WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
+
+IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR
+ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND,
+OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
+WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF
+LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
+OF THIS SOFTWARE.
+
+------------------------------------------------------------------------------
+OpenEXR library is redistributed within all opencv-python packages.
+
+Copyright (c) 2006, Industrial Light & Magic, a division of Lucasfilm
+Entertainment Company Ltd. Portions contributed and copyright held by
+others as indicated. All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are
+met:
+
+ * Redistributions of source code must retain the above
+ copyright notice, this list of conditions and the following
+ disclaimer.
+
+ * Redistributions in binary form must reproduce the above
+ copyright notice, this list of conditions and the following
+ disclaimer in the documentation and/or other materials provided with
+ the distribution.
+
+ * Neither the name of Industrial Light & Magic nor the names of
+ any other contributors to this software may be used to endorse or
+ promote products derived from this software without specific prior
+ written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
+IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+------------------------------------------------------------------------------
+Intel(R) IPP ICV library statically linked within x86 and x86_64 opencv-python packages.
+
+Intel(R) Integrated Performance Primitives 2021 Update 10
+
+Intel Simplified Software License (Version October 2022)
+
+Intel(R) Integrated Performance Primitives (Intel(R) IPP) : Copyright (C) 1997 Intel Corporation
+
+Use and Redistribution. You may use and redistribute the software, which is
+provided in binary form only, (the "Software"), without modification,
+provided the following conditions are met:
+
+* Redistributions must reproduce the above copyright notice and these
+ terms of use in the Software and in the documentation and/or other materials
+ provided with the distribution.
+* Neither the name of Intel nor the names of its suppliers may be used to
+ endorse or promote products derived from this Software without specific
+ prior written permission.
+* No reverse engineering, decompilation, or disassembly of the Software is
+ permitted, nor any modification or alteration of the Software or its operation
+ at any time, including during execution.
+
+No other licenses. Except as provided in the preceding section, Intel grants no
+licenses or other rights by implication, estoppel or otherwise to, patent,
+copyright, trademark, trade name, service mark or other intellectual property
+licenses or rights of Intel.
+
+Third party software. "Third Party Software" means the files (if any) listed
+in the "third-party-software.txt" or other similarly-named text file that may
+be included with the Software. Third Party Software, even if included with the
+distribution of the Software, may be governed by separate license terms, including
+without limitation, third party license terms, open source software notices and
+terms, and/or other Intel software license terms. These separate license terms
+solely govern Your use of the Third Party Software.
+
+DISCLAIMER. THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED
+WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, AND NON-INFRINGEMENT ARE
+DISCLAIMED. THIS SOFTWARE IS NOT INTENDED FOR USE IN SYSTEMS OR APPLICATIONS
+WHERE FAILURE OF THE SOFTWARE MAY CAUSE PERSONAL INJURY OR DEATH AND YOU AGREE
+THAT YOU ARE FULLY RESPONSIBLE FOR ANY CLAIMS, COSTS, DAMAGES, EXPENSES, AND
+ATTORNEYS' FEES ARISING OUT OF ANY SUCH USE, EVEN IF ANY CLAIM ALLEGES THAT
+INTEL WAS NEGLIGENT REGARDING THE DESIGN OR MANUFACTURE OF THE SOFTWARE.
+
+LIMITATION OF LIABILITY. IN NO EVENT WILL INTEL BE LIABLE FOR ANY DIRECT,
+INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
+OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+No support. Intel may make changes to the Software, at any time without notice,
+and is not obligated to support, update or provide training for the Software.
+
+Termination. Your right to use the Software is terminated in the event of your
+breach of this license.
+
+Feedback. Should you provide Intel with comments, modifications, corrections,
+enhancements or other input ("Feedback") related to the Software, Intel will be
+free to use, disclose, reproduce, license or otherwise distribute or exploit the
+Feedback in its sole discretion without any obligations or restrictions of any
+kind, including without limitation, intellectual property rights or licensing
+obligations.
+
+Compliance with laws. You agree to comply with all relevant laws and regulations
+governing your use, transfer, import or export (or prohibition thereof) of the
+Software.
+
+Governing law. All disputes will be governed by the laws of the United States of
+America and the State of Delaware without reference to conflict of law
+principles and subject to the exclusive jurisdiction of the state or federal
+courts sitting in the State of Delaware, and each party agrees that it submits
+to the personal jurisdiction and venue of those courts and waives any
+objections. THE UNITED NATIONS CONVENTION ON CONTRACTS FOR THE INTERNATIONAL
+SALE OF GOODS (1980) IS SPECIFICALLY EXCLUDED AND WILL NOT APPLY TO THE SOFTWARE.
+
+------------------------------------------------------------------------------
+Orbbec SDK distributed with arm64 MacOS packages.
+
+MIT License
+
+Copyright (c) 2023 OrbbecDeveloper
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/README.md b/README.md
index d60fcdf2..03396b56 100644
--- a/README.md
+++ b/README.md
@@ -1,4 +1,24 @@
-[![Downloads](http://pepy.tech/badge/opencv-python)](http://pepy.tech/project/opencv-python)
+[![Downloads](https://static.pepy.tech/badge/opencv-python)](http://pepy.tech/project/opencv-python)
+
+### Keep OpenCV Free
+
+OpenCV is raising funds to keep the library free for everyone, and we need the support of the entire community to do it. [Donate to OpenCV on Github](https://github.com/sponsors/opencv) to show your support.
+
+- [OpenCV on Wheels](#opencv-on-wheels)
+ - [Installation and Usage](#installation-and-usage)
+- [Frequently Asked Questions](#frequently-asked-questions)
+- [Documentation for opencv-python](#documentation-for-opencv-python)
+ - [CI build process](#ci-build-process)
+ - [Manual builds](#manual-builds)
+ - [Manual debug builds](#manual-debug-builds)
+ - [Source distributions](#source-distributions)
+ - [Licensing](#licensing)
+ - [Versioning](#versioning)
+ - [Releases](#releases)
+ - [Development builds](#development-builds)
+ - [Manylinux wheels](#manylinux-wheels)
+ - [Supported Python versions](#supported-python-versions)
+ - [Backward compatibility](#backward-compatibility)
## OpenCV on Wheels
@@ -67,7 +87,7 @@ A: Make sure you have removed old manual installations of OpenCV Python bindings
**Q: Function foo() or method bar() returns wrong result, throws exception or crashes interpreter. What should I do?**
-A: The repository contains only OpenCV-Python package build scripts, but not OpenCV itself. Python bindings for OpenCV are developed in official OpenCV repository and it's the best place to report issues. Also please check {OpenCV wiki](https://github.com/opencv/opencv/wiki) and [the official OpenCV forum](https://forum.opencv.org/) before file new bugs.
+A: The repository contains only OpenCV-Python package build scripts, but not OpenCV itself. Python bindings for OpenCV are developed in official OpenCV repository and it's the best place to report issues. Also please check [OpenCV wiki](https://github.com/opencv/opencv/wiki) and [the official OpenCV forum](https://forum.opencv.org/) before file new bugs.
**Q: Why the packages do not include non-free algorithms?**
@@ -137,7 +157,7 @@ If some dependency is not enabled in the pre-built wheels, you can also run the
4. Select the package flavor which you wish to build with `ENABLE_CONTRIB` and `ENABLE_HEADLESS`: i.e. `export ENABLE_CONTRIB=1` if you wish to build `opencv-contrib-python`
5. Run ``pip wheel . --verbose``. NOTE: make sure you have the latest ``pip`` version, the ``pip wheel`` command replaces the old ``python setup.py bdist_wheel`` command which does not support ``pyproject.toml``.
- this might take anything from 5 minutes to over 2 hours depending on your hardware
-6. You'll have the wheel file in the `dist` folder and you can do with that whatever you wish
+6. Pip will print fresh wheel location at the end of build procedure. If you use old approach with `setup.py` file wheel package will be placed in `dist` folder. Package is ready and you can do with that whatever you wish.
- Optional: on Linux use some of the `manylinux` images as a build hosts if maximum portability is needed and run `auditwheel` for the wheel after build
- Optional: on macOS use ``delocate`` (same as ``auditwheel`` but for macOS) for better portability
@@ -216,11 +236,12 @@ The default ``manylinux2014`` images have been extended with some OpenCV depende
Python 3.x compatible pre-built wheels are provided for the officially supported Python versions (not in EOL):
-- 3.6
- 3.7
- 3.8
- 3.9
- 3.10
+- 3.11
+- 3.12
### Backward compatibility
@@ -228,3 +249,6 @@ Starting from 4.2.0 and 3.4.9 builds the macOS Travis build environment was upda
Starting from 4.3.0 and 3.4.10 builds the Linux build environment was updated from `manylinux1` to `manylinux2014`. This dropped support for old Linux distributions.
+Starting from version 4.7.0 the Mac OS GitHub Actions build environment was update to version 11. Mac OS 10.x support depricated. See https://github.com/actions/runner-images/issues/5583
+
+Starting from version 4.9.0 the Mac OS GitHub Actions build environment was update to version 12. Mac OS 10.x support depricated by Brew and most of used packages.
diff --git a/docker/manylinux2014/Dockerfile_aarch64 b/docker/manylinux2014/Dockerfile_aarch64
index 48ad3f98..e19492ff 100644
--- a/docker/manylinux2014/Dockerfile_aarch64
+++ b/docker/manylinux2014/Dockerfile_aarch64
@@ -1,38 +1,27 @@
-# Version: 20220824
+# Version: 20240524
# Image name: quay.io/opencv-ci/opencv-python-manylinux2014-aarch64
FROM quay.io/pypa/manylinux2014_aarch64:latest
ARG CCACHE_VERSION=3.7.9
-ARG FFMPEG_VERSION=4.4.1
-ARG FREETYPE_VERSION=2.12.1
-ARG LIBPNG_VERSION=1.6.37
+ARG FFMPEG_VERSION=5.1.4
+ARG FREETYPE_VERSION=2.13.2
+ARG LIBPNG_VERSION=1.6.43
+ARG VPX_VERSION=v1.14.0
ARG NASM_VERSION=2.15.04
-ARG OPENSSL_VERSION=1_1_1o
-ARG QT_VERSION=5.15.0
+ARG OPENSSL_VERSION=1_1_1w
+ARG QT_VERSION=5.15.13
ARG YASM_VERSION=1.3.0
-ARG ZLIB_VERSION=1.2.12
ENV LD_LIBRARY_PATH /usr/local/lib:$LD_LIBRARY_PATH
# epel-release need for aarch64 to get openblas packages
-RUN yum install bzip2-devel curl-devel xcb-util-renderutil-devel xcb-util-devel xcb-util-image-devel xcb-util-keysyms-devel xcb-util-wm-devel mesa-libGL-devel libxkbcommon-devel libxkbcommon-x11-devel libXi-devel lapack-devel epel-release -y && \
- yum install openblas-devel -y && \
+RUN yum install zlib-devel curl-devel xcb-util-renderutil-devel xcb-util-devel xcb-util-image-devel xcb-util-keysyms-devel xcb-util-wm-devel mesa-libGL-devel libxkbcommon-devel libxkbcommon-x11-devel libXi-devel lapack-devel epel-release -y && \
+ yum install openblas-devel dejavu-sans-fonts -y && \
cp /usr/include/lapacke/lapacke*.h /usr/include/ && \
curl https://raw.githubusercontent.com/xianyi/OpenBLAS/v0.3.3/cblas.h -o /usr/include/cblas.h && \
# libpng will be built from source
- yum remove libpng zlib-devel bzip2-devel -y
-
-RUN mkdir ~/zlib_sources && \
- cd ~/zlib_sources && \
- curl -O -L https://www.zlib.net/zlib-${ZLIB_VERSION}.tar.gz && \
- tar -xf zlib-${ZLIB_VERSION}.tar.gz && \
- cd zlib-${ZLIB_VERSION} && \
- ./configure --prefix=/usr/local && \
- make && \
- make install && \
- cd .. && \
- rm -rf ~/zlib_sources
+ yum remove libpng -y
RUN mkdir ~/libpng_sources && \
cd ~/libpng_sources && \
@@ -45,9 +34,10 @@ RUN mkdir ~/libpng_sources && \
cd .. && \
rm -rf ~/libpng_sources
+# looks like download.savannah.gnu.org suffers from https://savannah.gnu.org/bugs/?48150 in Manylinux 2014 env on aarch64
RUN mkdir ~/freetype_sources && \
cd ~/freetype_sources && \
- curl -O -L https://download.savannah.gnu.org/releases/freetype/freetype-${FREETYPE_VERSION}.tar.gz && \
+ curl -O -L https://download-mirror.savannah.gnu.org/releases/freetype/freetype-${FREETYPE_VERSION}.tar.gz && \
tar -xf freetype-${FREETYPE_VERSION}.tar.gz && \
cd freetype-${FREETYPE_VERSION} && \
./configure --prefix="/ffmpeg_build" --enable-freetype-config && \
@@ -56,8 +46,8 @@ RUN mkdir ~/freetype_sources && \
cd .. && \
rm -rf ~/freetype_sources
-RUN curl -O -L https://download.qt.io/official_releases/qt/5.15/${QT_VERSION}/single/qt-everywhere-src-${QT_VERSION}.tar.xz && \
- tar -xf qt-everywhere-src-${QT_VERSION}.tar.xz && \
+RUN curl -C - -O -L https://download.qt.io/archive/qt/5.15/${QT_VERSION}/single/qt-everywhere-opensource-src-${QT_VERSION}.tar.xz && \
+ tar -xf qt-everywhere-opensource-src-${QT_VERSION}.tar.xz && \
cd qt-everywhere-src-${QT_VERSION} && \
export MAKEFLAGS=-j$(nproc) && \
./configure -prefix /opt/Qt${QT_VERSION} -release -opensource -confirm-license -qtnamespace QtOpenCVPython -xcb -xcb-xlib -bundled-xcb-xinput -no-openssl -no-dbus -skip qt3d -skip qtactiveqt -skip qtcanvas3d -skip qtconnectivity -skip qtdatavis3d -skip qtdoc -skip qtgamepad -skip qtgraphicaleffects -skip qtimageformats -skip qtlocation -skip qtmultimedia -skip qtpurchasing -skip qtqa -skip qtremoteobjects -skip qtrepotools -skip qtscript -skip qtscxml -skip qtsensors -skip qtserialbus -skip qtserialport -skip qtspeech -skip qttranslations -skip qtwayland -skip qtwebchannel -skip qtwebengine -skip qtwebsockets -skip qtwebview -skip xmlpatterns -skip declarative -make libs && \
@@ -104,7 +94,7 @@ RUN mkdir ~/yasm_sources && \
RUN mkdir ~/libvpx_sources && \
cd ~/libvpx_sources && \
- git clone --depth 1 https://github.com/webmproject/libvpx.git && \
+ git clone --depth 1 -b ${VPX_VERSION} https://github.com/webmproject/libvpx.git && \
cd libvpx && \
./configure --prefix="/ffmpeg_build" --disable-examples --disable-unit-tests --enable-vp9-highbitdepth --as=yasm --enable-pic --enable-shared && \
make -j$(getconf _NPROCESSORS_ONLN) && \
diff --git a/docker/manylinux2014/Dockerfile_i686 b/docker/manylinux2014/Dockerfile_i686
index 3b866874..1c94b1fc 100644
--- a/docker/manylinux2014/Dockerfile_i686
+++ b/docker/manylinux2014/Dockerfile_i686
@@ -2,9 +2,9 @@ FROM quay.io/pypa/manylinux2014_i686:latest
ARG CCACHE_VERSION=3.7.9
ARG CMAKE_VERSION=3.17.0
-ARG FFMPEG_VERSION=4.4.1
+ARG FFMPEG_VERSION=5.1.4
ARG NASM_VERSION=2.15.04
-ARG OPENSSL_VERSION=1_1_1m
+ARG OPENSSL_VERSION=1_1_1w
ARG QT_VERSION=5.15.0
ARG YASM_VERSION=1.3.0
diff --git a/docker/manylinux2014/Dockerfile_x86_64 b/docker/manylinux2014/Dockerfile_x86_64
index 85fc22fd..eceae25e 100644
--- a/docker/manylinux2014/Dockerfile_x86_64
+++ b/docker/manylinux2014/Dockerfile_x86_64
@@ -1,38 +1,27 @@
-# Version: 20220824
+# Version: 20240524
# Image name: quay.io/opencv-ci/opencv-python-manylinux2014-x86-64
FROM quay.io/pypa/manylinux2014_x86_64:latest
ARG CCACHE_VERSION=3.7.9
-ARG FFMPEG_VERSION=4.4.1
-ARG FREETYPE_VERSION=2.12.1
-ARG LIBPNG_VERSION=1.6.37
+ARG FFMPEG_VERSION=5.1.4
+ARG FREETYPE_VERSION=2.13.2
+ARG LIBPNG_VERSION=1.6.43
+ARG VPX_VERSION=v1.14.0
ARG NASM_VERSION=2.15.04
-ARG OPENSSL_VERSION=1_1_1o
-ARG QT_VERSION=5.15.0
+ARG OPENSSL_VERSION=1_1_1w
+ARG QT_VERSION=5.15.13
ARG YASM_VERSION=1.3.0
-ARG ZLIB_VERSION=1.2.12
ENV LD_LIBRARY_PATH /usr/local/lib:$LD_LIBRARY_PATH
# epel-release need for aarch64 to get openblas packages
-RUN yum install bzip2-devel curl-devel xcb-util-renderutil-devel xcb-util-devel xcb-util-image-devel xcb-util-keysyms-devel xcb-util-wm-devel mesa-libGL-devel libxkbcommon-devel libxkbcommon-x11-devel libXi-devel lapack-devel epel-release -y && \
- yum install openblas-devel -y && \
+RUN yum install zlib-devel curl-devel xcb-util-renderutil-devel xcb-util-devel xcb-util-image-devel xcb-util-keysyms-devel xcb-util-wm-devel mesa-libGL-devel libxkbcommon-devel libxkbcommon-x11-devel libXi-devel lapack-devel epel-release -y && \
+ yum install openblas-devel dejavu-sans-fonts -y && \
cp /usr/include/lapacke/lapacke*.h /usr/include/ && \
curl https://raw.githubusercontent.com/xianyi/OpenBLAS/v0.3.3/cblas.h -o /usr/include/cblas.h && \
# libpng will be built from source
- yum remove libpng zlib-devel bzip2-devel -y
-
-RUN mkdir ~/zlib_sources && \
- cd ~/zlib_sources && \
- curl -O -L https://www.zlib.net/zlib-${ZLIB_VERSION}.tar.gz && \
- tar -xf zlib-${ZLIB_VERSION}.tar.gz && \
- cd zlib-${ZLIB_VERSION} && \
- ./configure --prefix=/usr/local && \
- make && \
- make install && \
- cd .. && \
- rm -rf ~/zlib_sources
+ yum remove libpng -y
RUN mkdir ~/libpng_sources && \
cd ~/libpng_sources && \
@@ -56,8 +45,8 @@ RUN mkdir ~/freetype_sources && \
cd .. && \
rm -rf ~/freetype_sources
-RUN curl -O -L https://download.qt.io/official_releases/qt/5.15/${QT_VERSION}/single/qt-everywhere-src-${QT_VERSION}.tar.xz && \
- tar -xf qt-everywhere-src-${QT_VERSION}.tar.xz && \
+RUN curl -O -L https://download.qt.io/archive/qt/5.15/${QT_VERSION}/single/qt-everywhere-opensource-src-${QT_VERSION}.tar.xz && \
+ tar -xf qt-everywhere-opensource-src-${QT_VERSION}.tar.xz && \
cd qt-everywhere-src-${QT_VERSION} && \
export MAKEFLAGS=-j$(nproc) && \
./configure -prefix /opt/Qt${QT_VERSION} -release -opensource -confirm-license -qtnamespace QtOpenCVPython -xcb -xcb-xlib -bundled-xcb-xinput -no-openssl -no-dbus -skip qt3d -skip qtactiveqt -skip qtcanvas3d -skip qtconnectivity -skip qtdatavis3d -skip qtdoc -skip qtgamepad -skip qtgraphicaleffects -skip qtimageformats -skip qtlocation -skip qtmultimedia -skip qtpurchasing -skip qtqa -skip qtremoteobjects -skip qtrepotools -skip qtscript -skip qtscxml -skip qtsensors -skip qtserialbus -skip qtserialport -skip qtspeech -skip qttranslations -skip qtwayland -skip qtwebchannel -skip qtwebengine -skip qtwebsockets -skip qtwebview -skip xmlpatterns -skip declarative -make libs && \
@@ -104,7 +93,7 @@ RUN mkdir ~/yasm_sources && \
RUN mkdir ~/libvpx_sources && \
cd ~/libvpx_sources && \
- git clone --depth 1 https://chromium.googlesource.com/webm/libvpx.git && \
+ git clone --depth 1 -b ${VPX_VERSION} https://chromium.googlesource.com/webm/libvpx.git && \
cd libvpx && \
./configure --prefix="/ffmpeg_build" --disable-examples --disable-unit-tests --enable-vp9-highbitdepth --as=yasm --enable-pic --enable-shared && \
make -j$(getconf _NPROCESSORS_ONLN) && \
diff --git a/find_version.py b/find_version.py
index 274c93e6..13e8003c 100644
--- a/find_version.py
+++ b/find_version.py
@@ -65,7 +65,7 @@
else:
# local version identifier, not to be published on PyPI
version = git_hash
- opencv_version += ".{}".format(version)
+ opencv_version += "+{}".format(version)
with open("cv2/version.py", "w") as f:
f.write('opencv_version = "{}"\n'.format(opencv_version))
diff --git a/multibuild b/multibuild
index bce1637e..0714f52e 160000
--- a/multibuild
+++ b/multibuild
@@ -1 +1 @@
-Subproject commit bce1637e202cb52b0e7ea42baa1cccc894b82806
+Subproject commit 0714f52ea1ea57a0bc33c7f8b74bae457e1fa8e0
diff --git a/opencv b/opencv
index 638a0788..b31bc1a2 160000
--- a/opencv
+++ b/opencv
@@ -1 +1 @@
-Subproject commit 638a0788fe8ba58d735ac0eddbc8297bb3105da0
+Subproject commit b31bc1a2954e22d87f8384212c5e3dfbe7024f16
diff --git a/opencv_contrib b/opencv_contrib
index b9ccfebf..f7d6288a 160000
--- a/opencv_contrib
+++ b/opencv_contrib
@@ -1 +1 @@
-Subproject commit b9ccfebf24d993ce5009c1b28c2bcbbdb3721a2c
+Subproject commit f7d6288aeb38ff1b8af70ecf50a98258e8cd1bef
diff --git a/opencv_extra b/opencv_extra
index a13afb81..0e3b933a 160000
--- a/opencv_extra
+++ b/opencv_extra
@@ -1 +1 @@
-Subproject commit a13afb81a66b95c25d83bcc4d661ae516bdfedde
+Subproject commit 0e3b933aa762b28b54a40034c58f8c734f1ed759
diff --git a/patch_auditwheel_whitelist.py b/patch_auditwheel_whitelist.py
index 150f97ca..b396ab55 100644
--- a/patch_auditwheel_whitelist.py
+++ b/patch_auditwheel_whitelist.py
@@ -3,26 +3,6 @@
from auditwheel import policy
-
-def add_zlib_versions():
- with open(join(dirname(abspath(policy.__file__)), "manylinux-policy.json"), 'r') as manylinux_policy:
- manylinux_policy_lines = manylinux_policy.readlines()
-
- manylinux_policy_data = ""
- for line in manylinux_policy_lines:
- if "ZLIB" in line:
- if len(line) > 22:
- updated_line = line[:-2] + ', "1.2.9", "1.2.12"]'
- else:
- updated_line = line[:-2] + '"1.2.9", "1.2.12"]'
- manylinux_policy_replacement = line.replace(line, updated_line)
- else:
- manylinux_policy_replacement = line
- manylinux_policy_data = manylinux_policy_data + manylinux_policy_replacement
-
- with open(join(dirname(abspath(policy.__file__)), "manylinux-policy.json"), 'w') as manylinux_final_policy:
- manylinux_final_policy.write(manylinux_policy_data)
-
def add_whitelisted_libs():
policies = None
@@ -35,7 +15,5 @@ def add_whitelisted_libs():
with open(join(dirname(abspath(policy.__file__)), "manylinux-policy.json"), "w") as f:
f.write(json.dumps(policies))
-
if __name__ == '__main__':
- add_zlib_versions()
add_whitelisted_libs()
diff --git a/patches/patchQtPlugins b/patches/patchQtPlugins
index a05a5f83..70c6975a 100644
--- a/patches/patchQtPlugins
+++ b/patches/patchQtPlugins
@@ -9,7 +9,7 @@ index 4c0b3880fc..dffa0a4caa 100644
+ install(DIRECTORY ${Qt5_DIR}/../../../plugins DESTINATION lib/qt)
+ endif()
+ if(UNIX AND NOT APPLE)
-+ install(DIRECTORY /opt/Qt5.15.0/plugins DESTINATION lib/qt)
++ install(DIRECTORY /opt/Qt5.15.13/plugins DESTINATION lib/qt)
+ install(DIRECTORY /usr/share/fonts DESTINATION lib/qt)
+ endif()
if(HAVE_QT_OPENGL)
diff --git a/pyproject.toml b/pyproject.toml
index 5993a2ac..270a25d1 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -1,13 +1,13 @@
[build-system]
requires = [
- "setuptools==59.2.0", "wheel==0.37.0", "cmake>=3.1", "pip",
- "scikit-build>=0.13.2",
+ "cmake>=3.13",
"numpy==1.13.3; python_version=='3.6' and platform_machine != 'aarch64' and platform_machine != 'arm64'",
- "numpy==1.14.5; python_version=='3.7' and platform_machine != 'aarch64' and platform_machine != 'arm64'",
- "numpy==1.17.3; python_version=='3.8' and platform_machine != 'aarch64' and platform_machine != 'arm64'",
- "numpy==1.19.3; python_version<='3.9' and sys_platform == 'linux' and platform_machine == 'aarch64'",
- "numpy==1.21.0; python_version<='3.9' and sys_platform == 'darwin' and platform_machine == 'arm64'",
- "numpy==1.19.3; python_version=='3.9' and platform_machine != 'aarch64' and platform_machine != 'arm64'",
- "numpy==1.21.2; python_version>='3.10'",
- "numpy==1.21.4; python_version>='3.10' and platform_system=='Darwin'"
+ "numpy==1.17.0; python_version=='3.7' and platform_machine != 'aarch64' and platform_machine != 'arm64'",
+ "numpy==1.17.5; python_version=='3.8' and platform_machine != 'aarch64' and platform_machine != 'arm64'",
+ "numpy==1.19.3; python_version<'3.9' and sys_platform == 'linux' and platform_machine == 'aarch64'",
+ "numpy==1.21.0; python_version<'3.9' and sys_platform == 'darwin' and platform_machine == 'arm64'",
+ "numpy>=2.0.0; python_version>='3.9'",
+ "pip",
+ "scikit-build>=0.14.0",
+ "setuptools==59.2.0",
]
diff --git a/setup.py b/setup.py
index 11d2cb0f..12eac0d5 100644
--- a/setup.py
+++ b/setup.py
@@ -7,8 +7,7 @@
import re
import sysconfig
import platform
-import skbuild
-from skbuild import cmaker
+from skbuild import cmaker, setup
def main():
@@ -25,19 +24,26 @@ def main():
install_requires = [
'numpy>=1.13.3; python_version<"3.7"',
- 'numpy>=1.14.5; python_version>="3.7"',
+ 'numpy>=1.17.0; python_version>="3.7"', # https://github.com/numpy/numpy/pull/13725
'numpy>=1.17.3; python_version>="3.8"',
'numpy>=1.19.3; python_version>="3.9"',
'numpy>=1.21.2; python_version>="3.10"',
'numpy>=1.19.3; python_version>="3.6" and platform_system=="Linux" and platform_machine=="aarch64"',
'numpy>=1.21.0; python_version<="3.9" and platform_system=="Darwin" and platform_machine=="arm64"',
'numpy>=1.21.4; python_version>="3.10" and platform_system=="Darwin"',
+ "numpy>=1.23.5; python_version>='3.11'",
+ "numpy>=1.26.0; python_version>='3.12'"
]
python_version = cmaker.CMaker.get_python_version()
- python_lib_path = cmaker.CMaker.get_python_library(python_version).replace(
- "\\", "/"
- )
+ python_lib_path = cmaker.CMaker.get_python_library(python_version) or ""
+ # HACK: For Scikit-build 0.17.3 and newer that returns None or empty sptring for PYTHON_LIBRARY in manylinux2014
+ # A small release related to PYTHON_LIBRARY handling changes in 0.17.2; scikit-build 0.17.3 returns an empty string from get_python_library if no Python library is present (like on manylinux), where 0.17.2 returned None, and previous versions returned a non-existent path. Note that adding REQUIRED to find_package(PythonLibs will fail, but it is incorrect (you must not link to libPython.so) and was really just injecting a non-existent path before.
+ # TODO: Remove the hack when the issue is handled correctly in main OpenCV CMake.
+ if python_lib_path == "":
+ python_lib_path = "libpython%sm.a" % python_version
+ python_lib_path = python_lib_path.replace("\\", "/")
+
python_include_dir = cmaker.CMaker.get_python_include_dir(python_version).replace(
"\\", "/"
)
@@ -97,7 +103,6 @@ def main():
"cv2": ["*%s" % sysconfig.get_config_vars().get("SO"), "version.py"]
+ (["*.dll"] if os.name == "nt" else [])
+ ["LICENSE.txt", "LICENSE-3RD-PARTY.txt"],
- "cv2.data": ["*.xml"],
}
# Files from CMake output to copy to package.
@@ -109,6 +114,12 @@ def main():
else []
)
+
+ (
+ [r"lib/libOrbbecSDK.dylib", r"lib/libOrbbecSDK.\d.\d.dylib", r"lib/libOrbbecSDK.\d.\d.\d.dylib"]
+ if platform.system() == "Darwin" and platform.machine() == "arm64"
+ else []
+ )
+ +
# In Windows, in python/X.Y//; in Linux, in just python/X.Y/.
# Naming conventions vary so widely between versions and OSes
# had to give up on checking them.
@@ -123,13 +134,10 @@ def main():
+
[
r"python/cv2/.*config.*.py"
- ],
- "cv2.data": [ # OPENCV_OTHER_INSTALL_PATH
- ("etc" if os.name == "nt" else "share/opencv5") + r"/haarcascades/.*\.xml"
- ],
- "cv2.gapi": [
- "python/cv2" + r"/gapi/.*\.py"
- ],
+ ]
+ +
+ [ r"python/cv2/py.typed" ] if sys.version_info >= (3, 6) else []
+ ,
"cv2.mat_wrapper": [
"python/cv2" + r"/mat_wrapper/.*\.py"
],
@@ -141,21 +149,42 @@ def main():
],
}
+ if sys.version_info >= (3, 6):
+ rearrange_cmake_output_data["cv2.typing"] = ["python/cv2" + r"/typing/.*\.py"]
+
# Files in sourcetree outside package dir that should be copied to package.
# Raw paths relative to sourcetree root.
files_outside_package_dir = {"cv2": ["LICENSE.txt", "LICENSE-3RD-PARTY.txt"]}
ci_cmake_generator = (
- ["-G", "Visual Studio 14" + (" Win64" if is64 else "")]
+ ["-G", "Visual Studio 16"]
if os.name == "nt"
else ["-G", "Unix Makefiles"]
)
+ generator_variant = []
+ if os.name == "nt":
+ if platform.machine() == "ARM64":
+ generator_variant = [ "-A", "ARM64",
+ # Emulated cmake requires following flags to correctly detect
+ # target architecture for windows/arm64 build
+ "-DOPENCV_WORKAROUND_CMAKE_20989=ON",
+ "-DCMAKE_SYSTEM_PROCESSOR=ARM64"]
+ elif is64:
+ generator_variant = ["-DCMAKE_GENERATOR_PLATFORM=x64"]
+ else:
+ generator_variant = ["-DCMAKE_GENERATOR_PLATFORM=Win32"]
+
+ print("Generator variant: ", generator_variant)
+
+ ci_cmake_generator = ci_cmake_generator + generator_variant
+
cmake_args = (
(ci_cmake_generator if is_CI_build else [])
+ [
# skbuild inserts PYTHON_* vars. That doesn't satisfy opencv build scripts in case of Py3
"-DPYTHON3_EXECUTABLE=%s" % sys.executable,
+ "-DPYTHON_DEFAULT_EXECUTABLE=%s" % sys.executable,
"-DPYTHON3_INCLUDE_DIR=%s" % python_include_dir,
"-DPYTHON3_LIBRARY=%s" % python_lib_path,
"-DBUILD_opencv_python3=ON",
@@ -178,18 +207,6 @@ def main():
"-DPYTHON3_LIMITED_API=ON",
"-DBUILD_OPENEXR=ON",
]
- + (
- # CMake flags for windows/arm64 build
- ["-DCMAKE_GENERATOR_PLATFORM=ARM64",
- # Emulated cmake requires following flags to correctly detect
- # target architecture for windows/arm64 build
- "-DOPENCV_WORKAROUND_CMAKE_20989=ON",
- "-DCMAKE_SYSTEM_PROCESSOR=ARM64"]
- if platform.machine() == "ARM64" and sys.platform == "win32"
- # If it is not defined 'linker flags: /machine:X86' on Windows x64
- else ["-DCMAKE_GENERATOR_PLATFORM=x64"] if is64 and sys.platform == "win32"
- else []
- )
+ (
["-DOPENCV_EXTRA_MODULES_PATH=" + os.path.abspath("opencv_contrib/modules")]
if build_contrib
@@ -246,23 +263,16 @@ def main():
cmake_args.append("-DWITH_LAPACK=ON")
cmake_args.append("-DENABLE_PRECOMPILED_HEADERS=OFF")
- # https://github.com/scikit-build/scikit-build/issues/479
- if "CMAKE_ARGS" in os.environ:
- import shlex
-
- cmake_args.extend(shlex.split(os.environ["CMAKE_ARGS"]))
- del shlex
-
# works via side effect
RearrangeCMakeOutput(
rearrange_cmake_output_data, files_outside_package_dir, package_data.keys()
)
- skbuild.setup(
+ setup(
name=package_name,
version=package_version,
url="https://github.com/opencv/opencv-python",
- license="MIT",
+ license="Apache 2.0",
description="Wrapper package for OpenCV python bindings.",
long_description=long_description,
long_description_content_type="text/markdown",
@@ -273,13 +283,13 @@ def main():
install_requires=install_requires,
python_requires=">=3.6",
classifiers=[
- "Development Status :: 5 - Production/Stable",
+ "Development Status :: 5 - Alpha",
"Environment :: Console",
"Intended Audience :: Developers",
"Intended Audience :: Education",
"Intended Audience :: Information Technology",
"Intended Audience :: Science/Research",
- "License :: OSI Approved :: MIT License",
+ "License :: OSI Approved :: Apache Software License",
"Operating System :: MacOS",
"Operating System :: Microsoft :: Windows",
"Operating System :: POSIX",
@@ -292,6 +302,8 @@ def main():
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
+ "Programming Language :: Python :: 3.11",
+ "Programming Language :: Python :: 3.12",
"Programming Language :: C++",
"Programming Language :: Python :: Implementation :: CPython",
"Topic :: Scientific/Engineering",
@@ -302,8 +314,9 @@ def main():
cmake_source_dir=cmake_source_dir,
)
+ print("OpenCV is raising funds to keep the library free for everyone, and we need the support of the entire community to do it. Donate to OpenCV on GitHub:\nhttps://github.com/sponsors/opencv\n")
-class RearrangeCMakeOutput(object):
+class RearrangeCMakeOutput:
"""
Patch SKBuild logic to only take files related to the Python package
and construct a file hierarchy that SKBuild expects (see below)
@@ -384,7 +397,6 @@ def _classify_installed_files_override(
p.replace(os.path.sep, "/") for p in install_relpaths
]
relpaths_zip = list(zip(fslash_install_relpaths, install_relpaths))
- del install_relpaths, fslash_install_relpaths
final_install_relpaths = []
@@ -393,10 +405,29 @@ def _classify_installed_files_override(
# add lines from the old __init__.py file to the config file
with open(os.path.join(os.path.dirname(os.path.abspath(__file__)), 'scripts', '__init__.py'), 'r') as custom_init:
custom_init_data = custom_init.read()
- with open('%spython/cv2/config-%s.py'
- % (cmake_install_dir, sys.version_info[0]), 'w') as opencv_init_config:
+
+ # OpenCV generates config with different name for case with PYTHON3_LIMITED_API=ON
+ config_py = os.path.join(cmake_install_dir, 'python', 'cv2', 'config-%s.%s.py'
+ % (sys.version_info[0], sys.version_info[1]))
+ if not os.path.exists(config_py):
+ config_py = os.path.join(cmake_install_dir, 'python', 'cv2', 'config-%s.py' % sys.version_info[0])
+
+ with open(config_py, 'w') as opencv_init_config:
opencv_init_config.write(custom_init_data)
+ if sys.version_info >= (3, 6):
+ for p in install_relpaths:
+ if p.endswith(".pyi"):
+ target_rel_path = os.path.relpath(p, "python/cv2")
+ cls._setuptools_wrap._copy_file(
+ os.path.join(cmake_install_dir, p),
+ os.path.join(cmake_install_dir, "cv2", target_rel_path),
+ hide_listing=False,
+ )
+ final_install_relpaths.append(os.path.join("cv2", target_rel_path))
+
+ del install_relpaths, fslash_install_relpaths
+
for package_name, relpaths_re in cls.package_paths_re.items():
package_dest_reldir = package_name.replace(".", os.path.sep)
for relpath_re in relpaths_re:
diff --git a/travis_config.sh b/travis_config.sh
index 366d35ad..903ceafb 100644
--- a/travis_config.sh
+++ b/travis_config.sh
@@ -16,7 +16,7 @@ function bdist_wheel_cmd {
local abs_wheelhouse=$1
# install all required packages in pyproject.toml, because bdist_wheel does not do it
python${PYTHON_VERSION} -m pip install toml && python${PYTHON_VERSION} -c 'import toml; c = toml.load("pyproject.toml"); print("\n".join(c["build-system"]["requires"]))' | python${PYTHON_VERSION} -m pip install -r /dev/stdin
- CI_BUILD=1 python${PYTHON_VERSION} setup.py bdist_wheel --py-limited-api=cp36 -v
+ CI_BUILD=1 python${PYTHON_VERSION} setup.py bdist_wheel --py-limited-api=cp37 -v
cp dist/*.whl $abs_wheelhouse
if [ -z "$IS_OSX" ]; then
# this path can be changed in the latest manylinux image
@@ -34,8 +34,14 @@ if [ -n "$IS_OSX" ]; then
export MAKEFLAGS="-j$(sysctl -n hw.ncpu)"
else
echo " > Linux environment "
- export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/Qt5.15.0/lib
+ export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/opt/Qt5.15.13/lib
export MAKEFLAGS="-j$(grep -E '^processor[[:space:]]*:' /proc/cpuinfo | wc -l)"
+ CURRENT_ARCH=$(uname -m)
+ if [[ $CURRENT_ARCH == 'aarch64' ]]; then
+ # To avoid network issues with pypi.org on OpenCV CN machines
+ export PIP_INDEX_URL=https://pypi.tuna.tsinghua.edu.cn/simple
+ echo "Running for linux aarch64"
+ fi
fi
if [ -n "$IS_OSX" ]; then
@@ -44,13 +50,13 @@ if [ -n "$IS_OSX" ]; then
BREW_SLOW_BUILIDING_PACKAGES=$(printf '%s\n' \
"cmake 15" \
- "ffmpeg_opencv 10" \
+ "ffmpeg 10" \
)
function generate_ffmpeg_formula {
local FF="ffmpeg"
- local LFF="ffmpeg_opencv"
- local FF_FORMULA; FF_FORMULA=$(brew formula "${FF}${FFMPEG_FORMULA_VERSION}")
+ local LFF="ffmpeg"
+ local FF_FORMULA; FF_FORMULA=$(brew formula "${FF}")
local LFF_FORMULA; LFF_FORMULA="$(dirname "$FF_FORMULA")/${LFF}.rb"
local REGENERATE
@@ -70,9 +76,8 @@ if [ -n "$IS_OSX" ]; then
if [ -n "$REGENERATE" ]; then
echo "Regenerating custom ffmpeg formula"
# Bottle block syntax: https://docs.brew.sh/Bottles#bottle-dsl-domain-specific-language
- # FfmpegAT4 is a class in ffmpeg@4 formula
perl -wpe 'BEGIN {our ($found_blank, $bottle_block);}
- if (/(^class )(FfmpegAT4)(\s.*)/) {$_=$1."FfmpegOpencv".$3."\n"; next;}
+ if (/(^class )(Ffmpeg)(\s.*)/) {$_=$1."Opencv".$3."\n"; next;}
if (!$found_blank && /^$/) {$_.="conflicts_with \"ffmpeg\"\n\n"; $found_blank=1; next;}
if (!$bottle_block && /^\s*bottle do$/) { $bottle_block=1; next; }
if ($bottle_block) { if (/^\s*end\s*$/) { $bottle_block=0} elsif (/^\s*sha256\s/) {$_=""} next; }
@@ -112,9 +117,9 @@ function pre_build {
brew update
generate_ffmpeg_formula
brew_add_local_bottles
- brew install --build-bottle ffmpeg_opencv
+ brew install --build-bottle ffmpeg
# It needs when we use not the latest ffmpeg formula
- brew link ffmpeg_opencv
+ brew link ffmpeg
if [ -n "$CACHE_STAGE" ]; then
brew_go_bootstrap_mode 0
@@ -138,7 +143,7 @@ function run_tests {
echo "Running for linux"
- if [ $PYTHON == "python3.6" ]; then
+ if [ $PYTHON == "python3.7" ]; then
$PYTHON -m pip install -U numpy==1.19.4
fi
cd /io/tests
@@ -163,7 +168,7 @@ function pylint_test {
echo "Starting Pylint tests..."
- $PYTHON -m pip install pylint==2.12.2
+ $PYTHON -m pip install pylint==2.15.9
cd /io/tests
$PYTHON -m pylint /io/opencv/samples/python/squares.py
}
diff --git a/travis_osx_brew_cache.sh b/travis_osx_brew_cache.sh
index 1a2a1c6c..42e71446 100644
--- a/travis_osx_brew_cache.sh
+++ b/travis_osx_brew_cache.sh
@@ -265,14 +265,14 @@ function _brew_parse_bottle_json {
local JSON; JSON="${1:?}"; shift
- local JSON_DATA; JSON_DATA=$(python2.7 -c 'if True:
+ local JSON_DATA; JSON_DATA=$(python3 -c 'if True:
import sys,json; j=json.load(open(sys.argv[1],"rb")); [name]=j.keys(); [pdata]=j.values()
- print name
- print pdata["formula"]["pkg_version"]
- print pdata["bottle"]["rebuild"]
+ print(name)
+ print(pdata["formula"]["pkg_version"])
+ print(pdata["bottle"]["rebuild"])
[(tag_name, tag_dict)]=pdata["bottle"]["tags"].items()
- print tag_name
- print tag_dict["sha256"]
+ print(tag_name)
+ print(tag_dict["sha256"])
' "$JSON")
unset JSON
@@ -292,15 +292,15 @@ function _brew_parse_package_info {
PACKAGE="${1:?}"; shift
OS_CODENAME="${1:?}"; shift
- local JSON_DATA; JSON_DATA=$(python2.7 -c 'if True:
+ local JSON_DATA; JSON_DATA=$(python3 -c 'if True:
import sys, json, subprocess; j=json.loads(subprocess.check_output(("brew","info","--json=v1",sys.argv[1])))
data=j[0]
revision=data["revision"]
# in bottle''s json, revision is included into version; here, they are separate
- print data["versions"]["stable"]+("_"+str(revision) if revision else "")
+ print(data["versions"]["stable"]+("_"+str(revision) if revision else ""))
bottle_data=data["bottle"].get("stable",{"rebuild":"","files":{}})
- print bottle_data["rebuild"]
- print bottle_data["files"].get(sys.argv[2],{"sha256":"!?"})["sha256"] #prevent losing trailing blank line to command substitution
+ print(bottle_data["rebuild"])
+ print(bottle_data["files"].get(sys.argv[2],{"sha256":"!?"})["sha256"]) #prevent losing trailing blank line to command substitution
' \
"$PACKAGE" "$OS_CODENAME"); JSON_DATA="${JSON_DATA%\!\?}" #!? can't occur in a hash