This class represents a network instance loaded to plugin and ready for inference. More...
Public Member Functions | |
def | __init__ (self) |
There is no explicit class constructor. More... | |
def | infer (self, inputs=None) |
Starts synchronous inference for the first infer request of the executable network and returns output data. More... | |
def | start_async (self, request_id, inputs=None) |
Starts asynchronous inference for specified infer request. More... | |
def | requests (self) |
A tuple of InferRequest instances. | |
def | input_info (self) |
A dictionary that maps input layer names to InputInfoCPtr objects. | |
def | inputs (self) |
def | outputs (self) |
A dictionary that maps output layer names to CDataPtr objects. | |
def | get_exec_graph_info (self) |
Gets executable graph information from a device. More... | |
def | get_metric (self, metric_name) |
Gets general runtime metric for an executable network. More... | |
def | get_config (self, config_name) |
Gets configuration for current executable network. More... | |
def | export (self, model_file) |
Exports the current executable network. More... | |
def | wait (self, num_requests=None, timeout=None) |
Waits when the result from any request becomes available. More... | |
def | get_idle_request_id (self) |
Get idle request ID. More... | |
Data Fields | |
requests | |
A tuple of InferRequest instances. | |
input_info | |
A dictionary that maps input layer names to InputInfoCPtr objects. | |
inputs | |
outputs | |
A dictionary that maps output layer names to CDataPtr objects. | |
This class represents a network instance loaded to plugin and ready for inference.
def ie_api.ExecutableNetwork.__init__ | ( | self | ) |
There is no explicit class constructor.
To make a valid instance of ExecutableNetwork
, use load_network()
method of the IECore
class.
def ie_api.ExecutableNetwork.export | ( | self, | |
model_file | |||
) |
Exports the current executable network.
model_file | Full path to the target exported file location |
def ie_api.ExecutableNetwork.get_config | ( | self, | |
config_name | |||
) |
Gets configuration for current executable network.
The method is responsible to extract information which affects executable network execution
config_name | A configuration parameter name to request. |
Usage example:
def ie_api.ExecutableNetwork.get_exec_graph_info | ( | self | ) |
Gets executable graph information from a device.
IENetwork
Usage example:
def ie_api.ExecutableNetwork.get_idle_request_id | ( | self | ) |
Get idle request ID.
def ie_api.ExecutableNetwork.get_metric | ( | self, | |
metric_name | |||
) |
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.
metric_name | A metric name to request. |
Usage example:
def ie_api.ExecutableNetwork.infer | ( | self, | |
inputs = None |
|||
) |
Starts synchronous inference for the first infer request of the executable network and returns output data.
Wraps infer()
method of the InferRequest
class
inputs | A dictionary that maps input layer names to numpy.ndarray objects of proper shape with input data for the layer |
numpy.ndarray
objects with output data of the layerUsage example:
def ie_api.ExecutableNetwork.inputs | ( | self | ) |
A dictionary that maps input layer names to DataPtr objects
def ie_api.ExecutableNetwork.start_async | ( | self, | |
request_id, | |||
inputs = None |
|||
) |
Starts asynchronous inference for specified infer request.
Wraps async_infer()
method of the InferRequest
class.
request_id | Index of infer request to start inference |
inputs | A dictionary that maps input layer names to numpy.ndarray objects of proper shape with input data for the layer |
InferRequest
class.Usage example:
def ie_api.ExecutableNetwork.wait | ( | self, | |
num_requests = None , |
|||
timeout = None |
|||
) |
Waits when the result from any request becomes available.
Blocks until specified timeout elapses or the result.
num_requests | Number of idle requests for which wait. If not specified, num_requests value is set to number of requests by default. |
timeout | Time to wait in milliseconds or special (0, -1) cases described above. If not specified, timeout value is set to -1 by default. |
ie_api.ExecutableNetwork.inputs |
A dictionary that maps input layer names to DataPtr objects