Closed ComputerCarl closed 5 years ago
Hi, can you share the exact API calls you are making to the server ?
Sure! Fore example, when attempting to register the real_age
service from the models page. The /opt/models/age_real
directory already contains;
config.json
deploy.prototxt
model.caffemodel
And this is what I enter (minus init
and create_repository
lines because I already downloaded and unzipped the files)
curl -X PUT 'http://localhost:8080/services/age_real' -d '{
"description": "age estimation service",
"model": {
"repository": "/opt/models/age_real"
},
"mllib": "caffe",
"type": "supervised",
"parameters": {
"input": {
"connector": "image"
}
}
}'
I get response
{"status":{"code":400,"msg":"BadRequest","dd_code":1006,"dd_msg":"Service Bad Request Error: number of classes is unknown (nclasses == 0)"}}
Please hold off on responding.. I think I know where I messed up and am experimenting.
For others who hit this
"parameters": {
needs however many classes you trained on
> "mllib": {
> "nclasses": 2
> }
When I attempt to add several of the services, I get the error specified in the title. Sorry, I am new at ML.
Configuration
Here are the services I am attempting to register followed by the response