* remove ov::device::thermal ov::device::thermal was only supported on myriad * additional cleanup * remove myriad from AUTO and MULTI auto n multi n hetero + remove mentions of listing myriad devices * two final fixes * Update ov_auto.py --------- Co-authored-by: Ilya Churaev <ilya.churaev@intel.com>
23 lines
711 B
C++
23 lines
711 B
C++
#include <openvino/openvino.hpp>
|
|
|
|
int main() {
|
|
ov::AnyMap cpu_config, gpu_config;
|
|
//! [part4]
|
|
ov::Core core;
|
|
|
|
// Read a network in IR, PaddlePaddle, or ONNX format:
|
|
std::shared_ptr<ov::Model> model = core.read_model("sample.xml");
|
|
|
|
// When compiling the model on MULTI, configure GPU and CPU
|
|
// (devices, priorities, and device configurations):
|
|
ov::CompiledModel compileModel = core.compile_model(model, "MULTI",
|
|
ov::device::priorities("GPU", "CPU"),
|
|
ov::device::properties("GPU", gpu_config),
|
|
ov::device::properties("CPU", cpu_config));
|
|
|
|
// Optionally, query the optimal number of requests:
|
|
uint32_t nireq = compileModel.get_property(ov::optimal_number_of_infer_requests);
|
|
//! [part4]
|
|
return 0;
|
|
}
|