28 CHECK_NOTNULL(obstacle_ptr);
32 int id = obstacle_ptr->
id();
34 AERROR <<
"Obstacle [" <<
id <<
"] has no latest feature.";
39 CHECK_NOTNULL(latest_feature_ptr);
40 if (!latest_feature_ptr->has_lane() ||
41 !latest_feature_ptr->
lane().has_lane_graph() ||
42 !latest_feature_ptr->
lane().has_lane_feature()) {
43 ADEBUG <<
"Obstacle [" <<
id <<
"] has no lane graph.";
48 latest_feature_ptr->mutable_lane()->mutable_lane_graph();
49 CHECK_NOTNULL(lane_graph_ptr);
51 AERROR <<
"Obstacle [" <<
id <<
"] has no lane sequences.";
55 std::string curr_lane_id =
56 latest_feature_ptr->
lane().lane_feature().lane_id();
58 for (
auto& lane_sequence : *lane_graph_ptr->mutable_lane_sequence()) {
59 const double probability = ComputeProbability(curr_lane_id, lane_sequence);
60 lane_sequence.set_probability(probability);