linghu8812 / tensorrt_inference

702 stars 206 forks source link

ONNX conversion warning [CAN'T RECORD THE DATA FLOW OF PYTHON VALUES] #23

Open bobbilichandu opened 3 years ago

bobbilichandu commented 3 years ago

Converting a tensor to a Python boolean might cause the trace to be incorrect. We can't record the data flow of Python values, so this value will be treated as a constant in the future. This means that the trace might not generalize to other inputs! if self.grid[i].shape[2:4] != x[i].shape[2:4]:

facing this issue every time I try to convert model to onnx. Can this be ignored?

linghu8812 commented 3 years ago

please try to use https://github.com/linghu8812/ScaledYOLOv4 to export ONNX model, the yolo.py file is different.

bobbilichandu commented 3 years ago

Used the same[cloned the modified repository by you], but still facing the same issue. Will it affect the trt performance?

linghu8812 commented 3 years ago

this may caused by these lines: https://github.com/linghu8812/ScaledYOLOv4/blob/b584a70b27a75e01ab5710b7743ca325f81aa443/models/yolo.py#L46-L47

pepijnko commented 3 years ago

@chandu1263 did it have an impect on the trt performance ?

bobbilichandu commented 3 years ago

Nope. You can ignore that actually.