Skip to content

Commit

Permalink
chore(ar_tag_based_localizer): add json schema (autowarefoundation#6164)
Browse files Browse the repository at this point in the history
* Added json schema to AR tag-based localizer

Signed-off-by: Shintaro SAKODA <[email protected]>

* style(pre-commit): autofix

---------

Signed-off-by: Shintaro SAKODA <[email protected]>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
  • Loading branch information
2 people authored and karishma1911 committed Jun 3, 2024
1 parent d7eafc2 commit 260be59
Show file tree
Hide file tree
Showing 2 changed files with 92 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

**ArTagBasedLocalizer** is a vision-based localization node.

<img src="./doc_image/ar_tag_image.png" width="320px">
<img src="./doc_image/ar_tag_image.png" width="320px" alt="ar_tag_image">

This node uses [the ArUco library](https://index.ros.org/p/aruco/) to detect AR-Tags from camera images and calculates and publishes the pose of the ego vehicle based on these detections.
The positions and orientations of the AR-Tags are assumed to be written in the Lanelet2 format.
Expand Down Expand Up @@ -30,6 +30,10 @@ The positions and orientations of the AR-Tags are assumed to be written in the L
| `/tf` | `geometry_msgs::msg::TransformStamped` | [debug topic] TF from camera to detected tag |
| `/diagnostics` | `diagnostic_msgs::msg::DiagnosticArray` | Diagnostics outputs |

## Parameters

{{ json_to_markdown("localization/landmark_based_localizer/ar_tag_based_localizer/schema/ar_tag_based_localizer.schema.json") }}

## How to launch

When launching Autoware, set `artag` for `pose_source`.
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "Parameters for ar_tag_based_localizer",
"type": "object",
"definitions": {
"ar_tag_based_localizer": {
"type": "object",
"properties": {
"marker_size": {
"type": "number",
"description": "marker_size",
"default": 0.6
},
"target_tag_ids": {
"type": "array",
"description": "target_tag_ids",
"default": "['0','1','2','3','4','5','6']"
},
"base_covariance": {
"type": "array",
"description": "base_covariance",
"default": [
0.2, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.2, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.2, 0.0, 0.0,
0.0, 0.0, 0.0, 0.0, 0.02, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.02, 0.0, 0.0, 0.0, 0.0, 0.0,
0.0, 0.02
]
},
"distance_threshold": {
"type": "number",
"description": "distance_threshold(m)",
"default": "13.0"
},
"consider_orientation": {
"type": "boolean",
"description": "consider_orientation",
"default": "false"
},
"detection_mode": {
"type": "string",
"description": "detection_mode select from [DM_NORMAL, DM_FAST, DM_VIDEO_FAST]",
"default": "DM_NORMAL"
},
"min_marker_size": {
"type": "number",
"description": "min_marker_size",
"default": 0.02
},
"ekf_time_tolerance": {
"type": "number",
"description": "ekf_time_tolerance(sec)",
"default": 5.0
},
"ekf_position_tolerance": {
"type": "number",
"description": "ekf_position_tolerance(m)",
"default": 10.0
}
},
"required": [
"marker_size",
"target_tag_ids",
"base_covariance",
"distance_threshold",
"consider_orientation",
"detection_mode",
"min_marker_size",
"ekf_time_tolerance",
"ekf_position_tolerance"
],
"additionalProperties": false
}
},
"properties": {
"/**": {
"type": "object",
"properties": {
"ros__parameters": {
"$ref": "#/definitions/ar_tag_based_localizer"
}
},
"required": ["ros__parameters"],
"additionalProperties": false
}
},
"required": ["/**"],
"additionalProperties": false
}

0 comments on commit 260be59

Please sign in to comment.