From 36757ed20384c0161c99b2ed3a43517bd6ad9143 Mon Sep 17 00:00:00 2001 From: lidanqing Date: Tue, 21 May 2019 06:52:34 +0200 Subject: [PATCH] Enabling resnet101, vgg16, vgg19 INT8v2 model tests (#17468) * Add 6 models tests support in CMake * enabling resnet101, vgg16, vgg19 INT8v2 model tests test=develop * remove SERIAL test=develop --- .../fluid/inference/tests/api/CMakeLists.txt | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/paddle/fluid/inference/tests/api/CMakeLists.txt b/paddle/fluid/inference/tests/api/CMakeLists.txt index c0854d4d0a7..d2f358bd045 100644 --- a/paddle/fluid/inference/tests/api/CMakeLists.txt +++ b/paddle/fluid/inference/tests/api/CMakeLists.txt @@ -173,6 +173,28 @@ if(WITH_MKLDNN) inference_download_and_uncompress(${INT8_MOBILENET_MODEL_DIR} "${INFERENCE_URL}/int8" "mobilenetv1_int8_model.tar.gz" ) endif() inference_analysis_api_int8_test(test_analyzer_int8_mobilenet ${INT8_MOBILENET_MODEL_DIR} ${INT8_DATA_DIR} analyzer_int8_image_classification_tester.cc SERIAL) + + #resnet101 int8 + set(INT8_RESNET101_MODEL_DIR "${INT8_DATA_DIR}/resnet101") + if (NOT EXISTS ${INT8_RESNET101_MODEL_DIR}) + inference_download_and_uncompress(${INT8_RESNET101_MODEL_DIR} "${INFERENCE_URL}/int8" "Res101_int8_model.tar.gz" ) + endif() + inference_analysis_api_int8_test(test_analyzer_int8_resnet101 ${INT8_RESNET101_MODEL_DIR} ${INT8_DATA_DIR} analyzer_int8_image_classification_tester.cc) + + #vgg16 int8 + set(INT8_VGG16_MODEL_DIR "${INT8_DATA_DIR}/vgg16") + if (NOT EXISTS ${INT8_VGG16_MODEL_DIR}) + inference_download_and_uncompress(${INT8_VGG16_MODEL_DIR} "${INFERENCE_URL}/int8" "VGG16_int8_model.tar.gz" ) + endif() + inference_analysis_api_int8_test(test_analyzer_int8_vgg16 ${INT8_VGG16_MODEL_DIR} ${INT8_DATA_DIR} analyzer_int8_image_classification_tester.cc) + + #vgg19 int8 + set(INT8_VGG19_MODEL_DIR "${INT8_DATA_DIR}/vgg19") + if (NOT EXISTS ${INT8_VGG19_MODEL_DIR}) + inference_download_and_uncompress(${INT8_VGG19_MODEL_DIR} "${INFERENCE_URL}/int8" "VGG19_int8_model.tar.gz" ) + endif() + inference_analysis_api_int8_test(test_analyzer_int8_vgg19 ${INT8_VGG19_MODEL_DIR} ${INT8_DATA_DIR} analyzer_int8_image_classification_tester.cc) + endif() # bert, max_len=20, embedding_dim=128 -- GitLab