Commit 1c1de9a5 authored by liyinhao's avatar liyinhao Committed by zhangwenwei
Browse files

Add_bbox_unittest

parent beae2426
...@@ -126,7 +126,6 @@ def points_cam2img(points_3d, proj_mat): ...@@ -126,7 +126,6 @@ def points_cam2img(points_3d, proj_mat):
# previous implementation use new_zeros, new_one yeilds better results # previous implementation use new_zeros, new_one yeilds better results
points_4 = torch.cat( points_4 = torch.cat(
[points_3d, points_3d.new_ones(*points_shape)], dim=-1) [points_3d, points_3d.new_ones(*points_shape)], dim=-1)
# point_2d = points_4 @ tf.transpose(proj_mat, [1, 0])
point_2d = torch.matmul(points_4, proj_mat.t()) point_2d = torch.matmul(points_4, proj_mat.t())
point_2d_res = point_2d[..., :2] / point_2d[..., 2:3] point_2d_res = point_2d[..., :2] / point_2d[..., 2:3]
return point_2d_res return point_2d_res
This diff is collapsed.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment