djomo commited on
Commit
1616f3a
1 Parent(s): 7e929c6

Upload handler.py

Browse files
Files changed (1) hide show
  1. handler.py +6 -1
handler.py CHANGED
@@ -8,7 +8,12 @@ from paddleocr import PaddleOCR, draw_ocr
8
  class EndpointHandler():
9
  def __init__(self, path=""):
10
 
11
- self.pipeline = PaddleOCR(lang="en",ocr_version="PP-OCRv4",show_log = False,use_gpu=True)
 
 
 
 
 
12
 
13
 
14
  def __call__(self, data: Any) -> List[List[Dict[str, float]]]:
 
8
  class EndpointHandler():
9
  def __init__(self, path=""):
10
 
11
+ self.pipeline = PaddleOCR(lang="en",ocr_version="PP-OCRv4",
12
+ show_log = False,use_gpu=True,
13
+ det_model_dir=path,
14
+ cls_model_dir=path,
15
+ rec_model_dir=path
16
+ )
17
 
18
 
19
  def __call__(self, data: Any) -> List[List[Dict[str, float]]]: