API Guide

POST object-detection

POST https://nvision.nipa.cloud/api/v1/object-detection

This endpoint allows you to get free cakes.

Headers

Name
Type
Description

Authentication

string

ApiKey: Authentication token to track down who is requesting predictions.

Content-Type

string

Application/json

Request Body

Name
Type
Description

raw_data

string

Base64 encoded string of an image

configurations

array

List of configuration params corresponding to the service.

{    
   "source_id" : "",
   "frame_id" : "",
   "service_id" : "",
   "detected_objects" : [
      {
         "bounding_box" : {
            "bottom" : 251,
            "top" : 167,
            "right" : 479,
            "left" : 361
         },
         "parent" : "electronic",
         "cropped_image" : "",
         "confidence" : 0.995199978351593,
         "name" : "tvmonitor"
      }
   ]
}

Example JSON Request Body

{
    "raw_data": <<BASE64_ENCODED_IMAGE>>,
    "configurations": [
        {
            "parameter": "ConfidenceThreshold",
            "value": "0.1"
        },
        {
            "parameter": "OutputCroppedImage",
            "value": "false"
        },
        {
            "parameter": "OutputVisualizedImage",
            "value": "false"
        }
    ]
}

The configuration is different on individual service types. It is structured as a key-value mapping. A config name is defined in parameter field and the corresponding value is defined in value field in string format.

For object detection service, there are two available configurations as follows:

  • ConfidenceThreshold: to define the minimum confidence score of the prediction results.

    • Value options: [0, 1]

    • Default: "0.1"

  • OutputCroppedImage: to return cropped images from bounding box detections.

    • Value options: "true" or "false"

    • Default: "false"

  • OutputVisualizedImage: to return drawn bounding box detections on raw image.

    • Value options: "true" or "false"

    • Default: "false"

Last updated