Hello, we have trained successfully a YoloV5 and converted it to uint8.
The benchmark
./benchmark_model --graph=model.tflite --external_delegate_path=/usr/lib/libvx_delegate.so --enable_op_profiling=true
benchmark output :
External delegate path: [/usr/lib/libvx_delegate.so]
Loaded model model.tflite
Vx delegate: allowed_builtin_code set to 0.
Vx delegate: error_during_init set to 0.
Vx delegate: error_during_prepare set to 0.
Vx delegate: error_during_invoke set to 0.
EXTERNAL delegate created.
Going to apply 1 delegates one after another.
Explicitly applied EXTERNAL delegate, and the model graph will be completely executed by the delegate.
The input model file size (MB): 1.98869
Shows inference speed of ~66 ms which is not too bad. The output also shows that the inference is completely executed on the npu.
I started to implement the extraction of the bounding box from the prediction of the input image. I used python for a quick evaluation :
If you haven't resolved your issue yet you might need to open a support ticket.
It took me two different tickets but I finally received a patch from NXP support that I applied to op_map.cc in the vx-delegate. That resolved the issue for us and we can now get good results from the NPU that are very close to the CPU results.
Is that patch public? Can you share it with us? We are facing the same issues.
@taklause can you share the inference code ? I am facing similar issue.
Hi @Zhiming_Liu ,
I did as the document suggested.
As a remark, all the models are quantized with the same images. The models (raw - pb and converted tflite from Ultralytics) are also attached.
Regards
Hi @taklause
Send you the test code.
Hello @Zhiming_Liu ,
I reply directly in hope someone would help me fix the problem ;).
I m still having no detection inferencing with the NPU. Only the CPU gives me good detections, even when
I convert them with the eIQ tool you suggested.
Thanks, regards Daniel
Hello @taklause
Please provide test image and label.
Hello @Zhiming_Liu,
thanks for the support.
I attach two models, the pb file as the yolov5 unconverted and the efficientdetlite0 already converted.
Both deliver no results with the NPU, only with the CPU.
It is only a person detector, trained with the persons from COCO17 and a little bit of our data. There are three images and the label.txt.
Thanks again for looking into it.
Daniel
Which tag you used about yolov5, v7.0?
Have you changed any net struct in your training?
Hi @Zhiming_Liu ,
the access to the file was denied, I cant watch it.