motional / nuplan-devkit

The devkit of the nuPlan dataset.
https://www.nuplan.org
Other
662 stars 126 forks source link

How can I get "mission goal" during simulation? #289

Closed yaqlee closed 1 year ago

yaqlee commented 1 year ago

I wrote a function in agents_feature_builder to get mission goal during simulation, like this:

def get_features_from_simulation(self, current_input: PlannerInput, initialization: PlannerInitialization)

goal_ego_state = initialization.mission_goal

goal_x = goal_ego_state.x

But I was encountered with log " 'NoneType' has no attribute 'x' ", so how can I get "mission goal" during simulation?

patk-motional commented 1 year ago

Hi @yaqlee,

Some scenarios have missing mission goals. You need to set scenario_filter.remove_invalid_goals=true. Hope that helps.