Skip to content

Commit

Permalink
Default use paddle ocr to false to not break jupyter notebook example
Browse files Browse the repository at this point in the history
Add paddleocr to requirements
  • Loading branch information
aliencaocao committed Oct 29, 2024
1 parent be04aff commit fa9c69f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,5 @@ dill
accelerate
timm
einops==0.8.0
paddlepaddle
paddleocr
2 changes: 1 addition & 1 deletion utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ def get_xywh_yolo(input):



def check_ocr_box(image_path, display_img = True, output_bb_format='xywh', goal_filtering=None, easyocr_args=None, use_paddleocr=True):
def check_ocr_box(image_path, display_img = True, output_bb_format='xywh', goal_filtering=None, easyocr_args=None, use_paddleocr=False):
if use_paddleocr:
result = paddle_ocr.ocr(image_path, cls=False)[0]
coord = [item[0] for item in result]
Expand Down

0 comments on commit fa9c69f

Please sign in to comment.