I am unable to convert my custom trained caffe model using googlenet topology to IR.
Please find below the command used for conversion.
python mo.py --input_model ~/distdriver_caffe/googlenet_caffe_iter_2000.caffemodel --input_proto ~/distdriver_caffe/deploy.prototxt --output_dir ~/Distracteddriver_openvino/
The error message is as follows:
FRAMEWORK ERROR ] Exception message: Error parsing message
1. /home/u14685/distdriver_caffe/googlenet_caffe_iter_2000.caffemodel does not exist
2. /home/u14685/distdriver_caffe/googlenet_caffe_iter_2000.caffemodel does not have a valid structure
[ FRAMEWORK ERROR ] Model Optimizer is not able to parse /home/u14685/distdriver_caffe/googlenet_caffe_iter_2000.caffemodel
However, i am able to convert the bvlc googlenet model to IR
Dear Nikhila H,
Model Optimizer Caffe Documentation (still for R1, R2 is being updated as we speak) does not specify googlenet as one of the supported topologies. I suspect this is why you've run into this error.
I actually tried it on 2019R2 (just released yesterday), and I got the same error as you.
Sorry for the inconvenience.
Thank you for the reply.
As per my understanding,inception v1 and googlenet is the same topology(Please correct me if i am wrong) . inception v1 is the given in the list of supported topologies and the pretrained model(bvlc googlenet) was getting converted succesfully.
Also,i tried the same with alexnet topology,but still was facing the same issue.
Dear Nikhila H.
Yes my research also shows that googlenet and inception v1 are the same topology. I just now tried Alexnet with OpenVino R2 and I had no problem.
I think you're getting your models from the wrong place. Please look at C:\Program Files (x86)\IntelSWTools\openvino_2019.2.242\deployment_tools\tools\model_downloader\list_topologies.yml and you will find alexnet as well as all the googlenet-v1 through v4 there.
The easiest way to get these models is python downloader.py --all. But you can read the *.yml file and go to the repo directly as well.
Hope it helps,
As u said, the pretrained models of both the topologies (googlenet and alexnet) are getting converted successfully and is working fine . But the issue is with the fine tuned model (the custom model trained on our dataset) is having the issue.
Dear Nikhila H,
OK this is definitely believable if it's a custom-trained model. I reproduced your error on OpenVino 2019R2 using your custom-trained GoogleNet model. I will file a bug promptly. Sorry for the trouble !
Dear Nikhila H. , please find the generate_caffe_pb2.py in your openvino installation and regenerate caffe_pb2.py as below. Then retry your Model Optimizer command. Does it work ?
python "c:\Program Files (x86)\IntelSWTools\openvino_2019.2.242\deployment_tools\model_optimizer\mo\front\caffe\proto\generate_caffe_pb2.py" --input_proto caffe.proto.txt Running: "protoc -h" Running: "protoc caffe.proto.txt --python_out=c:\Program Files (x86)\IntelSWTools\openvino_2019.2.242\deployment_tools\model_optimizer\mo\front\caffe\proto" File caffe_pb2.py was generated in: c:\Program Files (x86)\IntelSWTools\openvino_2019.2.242\deployment_tools\model_optimizer\mo\front\caffe\proto
If it still fails, then what version of Caffe did you use for the customization of the model ? Where did you get your caffe.proto file ?
Did you get your caffe.proto from https://github.com/BVLC/caffe/tree/master/src/caffe/proto ?
Please answer back on this forum.