MCZhi / DIPP

[TNNLS] Differentiable Integrated Prediction and Planning Framework for Urban Autonomous Driving
https://mczhi.github.io/DIPP/
223 stars 44 forks source link

Some questions about the map_process #8

Closed yougeyxt closed 2 years ago

yougeyxt commented 2 years ago

Hi authors, thanks for the interesting and well-organized work! I have some questions regarding the map_process function in the data_process.py file:

  1. At line 83, it checks whether the agent_type equals to 2 (i.e., pedestrian), where agent_type defined by agent_type = int(traj[-1][-1]) if type is None else type. For the ego vehicle (i.e., the AV), the agent_type will equal 2 since the last element of traj for AV is vehicle height (which equals 2.33 meters) rather than vehicle type. Is this designed purposely so that the map_process of AV is different from other non-pedestrian (agent_type != 2)? Or should the line 403 be map_lanes[0], map_crosswalks[0] = self.map_process(ego, timestep, type=1)?
  2. At line 187, it scales different lanes to the same length of 100 data elements. Then the lane resolution (i.e., the distance between two elements of different lanes) in the vectorized_map will be different. Could you please provide some intuition about why we need to scale the lane? I have some difficulties understanding this step, please correct me if I misunderstand it.

Thank you!

MCZhi commented 2 years ago

Thanks for your interest in our work. Here are my answers to your questions.

  1. Yes, you are right. I forgot to change line 403 after I modified the map_process method. I will change line 403 to map_lanes[0], map_crosswalks[0] = self.map_process(ego, timestep, type=1). Thank you for pointing it out.
  2. Actually, this step is to ensure that every element in the fixed-size tensor is a valid waypoint. It may change the lane resolution but we think it may not be a big issue. You can fix the lane resolution if you prefer to do so but you may need to pad the zeros values in the network.

Hope my answers are helpful to you!

yougeyxt commented 2 years ago

Thank you for the answers, and they are very helpful!

yougeyxt commented 2 years ago

Hello, a kind reminder that line 31 in the test_utils.py file may also need to be changed to map_lanes[0], map_crosswalks[0] = self.map_process(ego, timestep, type=1). Thanks again for the great work.

MCZhi commented 2 years ago

Thank you for the correction.