- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi everybody,
I've a problem instantiating the OpenVINO inference engine for the intel cpu. When i call AddExtension(std::make_shared<Extensions::Cpu::CpuExtensions>(), "CPU"); on the InferenceEngine instance:
Core ie;
try
{
ie.AddExtension(std::make_shared<Extensions::Cpu::CpuExtensions>(), "CPU");
}catch (const std::exception& error) {
std::cout << "Exception inference engine add extension: " << error.what() << std::endl;
return 1;
}
catch (...) {
std::cout << "Unknown/internal exception happened." << std::endl;
return 1;
}
I get the error:
error LNK2001: external symbol "__declspec(dllimport) public: virtual void __cdecl InferenceEngine::Extensions::Cpu::CpuExtensions::GetVersion(struct InferenceEngine::Version const * &)const " (__imp_?GetVersion@CpuExtensions@Cpu@Extensions@InferenceEngine@@UEBAXAEAPEBUVersion@4@@Z) not resolved.
I've linked the library correctly and imported the .dll. I don't figure what goes wrong.
Thank's for help.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Gorza, Lorenzo,
Thanks for reaching out. Looking at one of our samples this is how the ie.AddExtension is used to load the CPU extension. Have you tried something similar? Also you can find more information about the function in the reference documentation here.
// @brief message for user library argument static const char custom_cpu_library_message[] = "Required for CPU custom layers." \ "Absolute path to a shared library with the kernels implementation"; DEFINE_string(l, "", custom_cpu_library_message); Core ie; try { // CPU(MKLDNN) extensions are loaded as a shared library and passed as a pointer to base extension IExtensionPtr extension_ptr = make_so_pointer<IExtension>(FLAGS_l); ie.AddExtension(extension_ptr, "CPU"); slog::info << "CPU Extension loaded: " << FLAGS_l << slog::endl; }
Regards,
Luis
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page