From: 박종현/On-Device Lab(SR)/Staff Engineer/삼성전자 Date: Mon, 18 Mar 2019 08:14:40 +0000 (+0900) Subject: Move scripts related with tflite_benchmark_model (#4770) X-Git-Tag: submit/tizen/20190325.013700~38 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=043fabd069abfe09fdd1fad9fe1518d4157c1834;p=platform%2Fcore%2Fml%2Fnnfw.git Move scripts related with tflite_benchmark_model (#4770) This commit extracts scripts related with tflite_benchmark_model from "externals/CMakeLists.txt", and move these scripts into tflite_benchmark_model project. Signed-off-by: Jonghyun Park --- diff --git a/externals/CMakeLists.txt b/externals/CMakeLists.txt index b0ac9de..cb4073f 100644 --- a/externals/CMakeLists.txt +++ b/externals/CMakeLists.txt @@ -4,10 +4,6 @@ if(NOT TensorFlowLite_FOUND) return() endif(NOT TensorFlowLite_FOUND) -if(BUILD_TFLITE_BENCHMARK_MODEL) - target_compile_definitions(tensorflow-lite PUBLIC "TFLITE_PROFILING_ENABLED") -endif() - if("${TARGET_OS}" STREQUAL "android") if(NOT DEFINED NDK_DIR) file(GLOB NDK_DIRS "${CMAKE_SOURCE_DIR}/tools/cross/ndk/*") diff --git a/tests/tools/tflite_benchmark_model/CMakeLists.txt b/tests/tools/tflite_benchmark_model/CMakeLists.txt index c48f658..7e0e9d8 100644 --- a/tests/tools/tflite_benchmark_model/CMakeLists.txt +++ b/tests/tools/tflite_benchmark_model/CMakeLists.txt @@ -2,6 +2,12 @@ if (NOT BUILD_TFLITE_BENCHMARK_MODEL) return() endif(NOT BUILD_TFLITE_BENCHMARK_MODEL) +nnfw_find_package(TensorFlowLite REQUIRED) + +# TODO Remove this target_compile_definitions command, and just check its presence. +# This change is prerequisites on pre-built tensorflow-lite package support +target_compile_definitions(tensorflow-lite PUBLIC "TFLITE_PROFILING_ENABLED") + file(GLOB_RECURSE SOURCES "*.cc") nnfw_find_package(TensorFlowSource REQUIRED)