AICamera icon indicating copy to clipboard operation
AICamera copied to clipboard

AICamera demo with Other Networks

Open pratikds opened this issue 7 years ago • 4 comments

Hi,

I tried to include my own design of the network trained on proprietary data sets. I converted it from .caffemodel to caffe2 .pb model.

I have included all class names in "class.h" file and also included the new network's init_net.pb and predict_net.pb files in native-lib.cpp file. I built the app but it doesn't get open on android phone.

Am I wrong somewhere?

I would appreciate any pointers.

Best Regards, Pratik Desai

pratikds avatar Aug 18 '17 10:08 pratikds

I tried using my own model, but it was consistently failing to parse the net (giving the "Couldn't parse net from data" error). I thought it might be due to the size of my net, so I retrained a smaller version (even smaller than squeezenet) and it is able to parse the new smaller net, however it now fails at the point where it should instantiate the predictor, without any useful error or log message.

I know my net is fine as I can load and run it using the python interface. I know the rest of the AICamera app is fine as it runs if I load the squeezenet model. I just can't work out why the two won't play nice...

ghost avatar Sep 10 '17 21:09 ghost

@m00nkeh I encountered into the same issue when I replace squeezenet with other models such as AlexNet. The net files are read but it's stuck on the Predictor constructor. Have u solved this issue?

xumengwei avatar Nov 22 '17 10:11 xumengwei

I am having also problems during loading of a VGG based net. here are the errors: : Instantiating predictor... A/native: [F given_tensor_fill_op.h:27] Check failed: output->size() == values_.size() output size: 2359296 given size: 1066588 A/native: terminating. A/libc: Fatal signal 6 (SIGABRT), code -6 in tid 1590 (AsyncTask #1)

fbadaud avatar Nov 24 '17 13:11 fbadaud

@ ghost I encountered into the same issue, use shufflenet pb that had tested on pc with caffe python, and it show '_predictor = new caffe2::Predictor(_initNet, _predictNet)' crash in debug mode, have you solved it?

cswwp avatar Nov 06 '18 09:11 cswwp