From 4f0d2b8309ccb4a5539c0625aa3336d439f60840 Mon Sep 17 00:00:00 2001 From: Yongjoo Ahn Date: Tue, 13 Jun 2023 16:18:05 +0900 Subject: [PATCH] [filter] Show deprecate message for tflite1 filter - tflite1 is going to be dropped in Tizen image. - Show deprecate warning message when the tflite1 subplugin is opened and in build time. Signed-off-by: Yongjoo Ahn --- ext/nnstreamer/tensor_filter/tensor_filter_tensorflow_lite.cc | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/ext/nnstreamer/tensor_filter/tensor_filter_tensorflow_lite.cc b/ext/nnstreamer/tensor_filter/tensor_filter_tensorflow_lite.cc index 6fb311c..c43e595 100644 --- a/ext/nnstreamer/tensor_filter/tensor_filter_tensorflow_lite.cc +++ b/ext/nnstreamer/tensor_filter/tensor_filter_tensorflow_lite.cc @@ -39,6 +39,10 @@ #include #include +#if TFLITE_VERSION_MAJOR < 2 +#pragma message("tensor_filter of TensorFlow Lite version 1.X is deprecated. Please use of TF Lite 2.X") +#endif + #if TFLITE_VERSION_MAJOR >= 2 || TFLITE_VERSION_MINOR >= 13 #if USE_TENSORFLOW2_HEADER_PATH #include @@ -1437,6 +1441,9 @@ done: static int tflite_open (const GstTensorFilterProperties *prop, void **private_data) { +#if TFLITE_VERSION_MAJOR < 2 + ml_logw ("tensor_filter of TensorFlow Lite version 1.X is deprecated. Please use of TF Lite 2.X"); +#endif int status = tflite_loadModelFile (prop, private_data); return status; -- 2.7.4