nuPlan converter

Hi! First of all, thanks a lot for the whole CommonRoad project! It’s super useful for my research and provides large parts of what I would otherwise have had to implement on my own.

I got a question related to the dataset converters. In your latest paper, you mention that you used them to convert from nuPlan to CommonRoad scenarios, and then, ultimately, to the graph dataset. However, there doesn’t seem to be any nuPlan-related code in repo. Is it not published, yet? Would be helpful to have this!

Also, another question to help with my understanding: when extracting CommonRoad scenarios from data, you’ll always have to pass a fixed length / number of frame, correct? There is no “dynamic” segmentation / no way to determine the start- and end points of a (in whatever sense) relevant scenario in a “smart” way, no?

@xiao_wang Could you have a quick look at this, please? :pray:

Regarding nuplan: The publishing of the nuplan converter is on our roadmap, however, it is not ready yet. In the meantime you could use the converted scenarios available here.

Regarding segmentation: We currently support two modes for segmentation: (1) fixed time frame, (2) one scenario per vehicle. A “smart” way is difficult to realize in general, since “smart” is often application-specific. However, the next release of the dataset converter (published within the next month) includes a major refactoring, making use of OOP, which should facilitate customization of the segmentation scheme to the user’s requirements.

Awesome, thanks! I’m really looking forward to this, as it will come in super handy for my own research.

Sorry to bother you guys again, but can you give a rough estimate of when the conversion code will be published? I’m considering implementing it myself, because I’d need precisely that for my research. But I’m hesitant as we would literally do the exact same piece of work in parallel then.

Hello @fmuetsch, have you implemented the converter by yourself at the end? Because it would be super helpful for my research as well!
Moreover, I am not quite sure whether using nuPlan or nuScenes, do you think would be also possible to use nuScenes and convert it in some way?
I would like to measure the safety based on their metrics using CommonRoad-CriMe, I think it would be really helpful.
Or maybe you think that it would be just possible to modify CommonRoad-CriMe codebase and adapt it to nuScenes data format?

Do you have any news about it?
Do you think adapting your CommonRoad-CriMe code to nuPlan/nuScenes would be possible or it would be too much ?

Hi @samuele99. We’ve implemented a very rudimentary conversion from nuPlan map + scenarios to CommonRoad (with one indirection via another custom format that we’re using internally). But it’s not comprehensive (only some layers of the map are covered) and contains quite a lot of ugly hacks here and there, which is why I wouldn’t feel comfortable sharing the code.

My preferred option would still be the CommonRoad team to release their tooling!

Regarding nuScenes: I’ve never worked with nuScenes, but in my undestanding, their map format is entirely different from nuPlan’s (just a single PNG image?). There is [1] to convert nuScenes maps into Lanelet2 format, from where you could - in theory - use the crdesigner tool to convert to CommonRoad. Converting the scenarios themselves should be quite straightforward as well, but, again, no experience with nuScenes so far.

Your research does actually sound quite familiar to ours. We’re also looking into CriMe to compute criticality of scenarios (over time) for different purposes. Perhaps lets connect and share our goals?

@samuele99 @fmuetsch
FYI: We plant to have a student group finalizing the nuplan converter in the upcoming semester.
A concrete release date depends on the progress of the students.

1 Like