Skip to content

Commit

Permalink
fix: cudaopencv
Browse files Browse the repository at this point in the history
  • Loading branch information
mrhanhan committed Mar 8, 2024
1 parent b26b7f6 commit a87ef2d
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions _posts/工作日志/OpenCV/2024-03-08-opencv-support-cuda.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
---
layout: post
category: [工作日志, OpenCV]
tags: [OpenCV, 日志]
title: OpenCV 支持CUDA
---

> 从源码编译 opencv 和 opencv-contrib 并指支撑 cuda

```shell
git clone https://github.com/opencv/opencv.git
git clone https://github.com/opencv/opencv-contrib.git
```

```shell
mkdir build
cd build
cmake \
-D OPENCV_DNN_CUDA=ON \
-D WITH_CUDA=ON \
-D WITH_CUDNN=ON \
-D OPENCV_DNN_CUDA=ON \
-D OPENCV_ENABLE_NONFREE=ON \
-D OPENCV_EXTRA_MODULES_PATH=../../opencv_contrib/modules \
..

make
```

0 comments on commit a87ef2d

Please sign in to comment.