hatem-darweesh / autoware.ai.openplanner

The workspace for directly downloading and installing Autoware.AI versions with the latest OpenPlanner 2.5 updates
Apache License 2.0
39 stars 7 forks source link

Some questions about 'curb' in openplanner-2.5 #5

Open quliang93 opened 2 years ago

quliang93 commented 2 years ago

Hi, guys, I'm here again. This time, I met some questions about curb in openplanner-2.5. I enabled the "detect curb" in Autoware-Runtime-Manager in op_local_motion panal. By the way, I also added curb in my own hd map. But when I run the codes, The vehicle still hit the curb. I also checked this problem in moriyama, which is the official demo hd map provided by Autoware team. But after open detection of curb, I added the ros-topic "map_curbs_rviz", which showed nothing.

Is there anything I missed? Maybe someone could give some advice? Thans a lot!

quliang93 commented 2 years ago

Hi, guys. I think I've find some problems about curb detection. Here is what I did. In src/autoware/common/op_planner/include/op_planner/VectorMapLoader.h. In line 24, I changed the line from bool 'load_curb = false' to 'load_curb = true'. Complile the whole project.

Also, make sure you have drawed the curb with the correct maptool box. And in curb.csv, it looks like: ID,LID,Height,Width,Dir,LinkID 1,1,2,2,1,1 2,2,2,2,1,1 3,3,2,2,1,1

And after doing this, when I open the 'op_global_planner', I can see the blue curb. And when you enable the 'curb_deteciton' in op_local_planner in motion_predictor, you can see how the curb influence the cost of each trajectory which is near by them.

Hope it's useful for you!

aforlano commented 2 years ago

This is exactly what I needed, thank you ! How did you come across this solution ?

aforlano commented 2 years ago

seams like that the wayarea2grid node is not working with the modified map.

When loading the modified exported map with the _vector_maploader node I get the following output:

terminal_error_output

hence the wayarea2grid node is not working then I think . . . Any idea why @quliang93 & @hatem-darweesh ?

quliang93 commented 2 years ago

Hi, aforlano I didn't use the node wayarea2grid (sorry about that). But I think both wayarea and curb detection do the same work. They both limit the trajectory, avoiding some staic obstacles. Wayarea is very important when I launch the A*star navigation. But in OpenPlanner, I think it's good to use curb detection. Here is what we do with OpenPlanner-1.15: https://www.bilibili.com/video/BV1G54y1Z7R4/?vd_source=3df1b632533eb0297de289c0cdc73c1a

Good Luck!

aforlano commented 2 years ago

Thank you @quliang93 for the information and the nice video :)

yes the generated wayarea (occupancy grid) can then be used to filter obstacles outside this area e.g. people walking on the sidewalk. The local planning is then much more stable and smoother.

What I then came across when implementing your approach with the integration of curb data was that the wayarea could no longer be generated. I have also described this problem here: https://github.com/autowarefoundation/autoware_ai_planning/issues/56 .

For further testing In the meantime I switched to Lanelet2 maps and integrated there curb data there using the JOSM-Editor with the Lanelet2 plugin, but the big problem is now that the open planner won't detect curbs there do you know why ?

momala commented 2 years ago

Hi, aforlano I didn't use the node wayarea2grid (sorry about that). But I think both wayarea and curb detection do the same work. They both limit the trajectory, avoiding some staic obstacles. Wayarea is very important when I launch the A*star navigation. But in OpenPlanner, I think it's good to use curb detection. Here is what we do with OpenPlanner-1.15: https://www.bilibili.com/video/BV1G54y1Z7R4/?vd_source=3df1b632533eb0297de289c0cdc73c1a

Good Luck!

Thank you @quliang93 for sharing your work with us. I wonder if you have tested the KML map also? I tried to add curbs to the Town_1 with the assuremappingtools. Then, I can see the blue line that appears as curbs in Rviz but the algorithm does not recognize them and the car hits the curb. I appreciate it if you have any useful information to share with us.

aforlano commented 2 years ago

@momala Hey momola! Are you using the op_local_planner with LaneLet2 maps and your curbs get detected ?

Because from my side I still can't get the op_local_planner to detect the curbs I added into my Lanelet2 map it only works with the vector map format (aisian)

I was thinking if the curb detection from op_local_planner can only working with vector (aisian) -map format

momala commented 2 years ago

@momala Hey momola! Are you using the op_local_planner with LaneLet2 maps and your curbs get detected ?

Because from my side I still can't get the op_local_planner to detect the curbs I added into my Lanelet2 map it only works with the vector map format (aisian)

I was thinking if the curb detection from op_local_planner can only working with vector (aisian) -map format

Hi @aforlano, Actually I am trying to find a clue for solving this issue. I am using KML maps. I am not sure if the problem is from the mapping editor software or the open planner alg. Inside the assuremappingtools, you can add curb lines to your map. you should indicate Curb ID, Road ID, Lane ID, Height, and Width. I don't have any idea what should be the value for each curb, but by default, I set the adjacent road and lane ID to the curb and set 2 for height and width(without any idea). However, I should mention I figured out once at the beginning before the vehicle moves some points were published inside "/map_curbs_rviz" but again after the vehicle moved they disappeared. Now I am trying to check the open planner package to find out what issues may cause this problem. I'll keep you posted on the process. I think it should work and just need some tweaking.

aforlano commented 2 years ago

Hello @momala, could you make some progress regarding this issue ?

momala commented 2 years ago

Hello @momala, could you make some progress regarding this issue ?

Hi @aforlano , Actually I found the problem. and it was from the way that I drew my curbs. as I told you I am using KML maps with assuremappingtools. previously I drew a straight line for each side of the road which is defined by two points. I figured out that the algorithms consider the curbs as an object while the vehicle gets closer to these points. so, before, I started my vehicle in the middle of the road which has at least a distance of 60 meters to the points that define the curbs. probably they were far. what I did to solve the issue was add more points to the line. So for instance, every 10 meters, I put a point to define the curbs. this solved my issue and now it detects curbs as obstacles. Hope I could explain it clearly.

aforlano commented 2 years ago

Hello @momala, sorry for the late reply. Thank you for the information and you are totally right. I was able to recreate the workflow with KML files, but it's actually not working for Lanelet2 maps. What I saw is that the export of the assure mapping tool doesn't contain the inserted curb data. So it seams that the Tool is currently not able to generate curb data for LL2. Maybe @hatem-darweesh knows something about this and it is a know Limitation??

hatem-darweesh commented 2 years ago

@aforlano @momala Unfortunately assure mapping tool doesn't export curb information. It is part of the tool development plan but I was too busy the last year. I will have to work on it to support lanelet2 for autoware.universe. Stay tuned.