frustum-pointnets 使用ground truth 后性能降低的原因

官方tensorflow代码:https://github.com/charlesq34/frustum-pointnets
欢迎star我的pytorch复现代码:https://github.com/simon3dv/frustum_pointnets_pytorch

问题的发现

用RGB 2d box:car_detection_3d AP AP:85.09, 72.11, 64.25
用gt 2d box:car_detection_3d AP AP:74.14 68.03 62.82
用gt 2d box后,2d AP是 100,100,100,但3d AP大幅下降

原因

在用pascal voc 的方式计算AP中会用到score值,如果score是固定1或者随机的,那么在低recall的情况下也得不到高的precision.因为低recall的时候会拿score最高的那几个预测来计算precision.
然而,f-pointnets 没有输出一个良好的score值.

test.py
用RGB时,score的计算方式: score_list.append(batch_rgb_prob[j]),即用2d检测器的score
用gt时,score的计算方式:

mask_mean_prob = np.sum(batch_seg_prob * batch_seg_mask, 1) # B,
mask_mean_prob = mask_mean_prob / (np.sum(batch_seg_mask, 1))
batch_scores = np.log(mask_mean_prob) + np.log(heading_prob) + np.log(size_prob)
score_list.append(batch_scores[j])

验证

如果RGB也用f-pointnet计算score的方式,那么AP也会严重下降:3D AP: 76.976532 69.313423 63.041763

解决方案

最简单的解决方案是把gt的score计算方式改成

mask_max_prob = np.max(batch_seg_prob * batch_seg_mask, 1)
batch_scores = np.max(mask_max_prob)

得到AP:car_detection_3d AP: 85.082458 74.658356 67.191765
如果rgb也用这种方式计算score,AP是car_detection_3d AP: 81.558723 70.068161 63.369583,仍然比用2d score要差几个点,可见这种方式也不是最好的.
我猜最好的方式还是再训练一个分类分支,比如f-convnet就不会出现这样的问题.

猜你喜欢

转载自www.cnblogs.com/simingfan/p/12398432.html
今日推荐