OpenCV 4.12.0
Open Source Computer Vision
Loading...
Searching...
No Matches
cv::gapi::ov::Params< cv::gapi::Generic > Class Reference

#include <opencv2/gapi/infer/ov.hpp>

Collaboration diagram for cv::gapi::ov::Params< cv::gapi::Generic >:

Public Member Functions

 Params (const std::string &tag, const std::string &blob_path, const std::string &device)
 Params (const std::string &tag, const std::string &model_path, const std::string &bin_path, const std::string &device)
 Class constructor.
GBackend backend () const
Params< cv::gapi::Generic > & cfgInputLayers (const std::vector< std::string > &layer_names)
 Specifies sequence of network input layers names for inference.
ParamscfgInputModelLayout (detail::AttrMap< std::string > layout_map)
ParamscfgInputModelLayout (std::string layout)
ParamscfgInputTensorLayout (detail::AttrMap< std::string > layout_map)
ParamscfgInputTensorLayout (std::string layout)
ParamscfgMean (detail::AttrMap< std::vector< float > > mean_map)
ParamscfgMean (std::vector< float > mean_values)
ParamscfgNumRequests (const size_t nireq)
Params< cv::gapi::Generic > & cfgOutputLayers (const std::vector< std::string > &layer_names)
 Specifies sequence of network output layers names for inference.
ParamscfgOutputModelLayout (detail::AttrMap< std::string > layout_map)
ParamscfgOutputModelLayout (std::string layout)
ParamscfgOutputTensorLayout (detail::AttrMap< std::string > layout_map)
ParamscfgOutputTensorLayout (std::string layout)
ParamscfgOutputTensorPrecision (detail::AttrMap< int > precision_map)
ParamscfgOutputTensorPrecision (int precision)
ParamscfgPluginConfig (const detail::ParamDesc::PluginConfigT &config)
ParamscfgReshape (detail::AttrMap< std::vector< size_t > > new_shape_map)
ParamscfgReshape (std::vector< size_t > new_shape)
ParamscfgResize (detail::AttrMap< int > interpolation)
ParamscfgResize (int interpolation)
ParamscfgScale (detail::AttrMap< std::vector< float > > scale_map)
ParamscfgScale (std::vector< float > scale_values)
cv::util::any params () const
std::string tag () const

Protected Attributes

detail::ParamDesc m_desc
std::string m_tag

Constructor & Destructor Documentation

◆ Params() [1/2]

cv::gapi::ov::Params< cv::gapi::Generic >::Params ( const std::string & tag,
const std::string & model_path,
const std::string & bin_path,
const std::string & device )
inline

Class constructor.

Constructs Params based on model information and specifies default values for other inference description parameters. Model is loaded and compiled using "OpenVINO Toolkit".

Parameters
tagstring tag of the network for which these parameters are intended.
model_pathPath to a model.
bin_pathPath to a data file. For IR format (*.bin): If path is empty, will try to read a bin file with the same name as xml. If the bin file with the same name is not found, will load IR without weights. For PDPD (*.pdmodel) and ONNX (*.onnx) formats bin_path isn't used.
devicetarget device to use.
Here is the call graph for this function:

◆ Params() [2/2]

cv::gapi::ov::Params< cv::gapi::Generic >::Params ( const std::string & tag,
const std::string & blob_path,
const std::string & device )
inline

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

This constructor for pre-compiled networks. Model is imported from pre-compiled blob.

Parameters
tagstring tag of the network for which these parameters are intended.
blob_pathpath to the compiled model (*.blob).
devicetarget device to use.
Here is the call graph for this function:

Member Function Documentation

◆ backend()

GBackend cv::gapi::ov::Params< cv::gapi::Generic >::backend ( ) const
inline
Here is the call graph for this function:

◆ cfgInputLayers()

Params< cv::gapi::Generic > & cv::gapi::ov::Params< cv::gapi::Generic >::cfgInputLayers ( const std::vector< std::string > & layer_names)
inline

Specifies sequence of network input layers names for inference.

The function is used to associate cv::gapi::infer<> inputs with the model inputs. Number of names has to match the number of network inputs as defined in G_API_NET(). In case a network has only single input layer, there is no need to specify name manually.

Parameters
layer_namesstd::array<std::string, N> where N is the number of inputs as defined in the G_API_NET. Contains names of input layers.
Returns
reference to this parameter structure.

◆ cfgInputModelLayout() [1/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgInputModelLayout ( detail::AttrMap< std::string > layout_map)
inline

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Here is the call graph for this function:

◆ cfgInputModelLayout() [2/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgInputModelLayout ( std::string layout)
inline
See also
ov::Params::cfgInputModelLayout.
Here is the call graph for this function:

◆ cfgInputTensorLayout() [1/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgInputTensorLayout ( detail::AttrMap< std::string > layout_map)
inline

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Here is the call graph for this function:

◆ cfgInputTensorLayout() [2/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgInputTensorLayout ( std::string layout)
inline
See also
ov::Params::cfgInputTensorLayout.
Here is the call graph for this function:

◆ cfgMean() [1/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgMean ( detail::AttrMap< std::vector< float > > mean_map)
inline

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Here is the call graph for this function:

◆ cfgMean() [2/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgMean ( std::vector< float > mean_values)
inline
See also
ov::Params::cfgMean.
Here is the call graph for this function:

◆ cfgNumRequests()

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgNumRequests ( const size_t nireq)
inline
See also
ov::Params::cfgNumRequests.
Here is the call graph for this function:

◆ cfgOutputLayers()

Params< cv::gapi::Generic > & cv::gapi::ov::Params< cv::gapi::Generic >::cfgOutputLayers ( const std::vector< std::string > & layer_names)
inline

Specifies sequence of network output layers names for inference.

The function is used to associate cv::gapi::infer<> outputs with the model outputs. Number of names has to match the number of network outputs as defined in G_API_NET(). In case a network has only single output layer, there is no need to specify name manually.

Parameters
layer_namesstd::array<std::string, N> where N is the number of outputs as defined in the G_API_NET. Contains names of output layers.
Returns
reference to this parameter structure.

◆ cfgOutputModelLayout() [1/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgOutputModelLayout ( detail::AttrMap< std::string > layout_map)
inline

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Here is the call graph for this function:

◆ cfgOutputModelLayout() [2/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgOutputModelLayout ( std::string layout)
inline
See also
ov::Params::cfgOutputModelLayout.
Here is the call graph for this function:

◆ cfgOutputTensorLayout() [1/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgOutputTensorLayout ( detail::AttrMap< std::string > layout_map)
inline

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Here is the call graph for this function:

◆ cfgOutputTensorLayout() [2/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgOutputTensorLayout ( std::string layout)
inline
See also
ov::Params::cfgOutputTensorLayout.
Here is the call graph for this function:

◆ cfgOutputTensorPrecision() [1/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgOutputTensorPrecision ( detail::AttrMap< int > precision_map)
inline

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Here is the call graph for this function:

◆ cfgOutputTensorPrecision() [2/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgOutputTensorPrecision ( int precision)
inline
See also
ov::Params::cfgOutputTensorPrecision.
Here is the call graph for this function:

◆ cfgPluginConfig()

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgPluginConfig ( const detail::ParamDesc::PluginConfigT & config)
inline
See also
ov::Params::cfgPluginConfig.
Here is the call graph for this function:

◆ cfgReshape() [1/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgReshape ( detail::AttrMap< std::vector< size_t > > new_shape_map)
inline

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Here is the call graph for this function:

◆ cfgReshape() [2/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgReshape ( std::vector< size_t > new_shape)
inline
See also
ov::Params::cfgReshape.
Here is the call graph for this function:

◆ cfgResize() [1/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgResize ( detail::AttrMap< int > interpolation)
inline

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Here is the call graph for this function:

◆ cfgResize() [2/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgResize ( int interpolation)
inline
See also
ov::Params::cfgResize.
Here is the call graph for this function:

◆ cfgScale() [1/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgScale ( detail::AttrMap< std::vector< float > > scale_map)
inline

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Here is the call graph for this function:

◆ cfgScale() [2/2]

Params & cv::gapi::ov::Params< cv::gapi::Generic >::cfgScale ( std::vector< float > scale_values)
inline
See also
ov::Params::cfgScale.
Here is the call graph for this function:

◆ params()

◆ tag()

std::string cv::gapi::ov::Params< cv::gapi::Generic >::tag ( ) const
inline

Member Data Documentation

◆ m_desc

◆ m_tag

std::string cv::gapi::ov::Params< cv::gapi::Generic >::m_tag
protected

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