}
int ret = mBackendHandle->Load(model_paths, model_format);
- if (ret != INFERENCE_ENGINE_ERROR_NONE)
+ if (ret != INFERENCE_ENGINE_ERROR_NONE) {
LOGE("Fail to load InferenceEngineVision");
+ mUseProfiler = false;
+ }
if (mUseProfiler == true) {
mProfiler->Stop(IE_PROFILER_LATENCY, "Load");
}
int ret = mBackendHandle->Run(input_buffers, output_buffers);
+ if (ret != INFERENCE_ENGINE_ERROR_NONE) {
+ LOGE("Failed to inference.");
+ mUseProfiler = false;
+ }
if (mUseProfiler == true) {
mProfiler->Stop(IE_PROFILER_LATENCY, "Run");