GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - Breakthrough/opencv-python-cuda: Precompiled NVIDIA® CUDA™ enabled opencv-python package, all batteries included.

BranchesTags
Open more actions menu
 
 

Latest commit

 

History

1,142 Commits
1,142 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
_build_backend
_build_backend
 
 
cv2
cv2
 
 
docs
docs
 
 
multibuild @ 4546f4d
multibuild @ 4546f4d
 
 
opencv @ 40738fb
opencv @ 40738fb
 
 
opencv_contrib @ 755e506
opencv_contrib @ 755e506
 
 
opencv_extra @ 3becd94
opencv_extra @ 3becd94
 
 
patches
patches
 
 
scripts
scripts
 
 
tests
tests
 
 
tools
tools
 
 
.gitignore
.gitignore
 
 
.gitmodules
.gitmodules
 
 
CONTRIBUTING.md
CONTRIBUTING.md
 
 
LICENSE-3RD-PARTY.txt
LICENSE-3RD-PARTY.txt
 
 
LICENSE.txt
LICENSE.txt
 
 
MANIFEST.in
MANIFEST.in
 
 
README.md
README.md
 
 
pyproject.toml
pyproject.toml
 
 
setup.py
setup.py
 
 

Repository files navigation

opencv-python-cuda

Pre-built NVIDIA® CUDA™ enabled OpenCV wheels for Python - batteries included.

Latest release Platform License

This is a fork of the official opencv-python project that ships fully standalone CUDA-enabled OpenCV builds. No CUDA Toolkit, cuDNN, or other NVIDIA SDK needs to be installed - every required runtime library is bundled in the wheel, including hardware video decoding and encoding (NVDEC/NVENC). Once installed, the following should just work:

import cv2
print(cv2.cuda.getCudaEnabledDeviceCount())

See the project homepage for more documentation.

Requirements

  • Windows x64 (the only platform packages are currently produced for)
  • NVIDIA GPU - Maxwell class (GeForce GTX 900 series) or newer
  • NVIDIA driver - the wheel links directly against driver libraries, so an up-to-date driver must be installed for import cv2 to succeed
  • Python 3.7 or newer - a single abi3 wheel covers all supported Python versions

Installation

The wheels are too large for PyPI, so they are served from a package index hosted alongside this documentation. Install by name with pip:

pip install opencv-python-cuda --extra-index-url https://breakthrough.github.io/opencv-python-cuda/packages/

or with uv:

uv pip install opencv-python-cuda --extra-index-url https://breakthrough.github.io/opencv-python-cuda/packages/

This installs the newest release, which is OpenCV 5. OpenCV 5 has breaking API changes (see the upstream change logs). To stay on OpenCV 4.x, ask for a version below 5:

pip install "opencv-python-cuda<5" --extra-index-url https://breakthrough.github.io/opencv-python-cuda/packages/

The wheel itself downloads from the Releases page and its SHA-256 hash is verified during installation. numpy and other dependencies still come from PyPI. Then import the cv2 package as usual.

Manual installation

  1. Download the latest opencv_python_cuda-*-win_amd64.whl from the Releases page.

  2. Install it with pip (or another package manager like uv):

    pip install opencv_python_cuda-<version>-win_amd64.whl
    

Note

If you have a previous manually-installed (not via pip) version of OpenCV (e.g. a cv2 module in the root of Python's site-packages), remove it before installing to avoid conflicts. Also make sure your pip is up to date (19.3 is the minimum supported version): pip install --upgrade pip.

What's included

  • All OpenCV modules that can be built with CUDA support
  • Hardware-accelerated video decoding and encoding via NVDEC/NVENC (cv2.cudacodec)
  • FFmpeg for video I/O
  • All required CUDA runtime libraries, bundled in the wheel

Non-free algorithms (e.g. SURF) are excluded - see the FAQ below.

Documentation

  • Project homepage - downloads and overview
  • CUDA Compatibility Reference - GPU architectures, compute capabilities, and CUDA toolkit support
  • Workflow Guide - repository setup, triggering builds, and wheel size strategy

Frequently Asked Questions

For general OpenCV questions, refer to the FAQ in the upstream project.

Q: Which OpenCV versions are available?

A: Two release lines are maintained: OpenCV 5.x, built from the 5.x-cuda branch (the default), and OpenCV 4.x, built from the 4.x-cuda branch. Both are published to the same package index; use a version specifier such as "opencv-python-cuda<5" to select 4.x.

Q: Why can't I pip install opencv-python-cuda from PyPI?

A: The package is far too large for PyPI and exceeds its project size limits. Instead, a PEP 503 package index is published at https://breakthrough.github.io/opencv-python-cuda/packages/, which points at the wheels on the Releases page. Pass it with --extra-index-url as shown in Installation, or download the wheel manually.

Q: Is --extra-index-url safe to use?

A: With --extra-index-url, pip also consults PyPI for the same package name and picks whichever index offers the highest version. opencv-python-cuda is not published on PyPI, so this is a theoretical concern only, but if you want to rule it out entirely, download the wheel from the Releases page and install it by file path instead.

Q: Why does import cv2 fail with "DLL load failed"?

A: The wheel requires an NVIDIA driver to be installed. On machines without one (or with a very old driver), the bundled CUDA and video codec libraries cannot be loaded.

Q: Why are non-free algorithms excluded?

A: Non-free algorithms such as SURF are patented and cannot be distributed as built binaries. Note that SIFT is included, due to patent expiration as of OpenCV 4.3.0 / 3.4.10. See opencv-python#126 for more info.

Licensing

The opencv-python-cuda package (i.e. the scripts in this repository) is available under the MIT license.

  • OpenCV itself is available under the Apache 2 license.
  • All wheels are distributed with FFmpeg, licensed under the LGPLv2.1, and redistributable portions of the NVIDIA® CUDA™ SDK under the NVIDIA Software License Agreement (EULA).
  • The packages include other binaries as well; the full list of licenses can be found in LICENSE-3RD-PARTY.txt.

By downloading and using the software, you agree to fully comply with the terms and conditions of the CUDA EULA.

About

Precompiled NVIDIA® CUDA™ enabled opencv-python package, all batteries included.

breakthrough.github.io/opencv-python-cuda/

Resources

Readme
License

Contributing

Contributing
Activity

Stars

7 stars

Watchers

0 watching

Forks

1 fork
Report repository

Releases

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.