synthetics_handwritten_OCR/OCR_earsing/README.md

727 B

OCR Earsing

This repository contains the code for erasing the OCR text from the images. Code is written based on OCR_SAM

Have 2 method to earse the text from the image:

  • Traditional method: using the bounding box of the text to earse the text, and use function OpenCV to earse the text.
  • Deep learning method: using the bounding box of the text, segment the text based on SAM (Segment Anything) and use diffuse model to earse the text.

In my code, I use the deep learning method to earse the text from the image.

Installation

pip install -r requirements.txt

Run

python ocr_eraser.py