About loss
See original GitHub issue您好,我直接用中文说可能解释的比较清楚。关于loss 的问题
pred = torch.add(torch.bmm(model_points, base), points + pred_t)
在看了 #7 后我也没有很理解您的意思,这个RGBD得出的point不是绝对坐标么?他和gt的model_points不在一个坐标系下么,那么这样相加的几何意义是什么,我没太理解。
另外关于per-pixel的意义,其实在计算时也只是简单的在pixel上对每个点进行重复,如
model_points = model_points.view(bs, 1, num_point_mesh, 3).repeat(1, num_p, 1, 1).view(bs * num_p, num_point_mesh, 3) target = target.view(bs, 1, num_point_mesh, 3).repeat(1, num_p, 1, 1).view(bs * num_p, num_point_mesh, 3)
这样对于计算有什么帮助呢?
谢谢,期待您的回复!
I was asking what’s the meaning of this line of code pred = torch.add(torch.bmm(model_points, base), points + pred_t)
. In addition, I also didn’t understand these lines of code model_points = model_points.view(bs, 1, num_point_mesh, 3).repeat(1, num_p, 1, 1).view(bs * num_p, num_point_mesh, 3) target = target.view(bs, 1, num_point_mesh, 3).repeat(1, num_p, 1, 1).view(bs * num_p, num_point_mesh, 3)
.
Issue Analytics
- State:
- Created 4 years ago
- Comments:6 (3 by maintainers)
Top GitHub Comments
Because R^{-1} = R^T and (R^T * pt)^T = (pt^T * R). Here we are doing (pt^T * R). The
points
in our code is pt^T which is a (N * 3) matrix.Hi, yes,
points+pred_t
is the absolute trans andpred_t
is an offset translation based the location of the selected input point. Since our model is outputtingpred_t
, when we calculate the loss of the translation estimation, we need to add the point locationpoints
to it. This is why we dopred = torch.add(torch.bmm(model_points, base), points + pred_t)
.I think you miss understand the meaning of
model_points
. This is the pointcloud of the object mesh model which later used for loss calculation by rotating and translating with our predicted 6D pose. The repeating action is to expand the vector to the same size of our pose prediction so that we later can do calculation easily.target
is also the pointcloud of object mesh model but is transferred by the GT 6D pose.It would be better to use English to ask the issue so that ppl can know what we are discussing. Thank you.