Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Satya__Reno
Beginner
71 Views

Faster RCNN Model Optimizer Error

Hi,

I'm trying to run model optimizer on my VGG16_faster_rcnn_final.caffemodel

I a working in a ubuntu 16.04 VM

I run like it was said on Faster RCNN demo :

python3 mo_caffe.py --input_model VGG16_faster_rcnn_final.caffemodel --input_proto test.prototxt

 

And i got this result :

Model Optimizer arguments:
Common parameters:
    - Path to the Input Model:     /home/beno/intel/VGG16_faster_rcnn_final.caffemodel
    - Path for generated IR:     /home/beno/intel/.
    - IR output name:     VGG16_faster_rcnn_final
    - Log level:     ERROR
    - Batch:     Not specified, inherited from the model
    - Input layers:     Not specified, inherited from the model
    - Output layers:     Not specified, inherited from the model
    - Input shapes:     Not specified, inherited from the model
    - Mean values:     Not specified
    - Scale values:     Not specified
    - Scale factor:     Not specified
    - Precision of IR:     FP32
    - Enable fusing:     True
    - Enable grouped convolutions fusing:     True
    - Move mean values to preprocess section:     False
    - Reverse input channels:     False
Caffe specific parameters:
    - Enable resnet optimization:     True
    - Path to the Input prototxt:     /home/beno/intel/test.prototxt
    - Path to CustomLayersMapping.xml:     Default
    - Path to a mean file:     Not specified
    - Offsets for a mean file:     Not specified
Model Optimizer version:     2019.1.1-83-g28dfbfd
[ ERROR ]  Cannot infer shapes or values for node "conv1".
[ ERROR ]  -1
[ ERROR ]  
[ ERROR ]  It can happen due to bug in custom shape infer function <function Convolution.infer at 0x7f0575880a60>.
[ ERROR ]  Or because the node inputs have incorrect values/shapes.
[ ERROR ]  Or because input shapes are incorrect (embedded to the model or passed via --input_shape).
[ ERROR ]  Run Model Optimizer with --log_level=DEBUG for more information.
[ ERROR ]  Exception occurred during running replacer "REPLACEMENT_ID" (<class 'extensions.middle.PartialInfer.PartialInfer'>): Stopped shape/value propagation at "conv1" node.
 For more information please refer to Model Optimizer FAQ (<INSTALL_DIR>/deployment_tools/documentation/docs/MO_FAQ.html), question #38.

Any idea of what's wrong ?

 

Regards.

Reno

0 Kudos
3 Replies
Satya__Reno
Beginner
71 Views

Kenneth_C_Intel
Employee
71 Views

add the flag --batch 1 

the issue looks to be in the shape model optimizer is unable to handle a -1 in the input shape. 

Try that and let me know if it completes.

Satya__Reno
Beginner
71 Views

Still got the same error

Input :
python3 mo_caffe.py --input_model VGG16_faster_rcnn_final.caffemodel --input_proto test.prototxt --batch 1
 

Output :

Model Optimizer arguments:
Common parameters:
    - Path to the Input Model:     /home/beno/intel/VGG16_faster_rcnn_final.caffemodel
    - Path for generated IR:     /home/beno/intel/.
    - IR output name:     VGG16_faster_rcnn_final
    - Log level:     ERROR
    - Batch:     1
    - Input layers:     Not specified, inherited from the model
    - Output layers:     Not specified, inherited from the model
    - Input shapes:     Not specified, inherited from the model
    - Mean values:     Not specified
    - Scale values:     Not specified
    - Scale factor:     Not specified
    - Precision of IR:     FP32
    - Enable fusing:     True
    - Enable grouped convolutions fusing:     True
    - Move mean values to preprocess section:     False
    - Reverse input channels:     False
Caffe specific parameters:
    - Enable resnet optimization:     True
    - Path to the Input prototxt:     /home/beno/intel/test.prototxt
    - Path to CustomLayersMapping.xml:     Default
    - Path to a mean file:     Not specified
    - Offsets for a mean file:     Not specified
Model Optimizer version:     2019.1.1-83-g28dfbfd
[ ERROR ]  Cannot infer shapes or values for node "conv1".
[ ERROR ]  -1
[ ERROR ]  
[ ERROR ]  It can happen due to bug in custom shape infer function <function Convolution.infer at 0x7f4c46546b70>.
[ ERROR ]  Or because the node inputs have incorrect values/shapes.
[ ERROR ]  Or because input shapes are incorrect (embedded to the model or passed via --input_shape).
[ ERROR ]  Run Model Optimizer with --log_level=DEBUG for more information.
[ ERROR ]  Exception occurred during running replacer "REPLACEMENT_ID" (<class 'extensions.middle.PartialInfer.PartialInfer'>): Stopped shape/value propagation at "conv1" node.
 For more information please refer to Model Optimizer FAQ (<INSTALL_DIR>/deployment_tools/documentation/docs/MO_FAQ.html), question #38.

Reply