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.
6506 Discussions

Random outputs when running on iGPU in asynchronous mode

xxbird
Novice
2,611 Views

Hi all,

I was trying to run an inference on iGPU by the C++ async API.  When I compiled the model on CPU (core.compile_model(model, “CPU”)), it worked fine and the result was correct. However, when I changed the device to iGPU (core.compile_model(model, “GPU”)), the outputs became some random number.  

Does anyone occur the same issue? 

 

Thanks.

0 Kudos
11 Replies
Wan_Intel
Moderator
2,563 Views

Hi Xxbird,

Thanks for reaching out to us.

I've validated Asynchronous Inference Request with Image Classification Async C++ Sample.

 

CPU:

cpu.png

 

GPU:

gpu.png

 

Are you using the latest version of the OpenVINO™ toolkit?

 

 

Regards,

Wan

 

0 Kudos
xxbird
Novice
2,549 Views

Hi Wan,

 

Thanks for your replying. 

I am using the 2022.3 LTS version. My device is 11th Gen Core i7-1195G7 and the system is Ubuntu 18.04.

I just tried the Classification Async C++ Sample  and the results were even more strange.

 

CPU:

81678782849_.pic.jpg

91678782850_.pic.jpg

 

GPU:

71678782849_.pic.jpg

61678782848_.pic.jpg

The results were totally different between CPU and GPU. When I tried to run on the same image on GPU multiple times, the results were changing everytime. Even sometimes the CPU had the same  problem ( not everytime).  

 

Best,

0 Kudos
Wan_Intel
Moderator
2,525 Views

Hi Xxbird,

Thanks for your information.

Please share your model with us for further investigation.

 

 

Regards,

Wan

 

0 Kudos
Wan_Intel
Moderator
2,469 Views

Hi Xxbird,

Please run the Image Classification Async C++ Sample using alexnet with the sample images in the attachment and see if the results of inferencing with CPU and GPU are similar.

 

 

Best,

Wan

 

0 Kudos
xxbird
Novice
2,442 Views

hi Wan,

I ran the sample using alexnet and the results were fine.  While I tried to use the mobilenet-v2 caffe version (https://docs.openvino.ai/latest/omz_models_model_mobilenet_v2.html), the results became weird on GPU (but it worked fine on CPU). 

xxbird_0-1679470525854.jpeg

Btw, I just used the "omz_converter" command to convert the model.

 

Best.

0 Kudos
xxbird
Novice
2,415 Views

I tested the models on my PC and the results were correct, so I am sure the model was converted in the right way.

Wan_Intel
Moderator
2,380 Views

Hi Xxbird,

Thanks for your information.

Glad to know the results were correct when the models were tested on your PC.

 

I've also validated the results of running Image Classification Async C++ Sample using mobilenet-v2 (FP16) with CPU and GPU.

 

CPU:

cpu_mobilenet.png

 

GPU:

gpu_mobilenet.png

 

 

Regards,

Wan

 

0 Kudos
xxbird
Novice
2,342 Views

Hi Wan,

 

I have found that it might be because the Opencl was not installed correctly.

 

Thanks for your help.

 

bouachalazhar
Beginner
2,223 Views

Hi, have you a link for install OpenCL on Windows 11 or Ubuntu 22.04 ?

0 Kudos
xxbird
Novice
2,212 Views
0 Kudos
Wan_Intel
Moderator
2,281 Views

Hi Xxbird,

Thanks for providing your solution in the community.

We're glad to know that your issue has been resolved after installing OpenCL™ for GPU. Therefore, this thread will no longer be monitored since the issue has been resolved. If you need additional information from Intel, please submit a new question.

 

 

Regards,

Wan

 

0 Kudos
Reply