EyeAI
Loading...
Searching...
No Matches
MetricDepthModel Class Reference

#include <MetricDepthModel.hpp>

Public Types

using CreateResult
 
using RunResult
 

Public Member Functions

RunResult run (FloatTensorBuffer< FloatTensorFormat::ImageRGB255 > &input)
 
std::span< const int > get_input_shape () const
 
std::span< const int > get_output_shape () const
 
 MetricDepthModel (std::unique_ptr< DepthModel > &&depth_model)
 

Static Public Member Functions

static CreateResult create (std::vector< int8_t > &&depth_model_data, std::string_view gpu_delegate_serialization_dir, std::string_view depth_model_token, TfLiteLogWarningCallback log_warning_callback, TfLiteLogErrorCallback log_error_callback, bool enable_npu, std::string npu_skel_directory)
 

Static Public Attributes

static constexpr size_t POLYNOMIAL_DEGREE = 4
 
static constexpr size_t COEFFS_COUNT = POLYNOMIAL_DEGREE + 1
 

Member Typedef Documentation

◆ CreateResult

Initial value:
tl::
expected<std::unique_ptr<MetricDepthModel>, TfLiteCreateRuntimeError>

◆ RunResult

Initial value:
tl::expected<
TfLiteRunInferenceError>
TensorBuffer< float, FloatTensorFormat, FORMAT > FloatTensorBuffer
Definition TensorBuffer.hpp:106

Constructor & Destructor Documentation

◆ MetricDepthModel()

MetricDepthModel::MetricDepthModel ( std::unique_ptr< DepthModel > && depth_model)

Member Function Documentation

◆ create()

MetricDepthModel::CreateResult MetricDepthModel::create ( std::vector< int8_t > && depth_model_data,
std::string_view gpu_delegate_serialization_dir,
std::string_view depth_model_token,
TfLiteLogWarningCallback log_warning_callback,
TfLiteLogErrorCallback log_error_callback,
bool enable_npu,
std::string npu_skel_directory )
staticnodiscard

◆ get_input_shape()

std::span< const int > MetricDepthModel::get_input_shape ( ) const
nodiscard

◆ get_output_shape()

std::span< const int > MetricDepthModel::get_output_shape ( ) const
nodiscard

◆ run()

MetricDepthModel::RunResult MetricDepthModel::run ( FloatTensorBuffer< FloatTensorFormat::ImageRGB255 > & input)
nodiscard
Parameters
inputshould be 3 * width * height

Member Data Documentation

◆ COEFFS_COUNT

size_t MetricDepthModel::COEFFS_COUNT = POLYNOMIAL_DEGREE + 1
staticconstexpr

◆ POLYNOMIAL_DEGREE

size_t MetricDepthModel::POLYNOMIAL_DEGREE = 4
staticconstexpr