Skip to content

Commit

Permalink
added florence2 od
Browse files Browse the repository at this point in the history
  • Loading branch information
dillonalaird committed Aug 21, 2024
1 parent c4e50c8 commit 7867169
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions vision_agent/tools/tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -738,9 +738,10 @@ def florence2_image_caption(image: np.ndarray, detail_caption: bool = True) -> s


def florence2_object_detection(prompt: str, image: np.ndarray) -> List[Dict[str, Any]]:
"""'florence2_object_detection' is a tool that can detect objects given a text
prompt such as a phrase or class names separated by commas. It returns a list of
detected objects as labels and their location as bounding boxes with score of 1.0.
"""'florence2_object_detection' that can detect and count multiple objects given a
text prompt such as category names or referring expressions. The categories in text
prompt are separated by commas. It returns a list of bounding boxes with normalized
coordinates, label names and associated probability scores set to 1.0
Parameters:
prompt (str): The prompt to ground to the image.
Expand Down Expand Up @@ -1525,6 +1526,7 @@ def overlay_heat_map(
florence2_ocr,
florence2_sam2_image,
florence2_sam2_video,
florence2_object_detection,
ixc25_image_vqa,
ixc25_video_vqa,
detr_segmentation,
Expand Down

0 comments on commit 7867169

Please sign in to comment.