From f6b37b42f217a0d2a50f1cc9082742d3855788dc Mon Sep 17 00:00:00 2001 From: Dillon Laird Date: Sun, 11 Aug 2024 13:17:32 -0700 Subject: [PATCH] added test cases --- tests/integ/test_tools.py | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/tests/integ/test_tools.py b/tests/integ/test_tools.py index 68f5d396..1d99ff69 100644 --- a/tests/integ/test_tools.py +++ b/tests/integ/test_tools.py @@ -5,17 +5,18 @@ blip_image_caption, clip, closest_mask_distance, - florencev2_image_caption, depth_anything_v2, + detr_segmentation, dpt_hybrid_midas, + florencev2_image_caption, + florencev2_object_detection, + florencev2_roberta_vqa, + florencev2_ocr, generate_pose_image, generate_soft_edge_image, - florencev2_object_detection, - detr_segmentation, git_vqa_v2, grounding_dino, grounding_sam, - florencev2_roberta_vqa, loca_visual_prompt_counting, loca_zero_shot_counting, ocr, @@ -182,6 +183,14 @@ def test_ocr() -> None: assert any("Region-based segmentation" in res["label"] for res in result) +def test_florencev2_ocr() -> None: + img = ski.data.page() + result = florencev2_ocr( + image=img, + ) + assert any("Region-based segmentation" in res["label"] for res in result) + + def test_mask_distance(): # Create two binary masks mask1 = np.zeros((100, 100), dtype=np.uint8)