-
Notifications
You must be signed in to change notification settings - Fork 639
Open
Description
在文件:https://github.com/fundamentalvision/BEVFormer/blob/master/projects/mmdet3d_plugin/bevformer/modules/encoder.py的第206行
prev_bev = torch.stack( [prev_bev, bev_query], 1).reshape(bs*2, len_bev, -1)
此句代码stack时,用了dim=1,这样stack第一个维度是batch size,所以对于同一条数据,它的pre和cur在一起。即: [pre_bev, bev_query]
下游文件:https://github.com/fundamentalvision/BEVFormer/blob/master/projects/mmdet3d_plugin/bevformer/modules/temporal_self_attention.py的197行:
在拼接query时,使用了上述信息,
query = torch.cat([value[:bs], query], -1)
此时用value[:bs]取数据时貌似不是特别对吧? 例如,若bs=2时,value[:bs]取到的就是同一条数据的[pre_bev, bev_query],但应该取的是不同数据的pre_bev。
请确认是否有此问题?
Metadata
Metadata
Assignees
Labels
No labels