app-mlperf-inference-ctuning-cpp-tflite
Automatically generated README for this automation recipe: app-mlperf-inference-ctuning-cpp-tflite
Category: Modular MLPerf inference benchmark pipeline
License: Apache 2.0
- CM meta description for this script: _cm.json
- Output cached? False
Reuse this script in your project
Install MLCommons CM automation meta-framework
Pull CM repository with this automation recipe (CM script)
cm pull repo mlcommons@cm4mlops
Print CM help from the command line
cmr "app mlperf inference tflite-cpp" --help
Run this script
Run this script via CLI
cm run script --tags=app,mlperf,inference,tflite-cpp[,variations] [--input_flags]
Run this script via CLI (alternative)
cmr "app mlperf inference tflite-cpp [variations]" [--input_flags]
Run this script from Python
import cmind
r = cmind.access({'action':'run'
'automation':'script',
'tags':'app,mlperf,inference,tflite-cpp'
'out':'con',
...
(other input keys for this script)
...
})
if r['return']>0:
print (r['error'])
Run this script via Docker (beta)
cm docker script "app mlperf inference tflite-cpp[variations]" [--input_flags]
Variations
-
No group (any combination of variations can be selected)
Click here to expand this section.
_armnn
- ENV variables:
- CM_MLPERF_TFLITE_USE_ARMNN:
yes
- CM_TMP_LINK_LIBS:
tensorflowlite,armnn
- CM_MLPERF_TFLITE_USE_ARMNN:
- ENV variables:
-
Group "backend"
Click here to expand this section.
_tf
- ENV variables:
- CM_MLPERF_BACKEND:
tf
- CM_MLPERF_BACKEND:
- ENV variables:
_tflite
(default)- ENV variables:
- CM_MLPERF_BACKEND:
tflite
- CM_MLPERF_BACKEND_VERSION:
master
- CM_TMP_LINK_LIBS:
tensorflowlite
- CM_TMP_SRC_FOLDER:
src
- CM_MLPERF_BACKEND:
- ENV variables:
-
Group "device"
Click here to expand this section.
_cpu
(default)- ENV variables:
- CM_MLPERF_DEVICE:
cpu
- CM_MLPERF_DEVICE:
- ENV variables:
_gpu
- ENV variables:
- CM_MLPERF_DEVICE:
gpu
- CM_MLPERF_DEVICE_LIB_NAMESPEC:
cudart
- CM_MLPERF_DEVICE:
- ENV variables:
-
Group "loadgen-scenario"
Click here to expand this section.
_singlestream
(default)- ENV variables:
- CM_MLPERF_LOADGEN_SCENARIO:
SingleStream
- CM_MLPERF_LOADGEN_SCENARIO:
- ENV variables:
-
Group "model"
Click here to expand this section.
_efficientnet
- ENV variables:
- CM_MODEL:
efficientnet
- CM_MODEL:
- ENV variables:
_mobilenet
- ENV variables:
- CM_MODEL:
mobilenet
- CM_MODEL:
- ENV variables:
_resnet50
(default)- ENV variables:
- CM_MODEL:
resnet50
- CM_MODEL:
- ENV variables:
-
Group "optimization-target"
Click here to expand this section.
_use-neon
- ENV variables:
- CM_MLPERF_SUT_NAME_RUN_CONFIG_SUFFIX1:
using_neon
- CM_MLPERF_TFLITE_USE_NEON:
1
- CM_MLPERF_SUT_NAME_RUN_CONFIG_SUFFIX1:
- ENV variables:
_use-opencl
- ENV variables:
- CM_MLPERF_SUT_NAME_RUN_CONFIG_SUFFIX1:
using_opencl
- CM_MLPERF_TFLITE_USE_OPENCL:
1
- CM_MLPERF_SUT_NAME_RUN_CONFIG_SUFFIX1:
- ENV variables:
-
Group "precision"
Click here to expand this section.
_fp32
(default)- ENV variables:
- CM_MLPERF_MODEL_PRECISION:
float32
- CM_MLPERF_MODEL_PRECISION:
- ENV variables:
_int8
- ENV variables:
- CM_DATASET_COMPRESSED:
on
- CM_MLPERF_MODEL_PRECISION:
int8
- CM_DATASET_COMPRESSED:
- ENV variables:
_uint8
- ENV variables:
- CM_DATASET_COMPRESSED:
on
- CM_MLPERF_MODEL_PRECISION:
uint8
- CM_DATASET_COMPRESSED:
- ENV variables:
Default variations
_cpu,_fp32,_resnet50,_singlestream,_tflite
Script flags mapped to environment
--compressed_dataset=value
→CM_DATASET_COMPRESSED=value
--count=value
→CM_MLPERF_LOADGEN_QUERY_COUNT=value
--mlperf_conf=value
→CM_MLPERF_CONF=value
--mode=value
→CM_MLPERF_LOADGEN_MODE=value
--output_dir=value
→CM_MLPERF_OUTPUT_DIR=value
--performance_sample_count=value
→CM_MLPERF_LOADGEN_PERFORMANCE_SAMPLE_COUNT=value
--scenario=value
→CM_MLPERF_LOADGEN_SCENARIO=value
--user_conf=value
→CM_MLPERF_USER_CONF=value
--verbose=value
→CM_VERBOSE=value
Default environment
These keys can be updated via --env.KEY=VALUE
or env
dictionary in @input.json
or using script flags.
- CM_DATASET_COMPRESSED:
off
- CM_DATASET_INPUT_SQUARE_SIDE:
224
- CM_FAST_COMPILATION:
yes
- CM_LOADGEN_BUFFER_SIZE:
1024
- CM_MLPERF_LOADGEN_MODE:
accuracy
- CM_MLPERF_LOADGEN_SCENARIO:
SingleStream
- CM_MLPERF_LOADGEN_TRIGGER_COLD_RUN:
0
- CM_MLPERF_OUTPUT_DIR:
.
- CM_MLPERF_SUT_NAME_IMPLEMENTATION_PREFIX:
tflite_cpp
- CM_MLPERF_TFLITE_USE_NEON:
0
- CM_MLPERF_TFLITE_USE_OPENCL:
0
- CM_ML_MODEL_GIVEN_CHANNEL_MEANS:
123.68 116.78 103.94
- CM_ML_MODEL_NORMALIZE_DATA:
0
- CM_ML_MODEL_SUBTRACT_MEANS:
1
- CM_VERBOSE:
0
Script output
cmr "app mlperf inference tflite-cpp [variations]" [--input_flags] -j