squeezenet_ssd_voc_ncnn

Squeezenet SSD

Embedded, Detection, Ncnn

curl -X PUT http://localhost:8080/services/squeezenet_ssd_voc -d '{
 "description": "Squeezenet SSD",
 "model": {
  "repository": "/opt/models/squeezenet_ssd_voc",
  "create_repository": true,
  "init":"https://deepdetect.com/models/init/embedded/images/detection/squeezenet_ssd_voc_ncnn.tar.gz"
 },
 "mllib": "ncnn",
 "type": "supervised",
 "parameters": {
  "input": {
   "connector": "image"
  }
 }
}'
curl -X POST 'http://localhost:8080/predict' -d '{
  "service": "squeezenet_ssd_voc",
  "parameters": {
    "input": {},
    "output": {
      "confidence_threshold": 0.3,
      "bbox": true
    },
    "mllib": {
      "gpu": true
    }
  },
  "data": [
    "/data/example.jpg"
  ]
}'
from dd_client import DD
from dd_client import DD
host = 'localhost'
port = 8080
dd = DD(host,port)
dd.set_return_format(dd.RETURN_PYTHON)

parameters_input = {"confidence_threshold":0.3, "bbox":True}
parameters_mllib = {}
parameters_output = {}
data = ["/data/example.jpg"]
sname = 'squeezenet_ssd_voc'
classif = dd.post_predict(sname,data,parameters_input,parameters_mllib,parameters_output)
// https://www.npmjs.com/package/deepdetect-js
var DD = require('deepdetect-js');

const dd = new DD({
  host: 'localhost',
  port: 8080
})

const postData = {
  "service": "squeezenet_ssd_voc",
  "parameters": {
    "input": {
      "confidence_threshold": 0.3,
      "bbox": true
    },
    "output": {},
    "mllib": {}
  },
  "data": [
    "/data/example.jpg"
  ]
}

async function run() {
  const predict = await dd.postPredict(postData);
  console.log(predict);
}

run()
{
  "status": {
    "code": 200,
    "msg": "OK"
  },
  "head": {
    "method": "/predict",
    "service": "squeezenet_ssd_voc",
    "time": 17
  },
  "body": {
    "predictions": [
      {
        "classes": [
          {
            "prob": 1,
            "last": true,
            "cat": "believed"
          }
        ],
        "uri": "/data/example.jpg"
      }
    ]
  }
}