This is an interface for the OpResolver for TFLiteMicro.
class MicroOpResolverThis is an interface for the OpResolver for TFLiteMicro. The differences from the TFLite OpResolver base class are to:
- explicitly remove support for Op versions
- allow for finer grained registration of the Builtin Ops to reduce code size for TFLiteMicro.
We need an interface class instead of directly using MicroMutableOpResolver because MicroMutableOpResolver is a class template with the number of registered Ops as the template parameter.
FindOp
C++Returns the Op registration struct corresponding to the enum code from the flatbuffer schema.
virtual const TFLMRegistration * tflite::MicroOpResolver::FindOp(BuiltinOperator op) const = 0Returns the Op registration struct corresponding to the enum code from the flatbuffer schema. Returns nullptr if the op is not found or if op == BuiltinOperator_CUSTOM.
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
op | BuiltinOperator | Required |
FindOp
C++Returns the Op registration struct corresponding to the custom operator by name.
virtual const TFLMRegistration * tflite::MicroOpResolver::FindOp(const char *op) const = 0Returns the Op registration struct corresponding to the custom operator by name.
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
op | const char * | Required |
Returns the operator specific parsing function for the OpData for a BuiltinOperator (if registered), else nullptr.
virtual TfLiteBridgeBuiltinParseFunction tflite::MicroOpResolver::GetOpDataParser(BuiltinOperator op) const = 0Returns the operator specific parsing function for the OpData for a BuiltinOperator (if registered), else nullptr.
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
op | BuiltinOperator | Required |
virtual tflite::MicroOpResolver::~MicroOpResolver()