MLBEDSW-5366 - TLCT: Some TensorTypes were missing
This commit add some TensorTypes that were missing
to the TensorFlow Lite mapping.
Signed-off-by: Dwight Lidman <dwight.lidman@arm.com>
Change-Id: I15e80769491e8f3093c14270cf2e312f1568dfc8
diff --git a/ethosu/vela/tflite_mapping.py b/ethosu/vela/tflite_mapping.py
index 02e91c7..d52e074 100644
--- a/ethosu/vela/tflite_mapping.py
+++ b/ethosu/vela/tflite_mapping.py
@@ -160,6 +160,10 @@
TensorType.BOOL: DataType.bool,
TensorType.COMPLEX64: DataType.complex64,
TensorType.COMPLEX128: DataType.complex128,
+ TensorType.UINT64: DataType.uint64,
+ TensorType.RESOURCE: DataType.resource,
+ TensorType.VARIANT: DataType.variant,
+ TensorType.UINT32: DataType.uint32,
}
datatype_inv_map = inverse_map(datatype_map)
@@ -172,6 +176,8 @@
datatype_map_numpy = {
TensorType.UINT8: np.uint8,
+ TensorType.UINT32: np.uint32,
+ TensorType.UINT64: np.uint64,
TensorType.INT8: np.int8,
TensorType.INT16: np.int16,
TensorType.INT32: np.int32,
@@ -183,6 +189,8 @@
TensorType.COMPLEX64: np.complex64,
TensorType.COMPLEX128: np.complex128,
TensorType.STRING: np.uint8,
+ TensorType.RESOURCE: None, # experimental type
+ TensorType.VARIANT: None, # experimental type
}