ultralytics 8.3.14 update TensorRT dynamic inference (#16953)
Co-authored-by: Glenn Jocher <glenn.jocher@ultralytics.com>
This commit is contained in:
parent
75b6733678
commit
03a1f58e03
3 changed files with 2 additions and 3 deletions
|
|
@ -501,7 +501,7 @@ class AutoBackend(nn.Module):
|
|||
|
||||
# TensorRT
|
||||
elif self.engine:
|
||||
if self.dynamic or im.shape != self.bindings["images"].shape:
|
||||
if self.dynamic and im.shape != self.bindings["images"].shape:
|
||||
if self.is_trt10:
|
||||
self.context.set_input_shape("images", im.shape)
|
||||
self.bindings["images"] = self.bindings["images"]._replace(shape=im.shape)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue