Skip to content

发现一个bug #13

@feichaiyu

Description

@feichaiyu

这里的top取值不应该是 top = row_ind+j*length 。这会导致在i=1时,在outs 取出的值无法放到outputs中正确的位置。
我的代码中改为 top = row_ind*self.anchor_num+j*length 是有效的。

top = row_ind+j*length
left = 4*j
outputs[top:top + length, 0:2] = (outs[row_ind:row_ind + length, left:left+2] * 2. - 0.5 + grid) * int(self.stride[i])
outputs[top:top + length, 2:4] = (outs[row_ind:row_ind + length, left+2:left+4] * 2) ** 2 * np.repeat(self.anchors[i, j, :].reshape(1,-1), h * w, axis=0)
outputs[top:top + length, 4] = outs[row_ind:row_ind + length, 4*self.anchor_num+j]
outputs[top:top + length, 5:] = outs[row_ind:row_ind + length, 5*self.anchor_num:]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions