Run OpenCV on Cloud Run with GPU acceleration

The following repository shows how to use GPUs on Cloud Run to accelerate OpenCVworkloads with CUDA. The demo uses the Farneback algorithm for estimating optical flowon your webcam feed, and lets you compare CPU-only performance with GPU-accelerated performance.

See the repository atOpenCV CUDA accelerated demo on Cloud Run with GPU support.

Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025-12-15 UTC.