Skip to content
Merged
Show file tree
Hide file tree
Changes from 28 commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
8729f85
feat: add inline autoware_launch parameter refiner script and documen…
technolojin Apr 16, 2026
6cea012
feat: enhance ROS 2 topology report functionality
technolojin Apr 16, 2026
f44d553
feat: add README for topology-analyzer tool
technolojin Apr 16, 2026
f86658d
feat: enhance topology analyzer with composable node container support
technolojin Apr 16, 2026
8261b74
feat: add process discovery features to topology analyzer
technolojin Apr 16, 2026
708358e
feat: implement process grouping and diffing in topology report
technolojin Apr 16, 2026
0e43505
feat: enhance topology matching algorithm and signature handling
technolojin Apr 16, 2026
02de31f
feat: enhance node matching algorithm for same-type compositions
technolojin Apr 16, 2026
8b7c49c
feat: refactor topology analyzer with modular structure and enhanced …
technolojin Apr 17, 2026
555a59e
feat: modularize ros2_graph_snapshot with new component detection and…
technolojin Apr 17, 2026
aa0e879
feat: introduce auto-system-config-generator for generating Autoware …
technolojin Apr 17, 2026
66757e9
fix: update README and enhance connection resolution logic
technolojin Apr 17, 2026
22adb85
refactor: enhance connection resolution and introduce namespace tree …
technolojin Apr 17, 2026
2f54419
feat: add graph JSON support for enhanced node remapping
technolojin Apr 17, 2026
b574a66
feat: add node configuration generation for undeclared ROS 2 nodes
technolojin Apr 17, 2026
ec41270
feat: enhance node configuration generation with namespace support
technolojin Apr 17, 2026
9822050
feat: introduce launch unifier for ROS 2 launch file processing
technolojin Apr 20, 2026
b8adcbf
feat: add support for extra arguments in composable nodes
technolojin Apr 20, 2026
8b23c33
feat: enhance system configuration generation with unified pipeline a…
technolojin Apr 20, 2026
9cd58f6
refactor: streamline output directory structure and enhance error mes…
technolojin Apr 20, 2026
913193d
refactor: update command-line arguments and output structure for syst…
technolojin Apr 20, 2026
5c484de
feat: implement auto-system-config-generator with unified pipeline fo…
technolojin Apr 20, 2026
c71411c
fix: correct namespace handling in Jinja2 template for composable nod…
technolojin Apr 20, 2026
220c690
enhance namespace handling in configuration generation
technolojin Apr 20, 2026
3b8275e
refactor: improve entity handling and shutdown logic in launch unifier
technolojin Apr 20, 2026
1ce874e
update README.md for improved clarity and formatting
technolojin Apr 20, 2026
81e6490
refactor: streamline code formatting and improve readability in param…
technolojin Apr 20, 2026
09b725e
feat: add port name shortening functionality to connection resolver a…
technolojin Apr 21, 2026
facb006
Update tools/system-config-generator/README.md
technolojin Apr 21, 2026
fda3812
Update tools/topology-analyzer/README.md
technolojin Apr 21, 2026
5e993fa
fix: update README.md and improve XML file naming in system config ge…
technolojin Apr 21, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
95 changes: 95 additions & 0 deletions tools/parameter-set-refiner/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
# parameter-set-refiner

A tool to remove `autoware_launch` config file dependencies from
`*.parameter_set.yaml` files by inlining only the parameter values that
actually differ from each package's own defaults.

## Background

`*.parameter_set.yaml` files in the autoware system designer framework can
reference config files from `autoware_launch` via `param_files` entries:

```yaml
- node: /perception/object_recognition/detection/centerpoint/validation
param_files:
- obstacle_pointcloud_based_validator_param_path: >-
$(find-pkg-share autoware_launch)/config/perception/.../obstacle_pointcloud_based_validator.param.yaml
param_values: []
```

This creates a hard dependency on `autoware_launch` at design time. The
refiner resolves each such reference, compares the `autoware_launch` override
against the package's own default config, and rewrites the entry so only the
differing values are kept as inline `param_values`:

```yaml
- node: /perception/object_recognition/detection/centerpoint/validation
param_files: []
param_values:
- name: using_2d_validator
value: true
```

If the two files are identical, the reference is removed with no `param_values`
added.

## Usage

```bash
python3 inline_autoware_launch_params.py <parameter_set.yaml> [OPTIONS]
```

### Options

| Option | Description |
| --------------------- | ---------------------------------------------------------------------------------- |
| `--workspace-src DIR` | Root of the colcon `src/` tree. Auto-detected from the input file path if omitted. |
| `--dry-run` | Print what would change without writing the file. |
| `--output FILE` | Write the result to `FILE` instead of modifying in place. |

### Example

```bash
python3 inline_autoware_launch_params.py /path/to/autoware/src/launcher/autoware_launch/autoware_sample_designs/design/parameter_set/sample_system_perception.parameter_set.yaml --workspace-src /path/to/autoware/src
```

## How it works

For each `param_files` entry referencing `$(find-pkg-share autoware_launch)/...`:

1. **Resolve the autoware_launch config** — maps the `$(find-pkg-share ...)` substitution to an actual file path in the workspace.

2. **Find the matching `*.node.yaml`** — searches the workspace for node definitions that declare the same `param_file` key. When multiple candidates exist (e.g. the generic `param_path` key appears in many nodes), the best match is selected using this priority:
- Node whose declared default filename matches the autoware_launch config filename (exact match).
- Node whose package contains `config/<autoware_launch_config_filename>`.
- Node whose package name best matches the directory path of the autoware_launch config (path-segment scoring).

3. **Resolve the package default config** — locates the baseline config file to compare against. Prefers `<pkg>/config/<autoware_launch_config_filename>` (exact filename match) over the filename declared in `node.yaml`, to handle cases where a node.yaml's declared default points to a sibling config for a different mode.

4. **Diff recursively** — compares the autoware_launch config against the package default using a recursive, leaf-level diff. Only the parameters that actually differ are recorded, using dotted-path names (e.g. `association.can_assign.unknown`) so that identical sibling fields are not written.

5. **Rewrite the entry** — appends the differing values to `param_values` (skipping any already set), then removes the `autoware_launch` reference from `param_files`. Non-autoware_launch `param_files` entries are preserved unchanged.

### Output format

- Scalars: `value: true` / `value: 0.5`
- Arrays: inline flow style `value: [0.098, 0.147, 0.078]`
- Nested dicts: block mapping under the dotted-path name, e.g.:

```yaml
- name: association.can_assign.unknown
value:
[polygon_tracker, multi_vehicle_tracker, pedestrian_and_bicycle_tracker]
```

## Requirements

```text
ruamel.yaml
```

Install with:

```bash
pip install ruamel.yaml
```
Loading
Loading