OpenDriveLab / TCP

[NeurIPS 2022] Trajectory-guided Control Prediction for End-to-end Autonomous Driving: A Simple yet Strong Baseline.
Apache License 2.0
309 stars 40 forks source link

some question about the network #22

Closed crazyleeth closed 1 year ago

crazyleeth commented 1 year ago

thanks for your great work,which taught me a lot however,I am a little confused about couple details about the network,looking for help. 1 You mentioned that you didnt use the last layer of the resnet34 which has 1000 output.but I find it in the code model.py "self.join_traj = nn.Sequential( nn.Linear(128+1000, 512), nn.ReLU(inplace=True), nn.Linear(512, 512), nn.ReLU(inplace=True), nn.Linear(512, 256), nn.ReLU(inplace=True), )" I am not sure about how this 1000 come from

2 it is about the attention map "self.wp_att = nn.Sequential( nn.Linear(256+256, 256), nn.ReLU(inplace=True), nn.Linear(256, 298), nn.Softmax(1) )" I just start study the attention machanism ,would you please show me what 298 represent? looking forward to your reply : )

penghao-wu commented 1 year ago
  1. For the control branch, we do not use the last layer of the resnet34, but we use the last layer for the trajectory branch. You can modify the trajectory branch to discard the last layer to make it more consistent.
  2. The 298 here is hard-coded to represent the size of the feature map (size 8*29) coming from the image backbone.
crazyleeth commented 1 year ago

thank you for your reply!have a nice day~