NanoNets
  1. Image Classification Model Predict
NanoNets
  • Image Classification Model Predict
    • Prediction for image File
      POST
    • Prediction for image URLs
      POST
  • Image Classification Model
    • Get Model by Id
      GET
    • Create New Model
      POST
    • Get All Models
      GET
  • Image Classification Model Train
    • Train Model
      POST
  • Image Classification Model Upload
    • Upload training images by File
      POST
    • Upload training images by Url
      POST
  • OCR Predict
    • Get Prediction File By Page ID
      GET
    • Get All Prediction Files
      GET
    • Get Prediction File By File ID
      GET
    • Prediction for image file
      POST
    • Async Prediction for image file
      POST
    • Prediction for image url
      POST
    • Async Prediction for image url
      POST
  • Get Full Text
    • Get Full Text
      POST
  • OCR Model
    • Create New Model
      POST
    • Get Model by Id
      GET
  • OCR Train
    • Train Model
      POST
  • OCR Upload
    • Upload training images by File
      POST
    • Upload training images by Url
      POST
  1. Image Classification Model Predict

Prediction for image File

开发环境
http://dev-cn.your-api-server.com
开发环境
http://dev-cn.your-api-server.com
POST
/ImageCategorization/LabelFile/
Use the model to predict which one of the categories an image (given an image file) belongs to.

请求参数

Body 参数multipart/form-data

返回响应

🟢200Model Object
application/json
Body

🟠400File missing. Check if you have included a file in the request OR Incorrect image. Check if file you included is a valid PNG or JPEG
🟠402Exhausted Free API Calls. You have exhausted your free API calls please change your plan <a href="https://app.nanonets.com/user/apps">here</a>
🟠404Model does not exists. Check if the model id exists
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST 'http://dev-cn.your-api-server.com/ImageCategorization/LabelFile/' \
--form 'modelId=""' \
--form 'file=@""'
响应示例响应示例
200 - response
{
    "message": "Success",
    "model_id": "00000000-0000-0000-0000-000000000000",
    "result": [
        {
            "file": "string",
            "message": "Success",
            "prediction": [
                {
                    "label": "category1",
                    "probability": 0.9
                },
                {
                    "label": "category2",
                    "probability": 0.1
                }
            ]
        }
    ]
}
修改于 2024-05-29 05:52:24
下一页
Prediction for image URLs
Built with