* Renaming all frontends from "*_ngraph_frontend*" to "_ov_frontend*" Also Debug builds on Windows release frontends without "d" suffix will not be loaded * Fix review comments and add wheels test debug prints * More debug prints * Load by absolute path and remove debug prints
38 lines
959 B
C++
38 lines
959 B
C++
// Copyright (C) 2018-2021 Intel Corporation
|
|
// SPDX-License-Identifier: Apache-2.0
|
|
//
|
|
|
|
#include "frontend_manager/frontend_manager.hpp"
|
|
#include "frontend_manager/frontend_manager_defs.hpp"
|
|
#include "ngraph/visibility.hpp"
|
|
|
|
// Defined if we are building the plugin DLL (instead of using it)
|
|
#ifdef mock1_ov_frontend_EXPORTS
|
|
# define MOCK_API OPENVINO_CORE_EXPORTS
|
|
#else
|
|
# define MOCK_API OPENVINO_CORE_IMPORTS
|
|
#endif // mock1_ov_frontend_EXPORTS
|
|
|
|
using namespace ngraph;
|
|
using namespace ov::frontend;
|
|
|
|
class FrontEndMock : public FrontEnd {
|
|
public:
|
|
std::string get_name() const override {
|
|
return "mock1";
|
|
}
|
|
};
|
|
|
|
extern "C" MOCK_API FrontEndVersion GetAPIVersion() {
|
|
return OV_FRONTEND_API_VERSION;
|
|
}
|
|
|
|
extern "C" MOCK_API void* GetFrontEndData() {
|
|
FrontEndPluginInfo* res = new FrontEndPluginInfo();
|
|
res->m_name = "mock1";
|
|
res->m_creator = []() {
|
|
return std::make_shared<FrontEndMock>();
|
|
};
|
|
return res;
|
|
}
|