%!s(
Parameter’s name | Parameter’s type | Description |
---|---|---|
out_filters |
string | Optional. Comma separated list of model outputs to return. |
input |
image | |
detect_objects |
bool | Detect objects and tag image |
detect_faces |
bool | Detect faces on image |
detect_poses |
bool | Detect poses for persons on image |
build_caption |
bool | Build caption for image |
curl -X POST \ -H 'Authorization: Bearer YOUR_USER_TOKEN' \ -H 'Content-Type: multipart/form-data' \ -F "out_filters=output" \ -F "input=input_value" \ -F "detect_objects=detect_objects_value" \ -F "detect_faces=detect_faces_value" \ -F "detect_poses=detect_poses_value" \ -F "build_caption=build_caption_value" \ https://dev.kibernetika.io/api/v0.2/workspace/kuberlab-demo/serving/photo-inside-picture/form-data
curl -X POST \ -H 'Authorization: Bearer YOUR_USER_TOKEN' \ -H 'Content-Type: application/json' \ -d ' { "build_caption": true, "detect_faces": true, "detect_objects": true, "detect_poses": true, "input": "base64_encoded_input_contents" } ' https://dev.kibernetika.io/api/v0.2/workspace/kuberlab-demo/serving/photo-inside-picture/proxy
import kclient from kclient.utils import client, request cl = client.with_bearer_token("YOUR_USER_TOKEN") serving_api = kclient.api.serving_api.ServingApi(cl) data = request.make(data={ "detect_objects": true, "detect_faces": true, "detect_poses": true, "build_caption": true, }, files={ "input": "/path/to/input_file", }) resp = serving_api.serving_proxy(data, "kuberlab-demo", "photo-inside-picture")
{ "output": "base64_encoded_image", "table_output": [ { "type": "object", "name": "person", "prob": 0.99, "image": "base64_encoded_image" } ], "caption_output": [ "a group of people walking down a street." ] }