class_docstr: This class provides a very high level route plan.
class_docstr_tok: ["This","class","provides","a","very","high","level","route","plan","."]
docstr: This function finds the road segment that a given location
  is part of, returning the edge it belongs to
docstr_tok: ["This","function","finds","the","road","segment","that","a","given","location","is","part","of",",","returning","the","edge","it","belongs","to"]
code: def _localize(self, location):
      """
      This function finds the road segment that a given location
      is part of, returning the edge it belongs to
      """
      waypoint = self._wmap.get_waypoint(location)
      edge = None
      try:
          edge = self._road_id_to_edge[waypoint.road_id][
              waypoint.section_id
          ][waypoint.lane_id]
      except KeyError:
          pass
      return edge
  
file_path: carla/PythonAPI/carla/agents/navigation/global_route_planner.py
imports: import math
  import numpy
  import networkx
  import carla
  from agents.navigation.local_planner import RoadOption
  from agents.tools.misc import vector
label_desc: Use image node_id 7 for calling the GlobalRoutePlanner obj's underlying member method code with example usage: obj._localize(location) and returns: edge