未验证 提交 6eed850e 编写于 作者: W Wenyu 提交者: GitHub

update (#3638)

上级 b40f00cb
......@@ -21,10 +21,10 @@ import copy
import paddle
import paddle.nn as nn
import ppdet.modeling.initializer as init
from ppdet.core.workspace import register
from ppdet.modeling.heads.roi_extractor import RoIAlign
from ppdet.modeling.bbox_utils import delta2bbox
from .. import initializer as init
_DEFAULT_SCALE_CLAMP = math.log(100000. / 16)
......@@ -366,6 +366,5 @@ class SparseRCNNHead(nn.Layer):
def box_cxcywh_to_xyxy(x):
x_c, y_c, w, h = x.unbind(-1)
b = [(x_c - 0.5 * w), (y_c - 0.5 * h),
(x_c + 0.5 * w), (y_c + 0.5 * h)]
return paddle.stack(b, axis=-1)
\ No newline at end of file
b = [(x_c - 0.5 * w), (y_c - 0.5 * h), (x_c + 0.5 * w), (y_c + 0.5 * h)]
return paddle.stack(b, axis=-1)
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册