leaf_focus/ocr/command.py
def ocr_prepare(input_file: Path, output_file: Path, threshold: int):
    """Prepare an image for OCR."""

    from leaf_focus.ocr.prepare.component import Component

    click.secho("Starting ocr prepare.", bold=True)

    logger = logging.getLogger()
    c = Component(logger)
    c.threshold(input_file, output_file, threshold)

    click.secho("Finished ocr prepare.", bold=True)
Prepare an image for OCR.
Prepare an image for OCR.
Prepare an image for OCR .
def ocr_prepare(input_file: Path, output_file: Path, threshold: int):
    from leaf_focus.ocr.prepare.component import Component
    click.secho("Starting ocr prepare.", bold=True)
    logger = logging.getLogger()
    c = Component(logger)
    c.threshold(input_file, output_file, threshold)
    click.secho("Finished ocr prepare.", bold=True)
def ocr_prepare ( input_file : Path , output_file : Path , threshold : int ) : from leaf_focus . ocr . prepare . component import Component click . secho ( "Starting ocr prepare." , bold = True ) logger = logging . getLogger ( ) c = Component ( logger ) c . threshold ( input_file , output_file , threshold ) click . secho ( "Finished ocr prepare." , bold = True )
Prepare an image for OCR.
Prepare an image for OCR .
"""Prepare an image for OCR."""
input_file
Path
output_file
Path
threshold
int