Skip to content

yunwoong7/korean_ocr_using_paddleOCR

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Korean OCR using paddleOCR

This is a Korean OCR Python code using the paddleOCR library

Requirements

  • Python 3.7+
  • paddlepaddle
  • paddleocr

You can install it from PyPI:

pip install paddlepaddle # for gpu user please install paddlepaddle-gpu
pip install paddleocr

PaddleOCR

Awesome multilingual OCR toolkits based on PaddlePaddle (practical ultra lightweight OCR system, support 80+ languages recognition, provide data annotation and synthesis tools, support training and deployment among server, mobile, embedded and IoT devices)

This repository is simply configured for PaddleOCR functionality and inspection. If you want to check out the various features of paddleOCR, please refer to the paddleOCR repository.

from main import MyPaddleOCR
 
ocr = MyPaddleOCR()

지원 가능한 언어 목록을 조회하는 기능입니다.

ocr.get_available_langs()

Output :

Available Language : ['ch', 'en', 'korean', 'japan', 'chinese_cht', 'ta', 'te', 'ka', 'latin', 'arabic', 'cyrillic', 'devanagari', 'french', 'german', 'structure']

사용가능한 Model을 조회하는 기능입니다.

ocr.get_available_models()

Output :

#1 Model Vesion : [PP-OCRv3] - Language : ['ch', 'en', 'korean', 'japan', 'chinese_cht', 'ta', 'te', 'ka', 'latin', 'arabic', 'cyrillic', 'devanagari']
#2 Model Vesion : [PP-OCRv2] - Language : ['ch']
#3 Model Vesion : [PP-OCR] - Language : ['ch', 'en', 'french', 'german', 'korean', 'japan', 'chinese_cht', 'ta', 'te', 'ka', 'latin', 'arabic', 'cyrillic', 'devanagari', 'structure']

OCR (Optical Character Recognition)

img_path = 'assets/images/test_image_3.jpg'
ocr.run_ocr(img_path, debug=True)

Output :

[2023/07/06 00:10:29] ppocr DEBUG: dt_boxes num : 4, elapse : 0.8806350231170654
[2023/07/06 00:10:29] ppocr DEBUG: rec_res num  : 4, elapse : 0.25487518310546875
['아래한글', '한글문서', '디자인', '202204']

Releases

No releases published

Packages

No packages published