These are chat archives for beniz/deepdetect

5th
Nov 2017
Emmanuel Benazera
@beniz
Nov 05 2017 07:17
For similarity search use the imgsearch in demos.
Gavin Gilmour
@gaving
Nov 05 2017 09:04

Thanks, I'll check it out. I tried to train vgg_face last night but verged on giving up.

https://gist.github.com/gaving/751add7887a464476a98d0e70a51d94c

Found a train_val + solver somewhere.. then issued the training call but kept getting a "Check failed (custom): (mdb_status) == (0)" error.

Emmanuel Benazera
@beniz
Nov 05 2017 09:06
This means that the automatically built db that holds your dataset cannot be found. You'd need to post your full train call.
Gitter's preview seems to be truncating them
Emmanuel Benazera
@beniz
Nov 05 2017 09:08
post into a gist.
Gavin Gilmour
@gaving
Nov 05 2017 09:09
Isn't that it in a gist? ^ :confused:
The POST to /train
Emmanuel Benazera
@beniz
Nov 05 2017 09:09
yes, sorry
Not sure what you are trying to do, but your train/ directory does not appear to hold the 1000 classes you are declaring in the service creation.
Gavin Gilmour
@gaving
Nov 05 2017 09:13
Ah. Yeah it's only got 1 image/folder, was just trying to see if it'd take the image for starters.
Out my depth :smile:
Emmanuel Benazera
@beniz
Nov 05 2017 09:13
try with 2 classes
Gavin Gilmour
@gaving
Nov 05 2017 09:14
So, two folders with images in? And change the call to nclasses: 2?
Ok, thanks.
Same error with nclasses: 2 and 2 folders. But I don't want to take up any more of your time so I'll go away and pour over the examples again.
Emmanuel Benazera
@beniz
Nov 05 2017 09:16
cleanup your model repo beforehand
remove the lmdb files if any
Gavin Gilmour
@gaving
Nov 05 2017 09:20
docker stop && docker rm && rm model.json&& rm -rf train.lmdb && docker run -p 8080:8080 --name dd -v /Users/gavin/Sandbox/dd:/opt/models beniz/deepdetect_cpu && curl <PUT /services/face> && curl <POST /train> = db_lmdb.hpp:15 / Check failed (custom): (mdb_status) == (0)"
I suppose it's caffe's error messages I find the most frustrating, quite cryptic
Emmanuel Benazera
@beniz
Nov 05 2017 09:20
what's in your model repo now ?
Gavin Gilmour
@gaving
Nov 05 2017 09:21
By that you mean model.json?
Emmanuel Benazera
@beniz
Nov 05 2017 09:23
I'd recommend you make a cleaner directory, only holding the prototxt and caffemodel to be finetuned
then post the full server output
Gavin Gilmour
@gaving
Nov 05 2017 09:23
Understood
Gavin Gilmour
@gaving
Nov 05 2017 09:29
No luck, same error. :( Presume there is nothing known with docker volumes and accessing the train.lmdb database?
Emmanuel Benazera
@beniz
Nov 05 2017 09:30
First, you need to share the full server output
Emmanuel Benazera
@beniz
Nov 05 2017 09:48
your train_val.prototxt is wrong, you need to look at the templates/caffe/vgg_16/vgg_16.prototxt head and fix it.
also rename the deploy file to deploy.prototxt and train_val.prototxt to VGG_FACE.prototxt
your vgg face model uses the ImageDataLayer interface that is not the one used by DD. there'll be support for it in a near future, but it is slower in practice. So for now you need to edit your file.
Gavin Gilmour
@gaving
Nov 05 2017 09:51
:astonished:
Ok, thank you for your time with this. I'll go away and read some more...
Difficult field you're in :)
Emmanuel Benazera
@beniz
Nov 05 2017 10:05
changes above should be simple
Gavin Gilmour
@gaving
Nov 05 2017 10:07
Yeah I tried as you said above by replacing from vgg_16.prototxt and renamed them all, but getting the same error unfortunately. Must be doing something else wrong.
Emmanuel Benazera
@beniz
Nov 05 2017 10:08
post your new prototxt
and modify your solver.prototxt so that it points to the right file
Model removed, train directory deleted, docker rm'd, docker started, PUT and POST calls issued.
Emmanuel Benazera
@beniz
Nov 05 2017 10:24
look carefully at the vgg_16.prototxt, that is not what you have here
Emmanuel Benazera
@beniz
Nov 05 2017 10:29
ah it's me looking at the wrong fil
file
you've just modified the head, right ?
Gavin Gilmour
@gaving
Nov 05 2017 10:30
Can I ask what you mean by head? I just replaced it entirely from master.
Emmanuel Benazera
@beniz
Nov 05 2017 10:31
you need to replace just the 2 top layers
Gavin Gilmour
@gaving
Nov 05 2017 10:32
Ok sorry will try that
ugh, top two layers replaced and same thing
seriously thanks for your help but I don't want to waste anymore time
I'll go and look at the examples
I've also found https://github.com/pleuren/vggface-finetune which might help
Emmanuel Benazera
@beniz
Nov 05 2017 10:35
post all files and server log after each failed trials
Gavin Gilmour
@gaving
Nov 05 2017 10:39
Just the usual ./include/caffe/util/db_lmdb.hpp:15 / Check failed (custom): (mdb_status) == (0)" and service face training call failed in the logs.
I have to step out but thanks again, if I get time later I will re-visit.
Emmanuel Benazera
@beniz
Nov 05 2017 10:39
np