depthai-experiments icon indicating copy to clipboard operation
depthai-experiments copied to clipboard

Error in Tensorflow to OpenVino Conversion in Google Colab (gen2-tf-image-classification)

Open aditya-AI opened this issue 2 years ago • 3 comments

Hi Team,

In the gen2-tf-image-classification example (Link: https://github.com/luxonis/depthai-experiments/tree/master/gen2-tf-image-classification) the TensorFlow to OpenVino (IR format) conversion is not working anymore. It was working a month ago but now its giving error. It seems to be an issue with the OpenVino installation in Google Colab as the OpenVino Validation Demo Code is also failing

/opt/intel/openvino_2021/deployment_tools/demo/demo_squeezenet_download_convert_run.sh

Below is the error I get:

Screenshot 2023-03-15 at 9 49 44 PM

To get better understanding of the error I ran the OpenVino validation demo without subprocess module below are the screenshots:

Screenshot 2023-03-15 at 9 51 46 PM

Screenshot 2023-03-15 at 9 52 06 PM

Also when the runtime in colab is GPU then the error is different:

Screenshot 2023-03-15 at 10 02 51 PM

@Erol444 please tag the ML folks who can help me with this issue. Thanks in Advance!

aditya-AI avatar Mar 15 '23 16:03 aditya-AI

@HonzaCuhel Do you mind looking into this? It's likely some version issue or some sort of Colab issue. If there's an easy way to "modernize" the notebook we should do it.

tersekmatija avatar Mar 15 '23 18:03 tersekmatija

@tersekmatija I have fixed the issue. Will update notebook and create a PR. I tried different OpenVino version, the best way to do it was with version 2022.1 however the predictions on OAK were not good the IR predictions were good. So I had refrain from using that even tried with a combination of IR and the Blob converter tool by Luxonis.

Give me sometime and would create a PR on this. Thanks!

Shall I close this issue? @tersekmatija

aditya-AI avatar Mar 15 '23 20:03 aditya-AI

Give me sometime and would create a PR on this. Thanks!

Thanks!

So I had refrain from using that even tried with a combination of IR and the Blob converter tool by Luxonis.

@aditya-AI It might be that export parameters passed to model optimizer were wrongly specified. So if you use any image normalization, this should be specified when exporting the model.

You can close the issue and open a new one if having issues with predictions or we can try solving it in this one :)

tersekmatija avatar Mar 16 '23 10:03 tersekmatija