This example builds on top of the ping_simple example to demonstrate how to create your own custom operator.
There are three operators involved in this example (tx -> mx -> rx):
- a transmitter, set to transmit a sequence of integes from 1-10 to it's 'out' port
- a middle operator that prints the received values, multiplies by a scalar and transmits the modified values
- a receiver that prints the received values to the terminal
Visit the SDK User Guide for step-by-step documentation of this example.
- using deb package install or NGC container:
/opt/nvidia/holoscan/examples/ping_custom_op/cpp/ping_custom_op
- source (dev container):
./run launch # optional: append `install` for install tree ./examples/ping_custom_op/cpp/ping_custom_op - source (local env):
${BUILD_OR_INSTALL_DIR}/examples/ping_custom_op/cpp/ping_custom_op
- using python wheel:
# [Prerequisite] Download example .py file below to `APP_DIR` # [Optional] Start the virtualenv where holoscan is installed python3 <APP_DIR>/ping_custom_op.py
- from NGC container:
python3 /opt/nvidia/holoscan/examples/ping_custom_op/python/ping_custom_op.py
- source (dev container):
./run launch # optional: append `install` for install tree python3 ./examples/ping_custom_op/python/ping_custom_op.py - source (local env):
export PYTHONPATH=${BUILD_OR_INSTALL_DIR}/python/lib python3 ${BUILD_OR_INSTALL_DIR}/examples/ping_custom_op/python/ping_custom_op.py