Install and Run Without Docker
The Safety Core ships as Debian packages and as a container image. The image is built from the same packages. Install the runtime package on every host that runs the launcher, a decision maker or a command receiver, even when the rest of the Safety Core runs in the container. Install the development package where you build your own decision maker or event source.
Packages
None of the packages declares a dependency, so dpkg does not install the libraries the binaries
need. Install them yourself; see Runtime libraries.
Download
The packages are NGC resources. Each package is one version of the resource
nvidia/halos-outside-in/outside-in-safety, named by the release, the platform, the build and the
package name.
psf-tegra-fsi is
nvidia/halos-outside-in/outside-in-safety:nv-psf-halos-1.4-aarch64-release-6b92731-psf-tegra-fsi,
and needs a separate
sign-up.
Install
On x86-64:
On IGX Thor:
To cross-compile for IGX Thor on an x86-64 host, extract the packages instead of installing them:
Reinstall, upgrade and remove
-
Same version. Every build of a package carries the same version string.
dpkg -ireplaces the installed files even when the version is unchanged, so a reinstall does install the new build. Confirm it by the file times, not the version: -
Edited configuration is overwritten. The packages mark no configuration files. A reinstall or upgrade replaces
nvpss.conf,sensor_pipelines_config.conf,thresholds.cfgandpcm_monitor.cfgin/opt/nvidia/psf/bin, and the rsyslog rule, with the shipped versions, and empties/var/log/psf/pss.log. Copy your edited files elsewhere first, and keep your own configuration under names the package does not ship (for examplesensor_config.conf, which ships only assensor_config.conf.sample). Learned baselines are not package files and are kept. SAIM refuses its baselines from an earlier release, so learn them again after upgrading; see Baselines. -
Remove.
dpkg --purgeremoves the package files and, for the runtime package, the three socket files in/run/nvpsf. It leaves the/run/nvpsfdirectory.
Install paths
Configuration files in /opt/nvidia/psf/bin:
Runtime libraries
On Ubuntu 24.04:
Ubuntu 22.04’s protobuf package provides libprotobuf.so.23, not libprotobuf.so.32, so it does
not satisfy mdx_client or nv_perception_monitor. The container image is based on
Ubuntu 24.04 and already contains the libraries its platform needs, except the driver’s.
Check that nothing is missing:
Expected result: no output.
PATH and LD_LIBRARY_PATH
The Safety Core executables carry no library search path of their own. The runtime package
registers /opt/nvidia/psf/lib with the dynamic linker through
/etc/ld.so.conf.d/nvidia-psf.conf and runs ldconfig, so after dpkg -i no
LD_LIBRARY_PATH is needed. The binaries are not added to PATH; call them by their full path,
or:
If you extracted the packages with dpkg -x instead of installing them, the linker
configuration is not in place. Set the library path to the extracted tree:
What the runtime package sets up
Kernel socket buffers
The transport sizes the gateway-to-SDM link for 516 decision packets, because a packet the
gateway cannot send burns a sequence number and the SDM latches on the gap. When the gateway and
each SDM open the link, they request receive and send buffers for 516 messages, read back what the
kernel granted, and refuse to continue if it is less. Linux caps the grant at
net.core.rmem_max (receive) and net.core.wmem_max (send), and the stock limits are lower than
the request.
Set both limits on the host that runs these processes. The container uses the host’s network namespace and shares the host’s limits. Do not lower a larger value that is already set.
Files in /etc/sysctl.d/ apply in name order, and a later file overrides an earlier one. The
file names below are chosen against the VSS settings file (99-vss.conf), which sets both limits
to 5242880.
On a host with CCPLEX SDMs only, the file sorts before the VSS file, so a larger VSS value still wins:
On an IGX Thor that runs fsicom-agent, the file sorts after the VSS file, because the agent needs
more than VSS sets:
Check:
What happens when a limit is too low:
The requested size is twice the payload because Linux reports buffer sizes with its own
accounting overhead included. The check is in provisionSocketBuffer() of the transport library.
The transport also honours an environment variable, NVPSF_MIN_QUEUE_DEPTH, that lowers the
516-packet floor for test machines and prints a warning when set. Do not set it in production: a
lower floor re-opens the drop that the floor exists to prevent.
Running without Docker
Every Safety Core process can run directly on the host.
Before you start
- Install the runtime package and the runtime libraries.
- Raise the kernel socket buffers.
- Check that
/run/nvpsfexists with mode1777(ls -ld /run/nvpsf). The package creates it at every boot. Without the package, create it after every boot, because/runis cleared:sudo mkdir -p /run/nvpsf && sudo chmod 1777 /run/nvpsf. - Create
/opt/nvidia/psf/bin/sensor_config.conffromsensor_config.conf.sample, or pointsensorConfiginnvpss.confat your file. The daemon reads the file named bysensorConfig, not the one you pass to the launcher or tomdx_client, so all three must name the same file. - Check
sensor_pipelines_config.confagainst your cameras (2D) or your BEV group (3D). - Copy the SDM configuration from its
.sampleand edit it. - For SAIM in active mode, make sure
/opt/nvidia/psf/bin/saim_baselineholds a baseline for every camera, learned (<camera>_baseline.cfg) or shipped (<camera>_baseline.cfg.default). - For PCM in active mode, make sure
/opt/nvidia/psf/bin/pcm_baselineholds a baseline learned with the same event mapping and SDM configurations as the active run (see Learning by hand), and that/opt/nvidia/psf/bin/pcm_monitor.cfglists the perception containers of this host.
With the launcher
launch_hoisa.sh --runtime host starts every process on the host, in the right order. It runs
them as root through sudo -n, so they all have the same primary group; run it as root or with
passwordless sudo.
To learn the baselines first, run the same command with --saim-mode learn --pcm-mode learn and
without the two --cmd-rx options. Every option is on
Launcher. The launcher does not start the command
receiver; start it first, as in step 4 below.
By hand
Start the processes in this order. The constraints that force it are:
These steps start the forklift safety function (ATL) in 2D. Run steps 1 to 3 and 5 to 8 in one root
shell (sudo -i), so that every Safety Core process runs as root with the same primary group (see
Shared process group). Run step 4 in its own terminal,
because the receiver reads release commands from its standard input; the receiver does not use the
AF_UNIX links, so it can run as any user.
-
Prepare the log files:
-
Start the SEI daemon, then wait for its socket:
Expected result: both sockets are listed.
-
Start the gateway and the MDX client:
In 3D, replace
--sensor-config /opt/nvidia/psf/bin/sensor_config.confwith--sensor-pipelines-config /opt/nvidia/psf/bin/sensor_pipelines_config.conf. -
In a separate terminal, on the PLC side, start the command receiver:
Expected result:
ATL UDP Command Receiver listening on port <cmd-rx-port>. -
Start the SDM:
-
Start SAIM from its baseline directory, if
required_safety_monitor = 1: -
Start PCM, if
required_perception_monitor = 1, with the same event mapping and SDM configuration as the SDM:PCM reads
/opt/nvidia/psf/bin/pcm_monitor.cfgand the baseline in/opt/nvidia/psf/bin/pcm_baseline. Check that it loaded both checks withgrep 'checks: container_health=' /var/log/psf/pcm.log | tail -n 1; the line should showdata_validation=on. -
Check that the SDM registered and is receiving decisions:
Expected result: a
SDM: sent registration (7 event types) to gatewayline, followed bySDM: received DecisionRequest from psdGatewaylines at least every 5 seconds. The receiver’s console shows the latch and release events.
For PXC, use /opt/nvidia/psf/apps/proximity/proximity_event_mapping.pb.txt,
proximity_sdm --config /opt/nvidia/psf/bin/pxc_sdm_forklift.conf --log_file /var/log/psf/pxc_sdm.log,
the same two files for PCM, and proximity_sdm_cmd_receiver.
To stop, send SIGTERM to every process; the gateway and the SDMs shut down cleanly on it:
Learning by hand
Learn mode needs no SEI daemon: neither monitor registers with it. Run both in one root shell,
against the normal, unobstructed scene, with <kafka-broker> as in By hand. Each
stops after --learn-duration seconds (1–3600, default 300). PCM exits with status 1 when it
could not write its baseline.
Expected result: one <camera>_baseline.cfg per camera in /opt/nvidia/psf/bin/saim_baseline,
and /opt/nvidia/psf/bin/pcm_baseline/pcm_baseline.cfg. PCM logs
DVM: baseline: published <n> camera(s) in /opt/nvidia/psf/bin/pcm_baseline/pcm_baseline.cfg; bbox/confidence/occupancy are not fault baselines.
Give PCM the same --event-mapping and --sdm-config values in learn and active mode; an active
PCM does not use a baseline learned with other values. See
PCM baselines.
Building the reference applications
The development package installs:
examples is /opt/nvidia/psf/examples/apps/metropolis after dpkg -i, or the same path under
<extraction-path> after dpkg -x.
Command receivers
The receivers need only their own source and packet header. On x86-64:
For IGX Thor, cross-compile on an x86-64 host with aarch64-linux-gnu-g++ and
E=<extraction-path>/opt/nvidia/psf/examples/apps/metropolis.
Decision makers
A reference SDM is built from these inputs:
The shared SDM headers are sdm_decision_request_state.h, sdm_decision_freshness.hpp,
sdm_gateway_decision_sequence.hpp and sdm_reviewed_sensor_set.hpp. The sensor-config parser is
sensor_config_parser.h and sensor_config_parser.cpp.
The development package at this release does not include the shared SDM headers or the
sensor-config parser, so the reference SDMs cannot be compiled from the package alone. The built
SDMs are in the runtime package, under /opt/nvidia/psf/apps. Use the shipped sources as the
reference for your own decision maker; its contract is on
Writing a decision maker.
FSI package
psf-tegra-fsi is for IGX Thor only. Install it on the Thor, with psf-tegra.
fsicom-agent needs libnvpsf_transport.so from psf-tegra, and the NvFsiCom and EPL libraries
of the IGX Safety Extension Package, which the Safety Core packages do not include. It also needs
the larger kernel socket buffers. Flashing the firmware and running the
agent are covered in Custom Deployment; the agent’s
options are on Launcher; its contract with the
gateway is on Writing a decision maker.