Hi! You can directly use the CARLA PythonAPI to map OpenDrive landmarks with traffic light actors in CARLA.
You can retrieve all the landmarks of type traffic light in the following way:
landmarks = carla_map.get_all_landmarks_of_type('1000001'):
Then, for each landmark, you can get the associated traffic light actor in CARLA:
traffic_light = carla_world.get_traffic_light(landmark)
Normally, traffic lights are defined inside intersections. That means that you will obtain multiple landmarks that refers to the same traffic light (one for each one of the possible directions in the intersection). The method
carla_world.get_traffic_light(landmark) will return the same traffic light actor for all these landmarks.