Intel® Distribution of OpenVINO™ Toolkit
Community assistance about the Intel® Distribution of OpenVINO™ toolkit, OpenCV, and all aspects of computer vision-related on Intel® platforms.
6404 Discussions

Fail to inference when convert to OpenVINO model

Liao__Mist
Beginner
462 Views

I have tried a model with TensorFlow Estimator for age/gender prediction. The model can predict correct values when inference with TensorFlow framework. When I convert the model to OpenVINO, I always get same predict values with different input images. I believe the problem is from model conversion. Could you tell me what could be wrong?

the command I used is:

/opt/intel/openvino_2019.1.144/deployment_tools/model_optimizer/mo_tf.py --saved_model_dir ~/Downloads/mobilenet-mtl-0.0001-8-0722-2/serving/1563817887/ --output=age_prob,gender_prob --reverse_input_channels -b 1 --data_type FP32

The output of my test python example:

[ INFO ] Loading network files:
        age_gender_pose_freeze.xml
        age_gender_pose_freeze.bin
[ INFO ] {'age_prob': <openvino.inference_engine.ie_api.OutputInfo object at 0x1115748b8>, 'gender_prob': <openvino.inference_engine.ie_api.OutputInfo object at 0x111574920>}
[ INFO ] Preparing input blobs
[ INFO ] Placeholder
[ INFO ] age_prob
[ INFO ] 1 3 96 96
[ INFO ] Image width (96, 96)
[ INFO ] Batch size is 1
[ INFO ] Loading model to the plugin
[ INFO ] Starting inference (1 iterations)
[ INFO ] Average running time of one iteration: 10.089874267578125 ms
[ INFO ] Processing output blob
[ INFO ] Top 2 results: 
Image /Users/mist_liao/Downloads/nm1468674_rm2096473856_1976-5-17_2013.jpg

classid probability
------- -----------
   1         1.0000000
   0         1.0000000

The probability are always 1.00000

Thanks.

0 Kudos
3 Replies
Liao__Mist
Beginner
462 Views

I have found the root cause. Thanks.

0 Kudos
Shubha_R_Intel
Employee
462 Views

Dear Liao, Mist,

Wonderful ! I am so happy to hear that you found the root cause. Would you mind sharing what it was so that the OpenVino community can learn from your pain ? You know what they say, "No Pain, No Gain". 

Thanks !

Shubha

 

0 Kudos
Morsali__Reza
Beginner
462 Views

Hi,

 

I am experiencing the same problem. I was wondering what was the root cause.

 

Thanks,

Reza

0 Kudos
Reply