mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-20 05:10:11 +01:00
teflon: Add support for the ResizeNearestNeighbor operation
Acked-by: Christian Gmeiner <cgmeiner@igalia.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/36699>
This commit is contained in:
parent
0001dab219
commit
b3262b37ce
2 changed files with 10 additions and 0 deletions
|
|
@ -269,6 +269,10 @@ fill_operation(struct teflon_delegate *delegate, TfLiteContext *tf_context, TfLi
|
|||
|
||||
break;
|
||||
}
|
||||
case kTfLiteBuiltinResizeNearestNeighbor: {
|
||||
operation->type = PIPE_ML_OPERATION_TYPE_RESIZE;
|
||||
break;
|
||||
}
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
|
|
@ -420,6 +424,9 @@ dump_graph(struct pipe_tensor *tensors, unsigned tensor_count, struct pipe_ml_op
|
|||
case PIPE_ML_OPERATION_TYPE_STRIDED_SLICE:
|
||||
teflon_debug("%-6s ", "STRIDED_SLICE");
|
||||
break;
|
||||
case PIPE_ML_OPERATION_TYPE_RESIZE:
|
||||
teflon_debug("%-6s ", "RESIZE");
|
||||
break;
|
||||
}
|
||||
|
||||
for (unsigned j = 0; j < operations[i].input_count; j++) {
|
||||
|
|
@ -629,6 +636,8 @@ tflite_builtin_op_name(TfLiteBuiltinOperator op)
|
|||
return "MEAN";
|
||||
case kTfLiteBuiltinStridedSlice:
|
||||
return "STRIDED_SLICE";
|
||||
case kTfLiteBuiltinResizeNearestNeighbor:
|
||||
return "RESIZE";
|
||||
default:
|
||||
return "unknown";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1055,6 +1055,7 @@ enum pipe_ml_operation_type {
|
|||
PIPE_ML_OPERATION_TYPE_SUBTRACT,
|
||||
PIPE_ML_OPERATION_TYPE_TRANSPOSE,
|
||||
PIPE_ML_OPERATION_TYPE_STRIDED_SLICE,
|
||||
PIPE_ML_OPERATION_TYPE_RESIZE,
|
||||
};
|
||||
|
||||
enum pipe_ml_pooling_type {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue