zoom_to_object
Crops an image to a specified object's bounding box for close analysis. Uses zero-shot object detection to find the best match.
Instructions
Zoom into an object in the image, allowing you to analyze it more closely. Crop image to the object bounding box and return the cropped image. If many objects are present in the image, will return the 'best' one as represented by object score.
Args:
image_path: path to the image
label: object label to find and crop to
hf_model (optional): huggingface zero-shot object detection model (default = "google/owlvit-large-patch14")
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| label | Yes | ||
| hf_model | No | ||
| image_path | Yes |