pixano.inference.zero_shot_detection
image_zero_shot_detection(client, media_dir, image, entity, source, classes, box_threshold=0.5, text_threshold=0.5, **client_kwargs)
async
Image zero shot task.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
client
|
PixanoInferenceClient
|
Pixano inference client. |
required |
media_dir
|
Path
|
Media directory. |
required |
image
|
Image
|
Image to generate mask for. |
required |
entity
|
Entity
|
Entity associated with the image. |
required |
source
|
Source
|
The source refering to the model. |
required |
classes
|
list[str] | str
|
List of classes to detect in the image. |
required |
box_threshold
|
float
|
Box threshold for detection in the image. |
0.5
|
text_threshold
|
float
|
Text threshold for detection in the image. |
0.5
|
client_kwargs
|
Additional kwargs for the client to be passed. |
{}
|
Returns:
Type | Description |
---|---|
list[tuple[BBox, Classification]]
|
List of BBoxes and Classifications detected in the image with respect to classes and threshold values. |