未验证 提交 8a3376b8 编写于 作者: J JYChen 提交者: GitHub

fix trt inference error in lite_hrnet (#4355)

上级 85218f9a
...@@ -651,7 +651,9 @@ class LiteHRNetModule(nn.Layer): ...@@ -651,7 +651,9 @@ class LiteHRNetModule(nn.Layer):
for i in range(len(self.fuse_layers)): for i in range(len(self.fuse_layers)):
y = out[0] if i == 0 else self.fuse_layers[i][0](out[0]) y = out[0] if i == 0 else self.fuse_layers[i][0](out[0])
for j in range(self.num_branches): for j in range(self.num_branches):
if i == j: if j == 0:
y += y
elif i == j:
y += out[j] y += out[j]
else: else:
y += self.fuse_layers[i][j](out[j]) y += self.fuse_layers[i][j](out[j])
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册