opencv

📁 g1joshi/agent-skills 📅 Feb 10, 2026
1
总安装量
1
周安装量
#76537
全站排名
安装命令
npx skills add https://github.com/g1joshi/agent-skills --skill opencv

Agent 安装分布

mcpjam 1
claude-code 1
replit 1
junie 1
windsurf 1
zencoder 1

Skill 文档

OpenCV

OpenCV is the fundamental library for Image Processing. v5.0 (2025) modernizes deep learning support and licensing.

When to Use

  • Image Manipulation: Resizing, cropping, color space conversion (BGR -> RGB).
  • Classic CV: Edge detection (Canny), Feature matching (SIFT/ORB).
  • Video I/O: Reading/Writing webcams or video files.

Core Concepts

BGR

OpenCV reads images as Blue-Green-Red (not RGB) by default. History quirks.

cv::Mat

The core matrix structure (in C++). In Python, it’s just a NumPy array.

DNN Module

Running darknet/onnx models directly in OpenCV (lightweight inference).

Best Practices (2025)

Do:

  • Use it for Preprocessing: cv2.resize() is highly optimized.
  • Use headless: pip install opencv-python-headless for server deployments (smaller, no GUI deps).

Don’t:

  • Don’t implement Deep Learning training: Use PyTorch. Use OpenCV only for inference/preprocessing.

References