OCR with python

👤 roamerxv 📦 v1.0.0 ⭐ 4.1 ⬇️ 10.6K 下载
📄 办公效率 免费

📖 技能介绍

OCR Text Recognition

This skill uses PaddleOCR for text recognition, supporting both Chinese and English.

Quick Start

Basic Usage

Perform OCR recognition directly on image or PDF files:

from paddleocr import PaddleOCR

ocr = PaddleOCR(lang='ch')
result = ocr.predict("file_path.jpg")

Dependency Installation

Install dependencies before first use:

pip3 install paddlepaddle paddleocr

Output Format

Recognition results return JSON containing:

  • rec_texts: List of recognized text
  • rec_scores: Confidence score for each text

Typical Use Cases

  1. PDF Scans: Use PyMuPDF to extract images first, then OCR
  2. Image Text Recognition: Perform OCR directly on images
  3. Multi-page PDFs: Process page by page

    7w4.net提供免费和付费技能下载。

Scripts

Common scripts are located in the scripts/ directory.

🤖 AI 评测

这个 OCR 技能质量中规中矩,优点是支持中文英文、能处理扫描版 PDF 和图片,功能比较实用。文档写得很清晰,中英文都有,上手容易。不足之处是缺少依赖说明文件,示例代码和实际脚本的用法不一致,容易让人困惑,另外没有测试代码,质量保障不足。总体来说能用,但细节打磨还需加强。

📊 多维度评分

适应性4
规范性3.8
有效性4
可靠性4.2
可信度4.8

📁 包含文件 (4 个)

📄 SKILL.md 1.1 KB
📄 SKILL.zh-CN.md 1021 B
📄 _meta.json 129 B
📄 scripts/ocr.py 3 KB