Group Variable state base classes

group ov_dev_api_variable_state_api

A set of base and helper classes to implement variable state.

interface IVariableState : public std::enable_shared_from_this<IVariableState>
#include <ivariable_state.hpp>

Minimal interface for variable state implementation.

Public Functions

virtual const std::string &get_name() const

Gets a variable state name.


A string representing variable state name

virtual void reset()

Reset internal variable state for relevant infer request, to a value specified as default for according ReadValue node.

virtual void set_state(const ov::SoPtr<ov::ITensor> &state)

Sets the new state for the next inference.


newState – A new state

virtual ov::SoPtr<ov::ITensor> get_state() const

Returns the value of the variable state.


The value of the variable state