Class ov::frontend::FrontEnd#
-
class FrontEnd#
An interface for identifying a frontend for a particular framework. Provides an ability to load and convert of input model.
Unnamed Group
-
void add_extension(const std::string &library_path)#
Registers extension.
- Parameters:
library_path – path to library with ov::Extension
Public Functions
-
FrontEnd()#
Default constructor.
-
template<typename ...Types>
inline bool supported(const Types&... vars) const# Validates if FrontEnd can recognize model with parameters specified. Same parameters should be used to load model.
- Parameters:
vars – Any number of parameters of any type. What kind of parameters are accepted is determined by each FrontEnd individually, typically it is std::string containing path to the model file. For more information please refer to specific FrontEnd documentation.
- Returns:
true if model recognized, false - otherwise.
-
template<typename ...Types>
inline InputModel::Ptr load(const Types&... vars) const# Loads an input model by any specified arguments. Each FrontEnd separately defines what arguments it can accept.
- Parameters:
vars – Any number of parameters of any type. What kind of parameters are accepted is determined by each FrontEnd individually, typically it is std::string containing path to the model file. For more information please refer to specific FrontEnd documentation.
- Returns:
Loaded input model.
-
virtual std::shared_ptr<ov::Model> convert(const InputModel::Ptr &model) const#
Completely convert and normalize entire Model, throws if it is not possible.
Completely convert the remaining, not converted part of a Model.
- Parameters:
partiallyConverted – partially converted OV Model
-
virtual std::shared_ptr<ov::Model> convert_partially(const InputModel::Ptr &model) const#
Convert only those parts of the model that can be converted leaving others as-is wrapped by FrameworkNode. Converted parts are normalized by additional transformations like it is done in convert method. If part of the graph cannot be converted, it is not guaranteed that the converted regions are completely normalized. Normalize should be called for each completely converted parts individually in this case.
-
virtual std::shared_ptr<ov::Model> decode(const InputModel::Ptr &model) const#
Convert operations with one-to-one mapping with decoding nodes. Each decoding node is an OV node representing a single FW operation node with all attributes represented in FW-independent way.
Runs normalization passes on Model that was loaded with partial conversion.
- Parameters:
Model – partially converted OV Model
-
virtual std::string get_name() const#
Gets name of this FrontEnd. Can be used by clients if frontend is selected automatically by FrontEndManager::load_by_model.
- Returns:
Current frontend name. Empty string if not implemented
Register base extension in the FrontEnd.
- Parameters:
extension – base extension
Register base extensions in the FrontEnd.
- Parameters:
extensions – vector of extensions
-
void add_extension(const std::string &library_path)#