with the new version of TFLite, the new data types have been added. Since it's not supported and we cannot check the version of tensorflow at the build time, we have to set the datatype before building this package. I'd like to suggest adding a field at meson_option and allow user to set it.
Signed-off-by: HyoungJoo Ahn <hello.ahn@samsung.com>
else
error('Cannot find tensorflow-lite')
endif
+
+ tflite_datatype_arr = get_option('enable-additional-tflite-types')
+ foreach tflite_data_type : tflite_datatype_arr
+ message('data type [@0@] is added for TFLite'.format(tflite_data_type))
+ add_project_arguments('-DTFLITE_@0@=1'.format(tflite_data_type), language: ['c', 'cpp'])
+ endforeach
+
endif
# PyTorch
option('enable-edgetpu', type: 'boolean', value: false)
option('enable-armnn', type: 'boolean', value: false)
option('enable-openvino', type: 'boolean', value: false)
+option('enable-additional-tflite-types', type : 'array', choices : ['INT16','COMPLEX64','INT8','FLOAT16'], value : ['INT16','COMPLEX64','INT8'])