Got it

Yolov3 object detection Inference Atlas200DK Error!

Created: May 17, 2021 01:24:22Latest reply: May 28, 2021 09:27:55 951 13 2 0 1
  HiCoins as reward: 0 (problem unresolved)

Hello,

I trained a tensorflow Yolov3 implementation from here: https://github.com/YunYang1994/tensorflow-yolov3 and I followed all the steps for generated the .pb model for inference on coco dataset.


After that, with the ATC model conversion tool I converted the .pb to .om model with the followed command.


atc --model=yolov3_coco_shape.pb --framework=3 --output=yolov3_coco_shape --soc_version=Ascend310 --input_format=NHWC --output_type=FP32 --input_shape="input/input_data:1,416,416,3"


Then, for the inference process with the .om model I used the same pre-process and pos-process functions from the original tensorflow implementation. My script is attached with this message. (inference_yolov3.txt).

The implementation run without errors but the inference results with the .om model is unsatisfied.  


 I noted that the outputs of the model.execute function for the om model has the same dimensions that the original tensorflow implementation, however the arrays values are different. The image above shows an example


Could someone explain to me where is the error??

 

Thanks in advance for your support



om inference Error





Attachment: You need to log in to download or view. No account? Register

All Answers

Hallo @user_4147187


gg


How do I get output_node_names from model arts output?


Thankyou in advance

View more
  • x
  • convention:

Okay
View more
  • x
  • convention:

Hello, after a segmented investigation, we found that there is a problem in the preprocessing part of the model. The input data should be of float32 type. Tf may automatically convert the input data type according to the input data type of the model during model inference, but the om model does not Doing this step according to the input data type of the model resulted in the deviation of the input data and no error was reported. The inference code of the om model we wrote based on the original model pre-processing and post-processing code is modified as shown in the figure, and I hope it can help you:

1


View more
  • x
  • convention:

12
Back to list

Comment

You need to log in to comment to the post Login | Register

Notice: To protect the legitimate rights and interests of you, the community, and third parties, do not release content that may bring legal risks to all parties, including but are not limited to the following:
  • Politically sensitive content
  • Content concerning pornography, gambling, and drug abuse
  • Content that may disclose or infringe upon others ' commercial secrets, intellectual properties, including trade marks, copyrights, and patents, and personal privacy
Do not share your account and password with others. All operations performed using your account will be regarded as your own actions and all consequences arising therefrom will be borne by you. For details, see " User Agreement."

My Followers

Login and enjoy all the member benefits

Login

Block
Are you sure to block this user?
Users on your blacklist cannot comment on your post,cannot mention you, cannot send you private messages.
Reminder
Please bind your phone number to obtain invitation bonus.