Skip to content

Commit ba4e04f

Browse files
authored
Merge pull request #29 from aliencaocao/fix-inference-mode
Add torch.inference mode
2 parents 7df99e6 + 7703ae0 commit ba4e04f

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

utils.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ def get_yolo_model(model_path):
6464
return model
6565

6666

67+
@torch.inference_mode()
6768
def get_parsed_content_icon(filtered_boxes, ocr_bbox, image_source, caption_model_processor, prompt=None):
6869
to_pil = ToPILImage()
6970
if ocr_bbox:

0 commit comments

Comments
 (0)