These are chat archives for beniz/deepdetect

21st
Jul 2017
Nurettin Onur TUĞCU
@nurettin
Jul 21 2017 13:33
Hi, is there a simple API to upload and train a loaded service with a single image URL? Would it be hard to make?
Nurettin Onur TUĞCU
@nurettin
Jul 21 2017 13:42
I think I found it. I will "share a volume" with the docker image, place some images into a subdirectory and try calling the train API
Nurettin Onur TUĞCU
@nurettin
Jul 21 2017 14:58
and apparently I have to start two services, one for training and one for prediction
Emmanuel Benazera
@beniz
Jul 21 2017 15:23
Training call has a lock on the service, if that helps.
Nurettin Onur TUĞCU
@nurettin
Jul 21 2017 15:24
yeah I was imagining that the trained model would be locked when copying it on top of the old one
it does help, thanks
Nurettin Onur TUĞCU
@nurettin
Jul 21 2017 18:39
I made a quick queueing service to accept a some images per second, train and discard them. It's working while I'm querying for predict every few hundred milliseconds. Hey this is nicer than I thought!
I might use this at our company
Emmanuel Benazera
@beniz
Jul 21 2017 18:42
If you save snapshots from training you can then use the last one in a different service in parallel you your training service. However, it is more common to train fully then exploit the model.
Nurettin Onur TUĞCU
@nurettin
Jul 21 2017 18:43
at the moment I'm just using it on the same model directory. Train seems to lock while predict waits
oh. predict service doesn't re-read the model right?
it just loads initially, so my training is useless.
OK, then I will just restart the predict service every minute or so
first predict will take some time, then all will be well
my requirements is continuous uploading of pictures to train while getting predictions at the same time. So I will have two models and keep on copying/restarting every minute or so
Nurettin Onur TUĞCU
@nurettin
Jul 21 2017 18:48
I could use nginx LRU as a load balancer (hope it doesn't blacklist url when it doesn't respond)
Emmanuel Benazera
@beniz
Jul 21 2017 18:53
The model gets reloaded when training call finishes.
First predict call to new service does take longer as it loads the model up.
Nurettin Onur TUĞCU
@nurettin
Jul 21 2017 18:54
well that's just awesome
I will just have to collect images for like half an hour and then train
and then predict will reload