Skip to content

Commit 76d6110

Browse files
committed
parsed_content
1 parent 9f2dc91 commit 76d6110

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

gradio_demo.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,10 +74,11 @@ def process(
7474
dino_labled_img, label_coordinates, parsed_content_list = get_som_labeled_img(image_save_path, yolo_model, BOX_TRESHOLD = box_threshold, output_coord_in_ratio=True, ocr_bbox=ocr_bbox,draw_bbox_config=draw_bbox_config, caption_model_processor=caption_model_processor, ocr_text=text,iou_threshold=iou_threshold)
7575
image = Image.open(io.BytesIO(base64.b64decode(dino_labled_img)))
7676
print('finish processing')
77-
return image, json.dumps({
77+
parsed_content = json.dumps({
7878
"parsed_content_list": parsed_content_list,
7979
"label_coordinates": label_coordinates,
8080
}, indent=2)
81+
return image, parsed_content
8182

8283

8384

0 commit comments

Comments
 (0)