| 82 | } |
| 83 | |
| 84 | TfLiteType GetTensorFlowLiteType(TF_DataType type) { |
| 85 | switch (type) { |
| 86 | case TF_FLOAT: |
| 87 | return kTfLiteFloat32; |
| 88 | case TF_HALF: |
| 89 | return kTfLiteFloat16; |
| 90 | case TF_INT16: |
| 91 | return kTfLiteInt16; |
| 92 | case TF_INT32: |
| 93 | return kTfLiteInt32; |
| 94 | case TF_UINT8: |
| 95 | return kTfLiteUInt8; |
| 96 | case TF_INT8: |
| 97 | return kTfLiteInt8; |
| 98 | case TF_INT64: |
| 99 | return kTfLiteInt64; |
| 100 | case TF_COMPLEX64: |
| 101 | return kTfLiteComplex64; |
| 102 | case TF_STRING: |
| 103 | return kTfLiteString; |
| 104 | case TF_BOOL: |
| 105 | return kTfLiteBool; |
| 106 | default: |
| 107 | return kTfLiteNoType; |
| 108 | } |
| 109 | } |
| 110 | |
| 111 | } // namespace flex |
| 112 | } // namespace tflite |
no outgoing calls