From 5a9138026f7310fb27d0b0b5aab589751f056041 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=B8=89=E6=B4=8B=E4=B8=89=E6=B4=8B?= <1258009915@qq.com> Date: Wed, 17 Apr 2024 14:47:58 +0000 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E4=BA=86merge=20pre=5Freleas?= =?UTF-8?q?e=E5=88=86=E6=94=AF=E5=90=8E=E5=AF=BC=E8=87=B4=E5=8F=82?= =?UTF-8?q?=E6=95=B0=E5=90=8D=E4=B8=8D=E4=B8=80=E8=87=B4=E7=9A=84bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/models/ocr_model/utils/inference.py | 2 +- src/start_web.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/models/ocr_model/utils/inference.py b/src/models/ocr_model/utils/inference.py index 63273a8..92bc08c 100644 --- a/src/models/ocr_model/utils/inference.py +++ b/src/models/ocr_model/utils/inference.py @@ -13,7 +13,7 @@ from models.globals import MAX_TOKEN_SIZE def inference( model: TexTeller, tokenizer: RobertaTokenizerFast, - imgs_path: Union[List[str], List[np.ndarray]], + imgs: Union[List[str], List[np.ndarray]], inf_mode: str = 'cpu', num_beams: int = 1, ) -> List[str]: diff --git a/src/start_web.sh b/src/start_web.sh index 6ec8f7b..41e6311 100755 --- a/src/start_web.sh +++ b/src/start_web.sh @@ -1,7 +1,7 @@ #!/usr/bin/env bash set -exu -export CHECKPOINT_DIR="default" +export CHECKPOINT_DIR="/home/lhy/code/TexTeller/src/models/ocr_model/train/train_result/TexTellerv3/checkpoint-648000" export TOKENIZER_DIR="default" streamlit run web.py