Skip to content

Commit

Permalink
feat: override traffic light launcher for gen2 settings (autowarefoun…
Browse files Browse the repository at this point in the history
  • Loading branch information
TomohitoAndo authored Sep 10, 2024
1 parent a245488 commit dcad244
Show file tree
Hide file tree
Showing 2 changed files with 320 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,32 @@
<arg name="data_path" default="$(env HOME)/autoware_data" description="packages data and artifacts directory path"/>
<arg name="lidar_detection_model" default="centerpoint" description="options: `transfusion`, `centerpoint`, `apollo`, `pointpainting`, `clustering`"/>

<!-- In the Gen2 sensor configuration, the traffic_light_recognition node is launched not through the conventional autoware.universe/launch/tier4_perception_launch but with its own custom launch file.
This is because autoware.universe's launch files do not support an arbitrary number of cameras. If autoware.universe's launch files were to support it, it is recommended to use them instead. -->
<include file="$(find-pkg-share autoware_launch)/launch/components/traffic_light_recognition/traffic_light.launch.xml">
<arg name="fusion_only" value="true"/>
<arg name="enable_fine_detection" value="true"/>
<arg name="image_number" value="4"/>
<arg name="input/cloud" value="/sensing/lidar/top/pointcloud_raw"/>
<arg name="internal/traffic_signals" value="/perception/traffic_light_recognition/internal/traffic_signals"/>
<arg name="fusion/traffic_signals" value="/perception/traffic_light_recognition/fusion/traffic_signals"/>
<arg name="external/traffic_signals" value="/perception/traffic_light_recognition/external/traffic_signals"/>
<arg name="output/traffic_signals" value="/perception/traffic_light_recognition/traffic_signals"/>
<arg name="use_crosswalk_traffic_light_estimator" value="true"/>
<arg name="crosswalk_traffic_light_estimator_param_file" value="$(find-pkg-share autoware_crosswalk_traffic_light_estimator)/config/crosswalk_traffic_light_estimator.param.yaml"/>

<arg name="camera_namespaces" value="['camera4', 'camera5', 'camera6', 'camera7']"/>
<arg name="fine_detector_label_path" value="$(var data_path)/traffic_light_fine_detector/tlr_labels.txt"/>
<arg name="fine_detector_model_path" value="$(var data_path)/traffic_light_fine_detector/tlr_yolox_s_batch_6.onnx"/>
<arg name="car_classifier_label_path" value="$(var data_path)/traffic_light_classifier/lamp_labels.txt"/>
<arg name="pedestrian_classifier_label_path" value="$(var data_path)/traffic_light_classifier/lamp_labels_ped.txt"/>
<arg name="car_classifier_model_path" value="$(var data_path)/traffic_light_classifier/traffic_light_classifier_mobilenetv2_batch_6.onnx"/>
<arg name="pedestrian_classifier_model_path" value="$(var data_path)/traffic_light_classifier/ped_traffic_light_classifier_mobilenetv2_batch_6.onnx"/>
</include>

<!-- NOTE: Override by false to disable conventional traffic light recognition launch -->
<let name="use_traffic_light_recognition" value="false"/>

<include file="$(find-pkg-share tier4_perception_launch)/launch/perception.launch.xml">
<arg name="mode" value="$(var perception_mode)"/>
<arg name="vehicle_param_file" value="$(find-pkg-share $(var vehicle_model)_description)/config/vehicle_info.param.yaml"/>
Expand Down Expand Up @@ -178,7 +204,7 @@
<arg name="occupancy_grid_map_updater_param_path" value="$(find-pkg-share autoware_launch)/config/perception/occupancy_grid_map/$(var occupancy_grid_map_updater)_updater.param.yaml"/>

<!-- traffic light recognition -->
<arg name="use_traffic_light_recognition" value="true"/>
<arg name="use_traffic_light_recognition" value="$(var use_traffic_light_recognition)"/>
<arg name="traffic_light_recognition/enable_fine_detection" value="$(var traffic_light_recognition/enable_fine_detection)"/>
<arg name="traffic_light_recognition/fusion_only" value="true"/>
<arg name="traffic_light_image_number" value="1"/>
Expand Down
Loading

0 comments on commit dcad244

Please sign in to comment.