Simple image classification API
$ python app.py
$ curl -X POST -F [email protected] 'http://localhost:5000/predict'
{
"predictions": [
{
"label": "tiger_cat",
"probability": 0.4184308648109436
},
{
"label": "Egyptian_cat",
"probability": 0.3616541028022766
},
{
"label": "tabby",
"probability": 0.1262882500886917
},
{
"label": "lynx",
"probability": 0.02171700820326805
},
{
"label": "cup",
"probability": 0.00845610722899437
}
],
"success": true
}
Hey, It's nice flask application for reference. I have a question, I can run my web service successfully.
But I want to reload the service when I change my model. I know set debug = True can reload automatically when code change, also I can restart the program by myself.
The service will shutdown about 1 minute when I reload or restart the program. Are there any methods can change model but not stop the program?