Skip to content

Commit

Permalink
refactor: rework parameters for roi_pointcloud_fusion
Browse files Browse the repository at this point in the history
Signed-off-by: ktro2828 <[email protected]>
  • Loading branch information
ktro2828 committed Sep 28, 2023
1 parent 16faca8 commit 130791e
Show file tree
Hide file tree
Showing 3 changed files with 48 additions and 6 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
/**:
ros__parameters:
fuse_unknown_only: true
min_cluster_size: 2
cluster_2d_tolerance: 0.5
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
<launch>
<arg name="input/rois_number" default="6"/>
<arg name="cluster_2d_tolerance" default="0.5"/>
<arg name="min_cluster_size" default="2"/>
<arg name="fuse_unknown_only" default="true"/>
<arg name="input/rois0" default="rois0"/>
<arg name="input/camera_info0" default="/camera_info0"/>
<arg name="input/rois1" default="rois1"/>
Expand All @@ -23,6 +20,7 @@
<arg name="output/pointcloud" default="roi_pointcloud_fusion/output/pointcloud"/>
<arg name="output_clusters" default="output_clusters"/>
<arg name="debug/clusters" default="roi_pointcloud_fusion/debug/clusters"/>
<arg name="param_path" default="$(find-pkg-share image_projection_based_fusion)/config/roi_pointcloud_fusion.param.yaml"/>
<arg name="sync_param_path" default="$(find-pkg-share image_projection_based_fusion)/config/roi_sync.param.yaml"/>

<!-- for eval variable-->
Expand All @@ -38,9 +36,7 @@
<group>
<node pkg="image_projection_based_fusion" exec="roi_pointcloud_fusion_node" name="roi_pointcloud_fusion" output="screen">
<param name="rois_number" value="$(var input/rois_number)"/>
<param name="cluster_2d_tolerance" value="$(var cluster_2d_tolerance)"/>
<param name="min_cluster_size" value="$(var min_cluster_size)"/>
<param name="fuse_unknown_only" value="$(var fuse_unknown_only)"/>
<param from="(var param_path)"/>
<param from="$(var sync_param_path)"/>
<remap from="input" to="$(var input/pointcloud)"/>
<remap from="output" to="$(var output/pointcloud)"/>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "Parameters for RoI PointCloud Fusion Node",
"type": "object",
"definitions": {
"roi_pointcloud_fusion": {
"type": "object",
"properties": {
"fuse_unknown_only": {
"type": "boolean",
"description": "Whether to fuse only UNKNOWN clusters.",
"default": true
},
"min_cluster_size": {
"type": "integer",
"description": "The minimum number of points that a cluster must contain to be considered as valid.",
"default": 2
},
"cluster_2d_tolerance": {
"type": "number",
"description": "A cluster tolerance measured in radial direction [m]",
"default": 0.5,
"exclusiveMinimum": 0.0
}
},
"required": ["fuse_unknown_only", "min_cluster_size", "cluster_2d_tolerance"]
}
},
"properties": {
"/**": {
"type": "object",
"properties": {
"ros__parameters": {
"$ref": "#/definitions/roi_pointcloud_fusion"
}
},
"required": ["ros__parameters"]
}
},
"required": ["/**"]
}

0 comments on commit 130791e

Please sign in to comment.