未验证 提交 05c71b5f 编写于 作者: Y Yang Zhang 提交者: GitHub

Work around broadcast issue in iou_aware (#690) (#707)

上级 d32c426a
...@@ -35,7 +35,9 @@ def _split_ioup(output, an_num, num_classes): ...@@ -35,7 +35,9 @@ def _split_ioup(output, an_num, num_classes):
def _de_sigmoid(x, eps=1e-7): def _de_sigmoid(x, eps=1e-7):
x = fluid.layers.clip(x, eps, 1 / eps) x = fluid.layers.clip(x, eps, 1 / eps)
x = fluid.layers.clip((1 / x - 1.0), eps, 1 / eps) one = fluid.layers.fill_constant(
shape=[1, 1, 1, 1], dtype=x.dtype, value=1.)
x = fluid.layers.clip((one / x - 1.0), eps, 1 / eps)
x = -fluid.layers.log(x) x = -fluid.layers.log(x)
return x return x
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册