我的视频blog地址 http://www.lofter.com/blog/cloudrivers

OpenVino的MXnet模型转换


[在使用Movidius的模型优化器转换模型之前,需要先用MXNet的deploy.py将模型转换成部署模式,然后才能用movidius的优化器转换]

https://github.com/apache/incubator-mxnet/blob/master/example/ssd/deploy.py

cd ~
git clone https://github.com/apache/incubator-mxnet

mv tmp/*-0000.params tmp/ssd_resnet50_512-0000.params
mv tmp/*-symbol.json tmp/ssd_resnet50_512-symbol.json


python3 incubator-mxnet/example/ssd/deploy.py --network resnet50 --data-shape 512 --num-class 5 --prefix tmp/ssd_

cd /opt/intel/openvino/deployment_tools/model_optimizer

python3 mo_mxnet.py --input_model ssd_resnet50_512-0000.params --input_shape [1,3,512,512]

python3 mo_mxnet.py --input_model ssd_resnet50_512-0000.params --input_shape [1,3,512,512] --data_type=FP16

 

 

posted @ 2019-09-30 21:07  Michael云擎  阅读(833)  评论(0编辑  收藏  举报
我的视频blog地址 http://www.lofter.com/blog/cloudrivers