Intel® Distribution of OpenVINO™ Toolkit
Community assistance about the Intel® Distribution of OpenVINO™ toolkit, OpenCV, and all aspects of computer vision-related on Intel® platforms.

openvino C++

Arthur123
Beginner
1,450 Views

hello everyone!

 

I have a small question as to why model inference in python would use the
"net = ie.read_network(model,weights)" api to import model and parameters (.xml & .bin)


but In the c++ call samples:

"ie.compile_model"  only the .xml file is imported, isn't the weights file (.bin) needed?

 

Expecting someone to tell me why

thanks in advance!

0 Kudos
1 Solution
Hairul_Intel
Moderator
1,403 Views

Hi Arthur123,

Thank you for reaching out to us.

 

For your information, when loading a model in OpenVINO C++ API without specifying the bin_path, the core.read_model() will try to read a bin file with the same name as xml and if no bin file is found, it will load IR without weights.

 

You can refer the class ov::Core for more information on OpenVINO Runtime C++ API.

 

Hope this helps.

 

 

Regards,

Hairul 


View solution in original post

0 Kudos
3 Replies
Hairul_Intel
Moderator
1,404 Views

Hi Arthur123,

Thank you for reaching out to us.

 

For your information, when loading a model in OpenVINO C++ API without specifying the bin_path, the core.read_model() will try to read a bin file with the same name as xml and if no bin file is found, it will load IR without weights.

 

You can refer the class ov::Core for more information on OpenVINO Runtime C++ API.

 

Hope this helps.

 

 

Regards,

Hairul 


0 Kudos
Arthur123
Beginner
1,329 Views

Get it, thanks a lot! 

0 Kudos
Hairul_Intel
Moderator
1,301 Views

Hi Arthur123,

This thread will no longer be monitored since this issue has been resolved. If you need any additional information from Intel, please submit a new question.

 

 

Regards,

Hairul


0 Kudos
Reply