Commit daa913d4 authored by GONZALES ZUNIGA Juan Diego's avatar GONZALES ZUNIGA Juan Diego
Browse files

Merge branch '2020.4.287'

parents be4778a7 3e4e14ad
FROM local/dockervino:phase1 as build
ARG downloader=/opt/intel/openvino/deployment_tools/tools/model_downloader/downloader.py
ARG optimizer=/opt/intel/openvino/deployment_tools/model_optimizer/mo.py
ENV downloader=${INTEL_OPENVINO_DIR}/deployment_tools/tools/model_downloader/downloader.py
ENV converter=${INTEL_OPENVINO_DIR}/deployment_tools/tools/model_downloader/converter.py
ENV optimizer=${INTEL_OPENVINO_DIR}/deployment_tools/model_optimizer/mo.py
ARG models=/root/openvino_models
WORKDIR $models
RUN python3 $downloader --name googlenet-v3 --output_dir $models
RUN python3 $optimizer --input_model ./public/googlenet-v3/inception_v3_2016_08_28_frozen.pb --output_dir ./ir/googlenet/v3/FP32 --data_type FP32
RUN python3 $optimizer --input_model ./public/googlenet-v3/inception_v3_2016_08_28_frozen.pb --output_dir ./ir/googlenet/v3/FP16 --data_type FP16
RUN python3 $converter --name googlenet-v3 --output_dir $models --precisions FP32,FP16
RUN python3 $downloader --name googlenet-v4-tf --output_dir $models
RUN python3 $optimizer --input_model ./public/googlenet-v4-tf/inception_v4.frozen.pb --output_dir ./ir/googlenet/v4/FP32 --data_type FP32
RUN python3 $optimizer --input_model ./public/googlenet-v4-tf/inception_v4.frozen.pb --output_dir ./ir/googlenet/v4/FP16 --data_type FP16
RUN python3 $converter --name googlenet-v4-tf --output_dir $models --precisions FP32,FP16
RUN python3 $downloader --name vgg16 --output_dir $models
RUN python3 $optimizer --input_model ./public/vgg16/vgg16.caffemodel --output_dir ./ir/vgg/16/FP32 --data_type FP32
RUN python3 $optimizer --input_model ./public/vgg16/vgg16.caffemodel --output_dir ./ir/vgg/16/FP16 --data_type FP16
RUN python3 $converter --name vgg16 --output_dir $models --precisions FP32,FP16
RUN python3 $downloader --name vgg19 --output_dir $models
RUN python3 $optimizer --input_model ./public/vgg19/vgg19.caffemodel --output_dir ./ir/vgg/19/FP32 --data_type FP32
RUN python3 $optimizer --input_model ./public/vgg19/vgg19.caffemodel --output_dir ./ir/vgg/19/FP16 --data_type FP16
#RUN python3 $downloader --name resnet-50 --output_dir $models
#RUN python3 $optimizer --input_model ./public/resnet-50/resnet-50.caffemodel --output_dir ./ir/resnet/v1/50/FP32 --data_type FP32
#RUN python3 $optimizer --input_model ./public/resnet-50/resnet-50.caffemodel --output_dir ./ir/resnet/v1/50/FP16 --data_type FP16
#RUN python3 $downloader --name resnet-101 --output_dir $models
#RUN python3 $optimizer --input_model ./public/resnet-101/resnet-101.caffemodel --output_dir ./ir/resnet/v1/101/FP32 --data_type FP32
#RUN python3 $optimizer --input_model ./public/resnet-101/resnet-101.caffemodel --output_dir ./ir/resnet/v1/101/FP16 --data_type FP16
RUN python3 $converter --name vgg19 --output_dir $models --precisions FP32,FP16
#RUN python3 $downloader --name resnet-152 --output_dir $models
#RUN python3 $optimizer --input_model ./public/resnet-152/resnet-152.caffemodel --output_dir ./ir/resnet/v1/152/FP32 --data_type FP32
#RUN python3 $optimizer --input_model ./public/resnet-152/resnet-152.caffemodel --output_dir ./ir/resnet/v1/152/FP16 --data_type FP16
RUN python3 $downloader --name resnet-50-tf --output_dir $models
RUN python3 $converter --name resnet-50-tf --output_dir $models --precisions FP32,FP16
COPY ./entrypoint.sh /
CMD ["/bin/bash"]
# @(#) run with coherent naming
docker build --tag=local/dockervino:benchmark . #| tee openvinobuild.log
docker build --tag=local/dockervino:benchmark --network=host . #| tee openvinobuild.log
......@@ -5,57 +5,24 @@ source $setupvars
# app, device, model and input are defined in the runcmd file
benchmark=/root/inference_engine_samples_build/intel64/Release/benchmark_app
input=/opt/intel/openvino/deployment_tools/demo/car.png
stars=/////////////////////////////////////////////////
models=/root/openvino_models
echo "Benchmarking starts now!"
lscpu
if [ "$device" == "CPU" ]; then
echo $stars
echo "Inception V3"
$benchmark -d $device -i $input -api $api -m $models/ir/googlenet/v3/FP32/inception_v3_2016_08_28_frozen.xml
echo $stars
echo "Inception V4"
$benchmark -d $device -i $input -api $api -m $models/ir/googlenet/v4/FP32/inception_v4.frozen.xml
echo $stars
echo "VGG16"
$benchmark -d $device -i $input -api $api -m $models/ir/vgg/16/FP32/vgg16.xml
echo $stars
echo "VGG19"
$benchmark -d $device -i $input -api $api -m $models/ir/vgg/19/FP32/vgg19.xml
echo $stars
#echo "Resnet 50"
#$benchmark -d $device -i $input -api $api -m $models/ir/resnet/v1/50/FP32/resnet-50.xml
#echo $stars
#echo "Resnet 101"
#$benchmark -d $device -i $input -api $api -m $models/ir/resnet/v1/101/FP32/resnet-101.xml
#echo $stars
#echo "Resnet 152"
#$benchmark -d $device -i $input -api $api -m $models/ir/resnet/v1/152/FP32/resnet-152.xml
#echo $stars
else
echo $stars
echo "Inception V3"
$benchmark -d $device -i $input -api $api -m $models/ir/googlenet/v3/FP16/inception_v3_2016_08_28_frozen.xml
echo $stars
echo "Inception V4"
$benchmark -d $device -i $input -api $api -m $models/ir/googlenet/v4/FP16/inception_v4.frozen.xml
echo $stars
echo "VGG16"
$benchmark -d $device -i $input -api $api -m $models/ir/vgg/16/FP16/vgg16.xml
echo $stars
echo "VGG19"
$benchmark -d $device -i $input -api $api -m $models/ir/vgg/19/FP16/vgg19.xml
echo $stars
#echo "Resnet 50"
#$benchmark -d $device -i $input -api $api -m $models/ir/resnet/v1/50/FP16/resnet-50.xml
#echo $stars
#echo "Resnet 101"
#$benchmark -d $device -i $input -api $api -m $models/ir/resnet/v1/101/FP16/resnet-101.xml
#echo $stars
#echo "Resnet 152"
#$benchmark -d $device -i $input -api $api -m $models/ir/resnet/v1/152/FP16/resnet-152.xml
#echo $stars
fi
echo "Inception V3"
$benchmark -d $device -i $input -api $api -m $models/public/googlenet-v3/$datatype/googlenet-v3.xml
echo "Inception V4"
$benchmark -d $device -i $input -api $api -m $models/public/googlenet-v4-tf/$datatype/googlenet-v4-tf.xml
echo "VGG16"
$benchmark -d $device -i $input -api $api -m $models/public/vgg16/$datatype/vgg16.xml
echo "VGG19"
$benchmark -d $device -i $input -api $api -m $models/public/vgg19/$datatype/vgg19.xml
echo "Resnet 50"
$benchmark -d $device -i $input -api $api -m $models/public/resnet-50-tf/$datatype/resnet-50-tf.xml
echo "Benchmarking done!"
......@@ -4,9 +4,9 @@ myname=benchmark
###### Settings ########
setupvars=/opt/intel/openvino/bin/setupvars.sh
device=CPU # CPU OR MYRIAD
device=CPU # CPU or MYRIAD
api=async # sync or async
datatype=FP32 # FP32 or FP16
set -x
docker run \
-d \
......@@ -16,6 +16,7 @@ docker run \
--env="DISPLAY" \
--env="device=$device" \
--env="api=$api" \
--env="datatype=$datatype" \
--env="setupvars=$setupvars" \
--volume="/dev:/dev" \
--cap-add SYS_PTRACE \
......
# @(#) run with coherent naming
docker build --tag=local/dockervino:debug . #| tee openvinobuild.log
docker build --tag=local/dockervino:debug --network=host . #| tee openvinobuild.log
......@@ -47,18 +47,14 @@ RUN apt-get update && \
rm -rf /var/lib/apt/lists/*
# Openvino Version and copy from host
ARG openvinoTar=l_openvino_toolkit_p_2021.1.110
ENV INTEL_OPENVINO_DIR=/opt/intel/openvino_2021.1.110
ENV INTEL_OPENVINO_DIR=/opt/intel/openvino
ARG TEMP_DIR=/tmp/openvino_installer
WORKDIR ${TEMP_DIR}
COPY ./$openvinoTar.tgz $TEMP_DIR
# install product by installation script
ENV TZ=Europe/Kiev
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone
RUN tar -xzf ${TEMP_DIR}/*.tgz --strip 1
RUN sed -i 's/decline/accept/g' silent.cfg && \
${TEMP_DIR}/install.sh -s silent.cfg && \
......
......@@ -7,6 +7,7 @@ docker run \
-d \
-ti \
--privileged \
--net=host \
--env="PS1=$myname> "\
--publish-all=true \
--hostname=$myname \
......
# @(#) run with coherent naming
docker build --tag=local/dockervino:phase2 . #| tee openvinobuild.log
docker build --tag=local/dockervino:phase2 --network=host . #| tee openvinobuild.log
......@@ -6,6 +6,7 @@ set -x
docker run \
-d \
-ti \
--privileged \
--net=host \
--env="DISPLAY" \
--env="PS1=$myname> "\
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment