#include "tensorflow_lite_support/cc/port/default/tflite_wrapper.h"
#include "absl/status/status.h"
#include "absl/strings/str_format.h"
#include "tensorflow/lite/acceleration/configuration/flatbuffer_to_proto.h"
#include "tensorflow/lite/acceleration/configuration/proto_to_flatbuffer.h"
#include "tensorflow/lite/c/common.h"
#include "tensorflow/lite/delegates/interpreter_utils.h"
#include "tensorflow/lite/minimal_logging.h"
#include "tensorflow_lite_support/cc/port/status_macros.h"
namespace tflite {
namespace support {
namespace {
DelegatePluginRegistry;
InterpreterUtils;
ComputeSettings;
Delegate;
}
absl::Status TfLiteInterpreterWrapper::SanityCheckComputeSettings(
const ComputeSettings& compute_settings) { … }
TfLiteInterpreterWrapper::TfLiteInterpreterWrapper(
const std::string& default_model_namespace,
const std::string& default_model_id)
: … { … }
std::string TfLiteInterpreterWrapper::ModelNamespace() { … }
std::string TfLiteInterpreterWrapper::ModelID() { … }
absl::Status TfLiteInterpreterWrapper::InitializeWithFallback(
std::function<absl::Status(std::unique_ptr<tflite::Interpreter>*)>
interpreter_initializer,
const ComputeSettings& compute_settings) { … }
absl::Status TfLiteInterpreterWrapper::InitializeWithFallback(
std::function<absl::Status(const InterpreterCreationResources&,
std::unique_ptr<tflite::Interpreter>*)>
interpreter_initializer,
const ComputeSettings& compute_settings) { … }
absl::Status TfLiteInterpreterWrapper::AllocateTensors() { … }
absl::Status TfLiteInterpreterWrapper::InitializeWithFallbackAndResize(
std::function<absl::Status(Interpreter*)> resize) { … }
absl::Status TfLiteInterpreterWrapper::InitializeDelegate() { … }
absl::Status TfLiteInterpreterWrapper::InvokeWithFallback(
const std::function<absl::Status(tflite::Interpreter* interpreter)>&
set_inputs) { … }
absl::Status TfLiteInterpreterWrapper::InvokeWithoutFallback() { … }
void TfLiteInterpreterWrapper::Cancel() { … }
void TfLiteInterpreterWrapper::SetTfLiteCancellation() { … }
absl::Status TfLiteInterpreterWrapper::LoadDelegatePlugin(
const std::string& name, const tflite::TFLiteSettings& tflite_settings) { … }
bool TfLiteInterpreterWrapper::HasMiniBenchmarkCompleted() { … }
}
}