Public Types | Public Member Functions
InferenceEngine::IExecutableNetwork Class Referenceabstract

This is an interface of an executable network. More...

#include <ie_iexecutable_network.hpp>

Inheritance diagram for InferenceEngine::IExecutableNetwork:
Inheritance graph
[legend]
Collaboration diagram for InferenceEngine::IExecutableNetwork:
Collaboration graph
[legend]

Public Types

using Ptr = std::shared_ptr< IExecutableNetwork >
 A smart pointer to the current IExecutableNetwork object.
 

Public Member Functions

virtual StatusCode GetOutputsInfo (ConstOutputsDataMap &out, ResponseDesc *resp) const noexcept=0
 Gets the Executable network output Data node information. More...
 
virtual StatusCode GetInputsInfo (ConstInputsDataMap &inputs, ResponseDesc *resp) const noexcept=0
 Gets the executable network input Data node information. More...
 
virtual StatusCode CreateInferRequest (IInferRequest::Ptr &req, ResponseDesc *resp) noexcept=0
 Creates an inference request object used to infer the network. More...
 
virtual StatusCode Export (const std::string &modelFileName, ResponseDesc *resp) noexcept=0
 Exports the current executable network. More...
 
virtual StatusCode Export (std::ostream &networkModel, ResponseDesc *resp) noexcept=0
 Exports the current executable network. More...
 
virtual StatusCode GetMappedTopology (std::map< std::string, std::vector< PrimitiveInfo::Ptr >> &deployedTopology, ResponseDesc *resp) noexcept=0
 Get the mapping of IR layer names to implemented kernels. More...
 
virtual StatusCode GetExecGraphInfo (ICNNNetwork::Ptr &graphPtr, ResponseDesc *resp) noexcept=0
 Get executable graph information from a device. More...
 
virtual StatusCode QueryState (IMemoryState::Ptr &pState, size_t idx, ResponseDesc *resp) noexcept=0
 Gets state control interface for given executable network. More...
 
virtual StatusCode SetConfig (const std::map< std::string, Parameter > &config, ResponseDesc *resp) noexcept=0
 Sets configuration for current executable network. More...
 
virtual StatusCode GetConfig (const std::string &name, Parameter &result, ResponseDesc *resp) const noexcept=0
 Gets configuration for current executable network. More...
 
virtual StatusCode GetMetric (const std::string &name, Parameter &result, ResponseDesc *resp) const noexcept=0
 Gets general runtime metric for an executable network. More...
 
virtual StatusCode GetContext (RemoteContext::Ptr &pContext, ResponseDesc *resp) const noexcept=0
 Gets shared context used to create an executable network. More...
 

Detailed Description

This is an interface of an executable network.

Member Function Documentation

§ CreateInferRequest()

virtual StatusCode InferenceEngine::IExecutableNetwork::CreateInferRequest ( IInferRequest::Ptr req,
ResponseDesc resp 
)
pure virtualnoexcept

Creates an inference request object used to infer the network.

The created request has allocated input and output blobs (that can be changed later).

Parameters
reqShared pointer to the created request object
respOptional: pointer to an already allocated object to contain information in case of failure
Returns
Status code of the operation: InferenceEngine::OK (0) for success

§ Export() [1/2]

virtual StatusCode InferenceEngine::IExecutableNetwork::Export ( const std::string &  modelFileName,
ResponseDesc resp 
)
pure virtualnoexcept

Exports the current executable network.

See also
Core::ImportNetwork
IInferencePlugin::ImportNetwork
Parameters
modelFileNameFull path to the location of the exported file
respOptional: pointer to an already allocated object to contain information in case of failure
Returns
Status code of the operation: InferenceEngine::OK (0) for success

§ Export() [2/2]

virtual StatusCode InferenceEngine::IExecutableNetwork::Export ( std::ostream &  networkModel,
ResponseDesc resp 
)
pure virtualnoexcept

Exports the current executable network.

See also
Core::ImportNetwork
IInferencePlugin::ImportNetwork
Parameters
networkModelNetwork model output stream
respOptional: pointer to an already allocated object to contain information in case of failure
Returns
Status code of the operation: InferenceEngine::OK (0) for success

§ GetConfig()

virtual StatusCode InferenceEngine::IExecutableNetwork::GetConfig ( const std::string &  name,
Parameter result,
ResponseDesc resp 
) const
pure virtualnoexcept

Gets configuration for current executable network.

The method is responsible to extract information which affects executable network execution. The list of supported configuration values can be extracted via ExecutableNetwork::GetMetric with the SUPPORTED_CONFIG_KEYS key, but some of these keys cannot be changed dymanically, e.g. DEVICE_ID cannot changed if an executable network has already been compiled for particular device.

Parameters
nameconfig key, can be found in ie_plugin_config.hpp
resultvalue of config corresponding to config key
respPointer to the response message that holds a description of an error if any occurred
Returns
code of the operation. InferenceEngine::OK if succeeded

§ GetContext()

virtual StatusCode InferenceEngine::IExecutableNetwork::GetContext ( RemoteContext::Ptr pContext,
ResponseDesc resp 
) const
pure virtualnoexcept

Gets shared context used to create an executable network.

Parameters
pContextRefernce to a pointer that will receive resulting shared context object ptr
respPointer to the response message that holds a description of an error if any occurred
Returns
code of the operation. InferenceEngine::OK if succeeded

§ GetExecGraphInfo()

virtual StatusCode InferenceEngine::IExecutableNetwork::GetExecGraphInfo ( ICNNNetwork::Ptr graphPtr,
ResponseDesc resp 
)
pure virtualnoexcept

Get executable graph information from a device.

Parameters
graphPtrnetwork ptr to store executable graph information
respOptional: pointer to an already allocated object to contain information in case of failure
Returns
Status code of the operation: InferenceEngine::OK (0) for success

§ GetInputsInfo()

virtual StatusCode InferenceEngine::IExecutableNetwork::GetInputsInfo ( ConstInputsDataMap inputs,
ResponseDesc resp 
) const
pure virtualnoexcept

Gets the executable network input Data node information.

The received info is stored in the given ConstInputsDataMap object. This method need to be called to find out input names for using them later during filling of a map of blobs passed to InferenceEngine::IInferencePlugin::Infer()

Parameters
inputsReference to ConstInputsDataMap object.
respOptional: pointer to an already allocated object to contain information in case of failure
Returns
Status code of the operation: InferenceEngine::OK (0) for success

§ GetMappedTopology()

virtual StatusCode InferenceEngine::IExecutableNetwork::GetMappedTopology ( std::map< std::string, std::vector< PrimitiveInfo::Ptr >> &  deployedTopology,
ResponseDesc resp 
)
pure virtualnoexcept

Get the mapping of IR layer names to implemented kernels.

Deprecated:
Use ExecutableNetwork::GetExecGraphInfo to get information about an internal graph. The method will be removed in 2021.1 release.
Parameters
deployedTopologyMap of PrimitiveInfo objects that represent the deployed topology
respOptional: pointer to an already allocated object to contain information in case of failure
Returns
Status code of the operation: InferenceEngine::OK (0) for success

§ GetMetric()

virtual StatusCode InferenceEngine::IExecutableNetwork::GetMetric ( const std::string &  name,
Parameter result,
ResponseDesc resp 
) const
pure virtualnoexcept

Gets general runtime metric for an executable network.

It can be network name, actual device ID on which executable network is running or all other properties which cannot be changed dynamically.

Parameters
namemetric name to request
resultmetric value corresponding to metric key
respPointer to the response message that holds a description of an error if any occurred
Returns
code of the operation. InferenceEngine::OK if succeeded

§ GetOutputsInfo()

virtual StatusCode InferenceEngine::IExecutableNetwork::GetOutputsInfo ( ConstOutputsDataMap out,
ResponseDesc resp 
) const
pure virtualnoexcept

Gets the Executable network output Data node information.

The received info is stored in the given ConstOutputsDataMap node. This method need to be called to find output names for using them later during filling of a map of blobs passed to InferenceEngine::IInferencePlugin::Infer()

Parameters
outReference to the ConstOutputsDataMap object
respOptional: pointer to an already allocated object to contain information in case of failure
Returns
Status code of the operation: InferenceEngine::OK (0) for success

§ QueryState()

virtual StatusCode InferenceEngine::IExecutableNetwork::QueryState ( IMemoryState::Ptr pState,
size_t  idx,
ResponseDesc resp 
)
pure virtualnoexcept

Gets state control interface for given executable network.

State control essential for recurrent networks

Parameters
pStatereference to a pointer that receives internal states
idxrequested index for receiving memory state
respOptional: pointer to an already allocated object to contain information in case of failure
Returns
Status code of the operation: InferenceEngine::OK (0) for success, OUT_OF_BOUNDS (-6) no memory state for given index

§ SetConfig()

virtual StatusCode InferenceEngine::IExecutableNetwork::SetConfig ( const std::map< std::string, Parameter > &  config,
ResponseDesc resp 
)
pure virtualnoexcept

Sets configuration for current executable network.

Parameters
configMap of pairs: (config parameter name, config parameter value)
respPointer to the response message that holds a description of an error if any occurred
Returns
code of the operation. InferenceEngine::OK if succeeded

The documentation for this class was generated from the following file: