User Data Directory
The CPM Lab keeps everything you create outside the installation, in one directory, so the layout is the same for Debian packages, Docker images and source builds:
~/cpm_lab/
├── experiments/ # recordings of the experiment recorder, with the evaluations of cpm_eval
├── calibrations/ # results of cpm_calibrate
├── ips/ # your IPS configurations (*.yaml)
└── maps/ # your Lanelet2 maps (*.osm)
Set CPM_LAB_HOME to use another directory, e.g. a data disk. All tools then use $CPM_LAB_HOME/experiments,
$CPM_LAB_HOME/calibrations, $CPM_LAB_HOME/ips and $CPM_LAB_HOME/maps. Explicit options take precedence:
the recorder parameter output_root, cpm_eval --root and cpm_calibrate --output-root. The directories are
created on first use; ips/ and maps/ you create yourself.
In Docker, the helper scripts mount this directory from the host, so its content survives the container:
the workspace’s Docker setup (
make ..., VS Code dev container) mounts~/cpm_labat/home/cpm/cpm_lab,the desktop image mounts
~/cpm_lab(or$CPM_LAB_HOME) at/root/cpm_lab,the simulation image mounts it at
/cpm_laband setsCPM_LAB_HOME=/cpm_lab.
Your Own Maps and IPS Configurations
The control flow offers the maps of the package cpm_lab_maps and the IPS configurations of the package
cpm_lab_indoor_positioning_system together with the files in ~/cpm_lab/maps/ and ~/cpm_lab/ips/. A lab can
therefore use its own map and calibration with the Debian packages or a Docker image, without rebuilding anything:
mkdir -p ~/cpm_lab/maps ~/cpm_lab/ips
cp mylab.osm ~/cpm_lab/maps/
cp mylab.yaml ~/cpm_lab/ips/
Restart the lab; the Control Center then lists mylab.osm and mylab.yaml. A file with the same name as a
packaged one replaces it, e.g. ~/cpm_lab/ips/munich2.yaml. The control flow runs as the user who started the lab,
so the files must be in that user’s ~/cpm_lab (or $CPM_LAB_HOME) on the computer that runs the control flow.
The map selection of the Control Center with mylab.osm from ~/cpm_lab/maps next to the packaged maps
A map needs the
originnode and follows the rules in Lanelet2 Maps.An IPS configuration is a complete parameter file, not only the output of
cpm_calibrate, see IPS Camera Calibration.
Started by hand, the map server and the IPS take absolute paths as well:
ros2 run cpm_lab_map_server cpm_lab_map_server_node --ros-args -r __ns:=/lab -p map_path:=$HOME/cpm_lab/maps/mylab.osm
ros2 launch cpm_lab_indoor_positioning_system default.launch.xml config_file:=$HOME/cpm_lab/ips/mylab.yaml
Maps and configurations that are useful for all labs belong into the packages; open a merge request, see Development Workflow.