(1)獲取openvino的軟件鏡像openvino_docker.tar
(2)Docker導(dǎo)入本地鏡像為openvino
cat /home/czw/下載/openvino_docker/openvino_docker |docker import - openvino
(3)查看主機(jī)上的鏡像拷姿,找到IMAGE ID
docker images
(4)使用openvino鏡像來運(yùn)行
docker run -it openvino:latest /bin/bash
docker ps -a
使用docker ps -a查看有那些容器在運(yùn)行
(5)再次啟動容器需要的操作
docker start 容器ID
docker attach 容器ID
root@7483ae1d61a4:容器已啟動標(biāo)志
之后所有的操作都是在容器內(nèi):
在容器內(nèi)時(shí),把它當(dāng)做linux系統(tǒng)來操作即可
(6)在容器內(nèi)運(yùn)行人臉識別示例
main.cpp所在位置:/opt/intel/computer_vision_sdk_2018.3.343/
deployment_tools/inference_engine/samples/interactice_face
_detection_sample
(1)在xx/samples目錄下創(chuàng)建名為build的目錄
創(chuàng)建build目錄:mkdir build
切換到build目錄:cd build
(2)編譯
cmake -DCMAKE_BUILD_+TYPE=Debug /opt/intel/computer_vision_sdk_2018.3.343/deployment_tools/inference_engine/samples)
運(yùn)行make生成示例:make
切換到build下的/intel64/Debug目錄:
cd /opt/intel/computer_vision_sdk_2018.3.343/deployment_tools/
inference_engine/samples/build/intel64/Debug
(3)輸入模型參數(shù)恋拷,運(yùn)行示例
./interactive_face_detection_sample -i /opt/image.jpg -m /opt/intel/computer_vision_sdk_2018.3.343/deployment_tools/intel_models/face-detection-adas-0001/FP32/face-detection-adas-0001.xml -m_ag /opt/intel/computer_vision_sdk_2018.3.343/deployment_tools/intel_models/age-gender-recognition-retail-0013/FP32/age-gender-recognition-retail-0013.xml -m_hp /opt/intel/computer_vision_sdk_2018.3.343/deployment_tools/intel_models/head-pose-estimation-adas-0001/FP32/head-pose-estimation-adas-0001.xml -m_em /opt/intel/computer_vision_sdk_2018.3.343/deployment_tools/intel_models/emotions-recognition-retail-0003/FP32/emotions-recognition-retail-0003.xml -d CPU
圖像或視頻處理后的存儲位置: /opt/video/
(4)從容器將文件復(fù)制到本機(jī)
docker cp 7483ae1d61a4:/opt/video/image.jpg /home/czw/下載