Flexiv Trainer is an all-in-one, local-first software platform for training physical AI skills on Flexiv robots. It takes you through the full imitation-learning workflow — collecting teleoperation demonstrations, saving them as LeRobot episodes, merging episodes into training datasets, and launching policy training runs — from a single web UI on your own machine, with no cloud services required.
The steps to set up and use this software can be summarized as:
- Install the software.
- Start the server.
- Set up robots and cameras in the UI.
- Teleoperate and record demonstration episodes.
- Review and merge episodes into one training dataset.
- Choose a policy and start training.
| OS | CPU |
|---|---|
| Ubuntu 22.04+ | x86-64, aarch64 |
- Python 3.12 or 3.14. Orbbec cameras require 3.12; on 3.14 only RealSense cameras are supported.
- GPU acceleration (optional but recommended).
- System config for realtime scheduling (see below).
This is required to run the teleoperation module:
echo "${USER} - rtprio 99" | sudo tee -a /etc/security/limits.conf
echo "${USER} - nice -20" | sudo tee -a /etc/security/limits.conf
echo "${USER} soft memlock unlimited" | sudo tee -a /etc/security/limits.conf
echo "${USER} hard memlock unlimited" | sudo tee -a /etc/security/limits.confImportant
Restart your device for the changes to take effect.
- A single- or dual-arm teleoperation setup eligible for high-transparency teleoperation.
- Supported cameras connected to your computer: 1 egocentric and 2 in-hand (left and right wrist), with the two in-hand cameras mounted on the follower robots.
- Flexiv Rizon series
- Intel RealSense cameras
- Orbbec cameras (Gemini 305/330 series and other OrbbecSDK v2 devices)
Both vendors can be used at the same time; each camera location is assigned a device serial independently, so a setup may mix RealSense and Orbbec cameras.
Orbbec support needs the pyorbbecsdk2 SDK, installed separately with
--no-deps:
pip install --no-deps 'pyorbbecsdk2>=2.1'The --no-deps is required, not optional. pyorbbecsdk2 declares hard pins for
its bundled example scripts (av==12.3.0, open3d, pygame, …) that
conflict with LeRobot's av>=15,<16; a plain install fails to resolve. The
binding itself does not import those packages and works against LeRobot's own
av.
The wheel is published for CPython 3.8–3.13 on Linux (x64/ARM64), Windows x64 and Apple Silicon — there is no 3.14 wheel and no source distribution, so Orbbec cameras need a Python 3.12 environment. When the SDK is absent the app still runs, reporting Orbbec as unavailable while RealSense cameras keep working.
On Linux, install the Orbbec udev rules once so cameras are reachable without
root. Skipping this is the usual cause of a camera that appears in lsusb but
never connects in the app:
sudo ./scripts/install-orbbec-udev-rules.shReplug the camera afterwards so the new permissions apply.
The rules cover both the raw USB node and the V4L2 /dev/videoN nodes. Without
the V4L2 rule the camera is still discovered but fails to open with
uvc_open failed ... Return Code: -6, because those nodes default to
root:video and most accounts are not in the video group.
Use a USB 3.0 port; the Gemini 305 falls back to reduced frame rates on USB 2.0.
-
Create a Python 3.12+ virtual environment:
python3 -m venv .venv
-
Activate the virtual environment:
source .venv/bin/activate -
Upgrade pip and install the package:
pip install --upgrade pip pip install -e .
To also install development dependencies (for running tests and linting):
pip install -e ".[dev]"The standard PyPI PyTorch package for aarch64 does not support CUDA (GPU acceleration) and will fall back to CPU-only execution. To enable GPU acceleration on NVIDIA Jetson devices, you must install the Jetson-compatible PyTorch wheels and their corresponding CUDA dependencies.
For JetPack 7 / CUDA 13, you can replace the default CPU PyTorch after installation:
pip install --no-deps --force-reinstall \
--index-url https://pypi.jetson-ai-lab.io/sbsa/cu130 \
torch==2.10.0 torchvision==0.25.0Refer to NVIDIA's official Jetson documentation for more details.
Start the backend server from the same environment where you installed the package:
source .venv/bin/activate
flexiv-trainer-serverAfter startup, the terminal prints the URL for the web UI. By default this is:
http://127.0.0.1:8000/
Open that URL in your browser to use the UI.
If the port is still occupied after closing a previous server session, clear leftover processes and start again:
source .venv/bin/activate
scripts/cleanup-server.sh
flexiv-trainer-serverWhen the UI opens, you will start on the home page.
- Enter the serial numbers for the two leader robots.
- Enter the serial numbers for the two follower robots.
- In the System Status tile, connect:
- Teleop Service
- Robot Data Service
- Cameras
- Confirm the system shows healthy status before moving on.
The home page also shows the storage locations used by the app for episodes, merged datasets, and training outputs.
Open Data Collection from the navigation bar.
On this page you can verify robot and camera health, view the camera feeds, monitor telemetry, run teleoperation, and record episodes.
- Check
System Statusand make sure teleoperation, robot data, and cameras are all connected. - Confirm that the egocentric and wrist camera feeds are updating at around 30 FPS.
- If needed, use
Home All Robotsbefore starting teleoperation. - In
Teleoperation Control, clickStartto begin teleoperation. - In
Episode Recording, choose which entries you want to record.- The default selection includes all available camera observations, robot states, and robot actions.
- Use
Select AllorDeselect Allif needed.
- Click the recording
Startbutton when you are ready to capture a demonstration. - Perform the task through teleoperation.
- Click the recording
Stopbutton when one episode is complete. - Click
Save Episodeto keep the recording, orDiscard Episodeto throw it away.
Saved episodes are written to the episode storage directory shown on the home page. By default, episodes are stored under:
.local/episodes/
Open Data Processing from the navigation bar.
- Click the add button in
Load Episodes. - In the episode browser, select one or more saved episode datasets.
- Use
Select AllorDeselect Allif you want to quickly toggle the full list. - Click
Load.
- Click an episode in the list to review it.
- Use the checkboxes to choose which episodes should be merged.
- Use
Select AllorDeselect Allto toggle the current list. - Click
Merge Selected Episodes.
The merging will take some time depending on the actual dataset size. When done:
- Review the merged dataset.
- Click
Nextif the merged dataset looks correct.
Merged datasets are stored under:
.local/datasets/
The experimental B-spline converter creates a new LeRobot dataset while
leaving the source dataset unchanged. Observations and videos are copied
without re-encoding. The copied dataset's discrete TCP action is replaced by
one flattened B-spline parameter segment per frame.
When B-Spline Diffusion is selected in Policy Training, the Start button runs this conversion automatically in the background and launches training only after the converted dataset validates successfully. Other policy types continue to train directly from the selected dataset. The command below remains available when a reusable converted dataset is wanted ahead of time.
With the default cubic configuration, one arm is represented by XYZ plus rotation-6D. The parameter matrix has shape:
(chunk_size + 2 * degree, 1 knot + 9 Cartesian controls)
= (16, 10)
Run the converter on a merged dataset:
flexivtrainer-convert-bspline \
.local/datasets/my_task \
.local/datasets/my_task_bsplineTCP pose axes are detected from the action names. To select arms explicitly:
flexivtrainer-convert-bspline \
.local/datasets/my_task \
.local/datasets/my_task_bspline \
--side left_arm \
--side right_armUseful fitting options include:
--degree 3
--chunk-size 10
--stride 1
--max-error 0.002
--smoothing 1e-12
The converted dataset stores its representation and per-episode reconstruction
report in meta/bspline.json. With the default settings, every episode must
contain at least 12 frames.
Important
This command prepares trainable spline-parameter targets. A B-spline-aware policy/rollout adapter is still required to reshape, validate, align, and evaluate predicted parameters. Do not send a checkpoint trained on this converted action feature through the existing Cartesian waypoint executor.
Open Policy Training from the navigation bar, then work through the steps.
- Click the add button to browse merged datasets.
- Select the dataset you want to train on.
- Click
Next.
- Review the dataset preview (whole dataset or a single episode).
- Click
Next.
- Select a training policy.
- The training output directory is generated automatically from the dataset name, policy, and a timestamp, and is shown under
Training Output Directory. - Click
Next.
- Under
Computation Device, leave the device onautoor pick a specific device. Use the reload button to re-evaluate available devices. - Click the start button in
Training Control. - Watch progress in the progress bar and the terminal log pane. Use
Pause/Resumewhile a run is live.
Training outputs are written to the output directory shown in Step 3. By default these live under:
.local/training/
For a normal session, the order is:
- Start
flexiv-trainer-server. - Open the web UI.
- Configure robot serial numbers on
Home. - Connect teleop service, robot data service, and cameras.
- Open
Data Collection. - Start teleoperation and record one or more demonstration episodes.
- Save the episodes you want to keep.
- Open
Data Processing. - Load and merge the saved episodes into one training dataset.
- Open
Policy Training. - Select the merged dataset and choose a policy.
- Pick a computation device and start training.
If you want to use the UI from another device on the same LAN, set a public base URL before starting the server:
export FLEXIV_TRAINER_PUBLIC_BASE_URL=http://<backend-host-ip>:8000
flexiv-trainer-serverThen open that public URL in a browser on the other device.
The backend API doc can be accessed at:
http://127.0.0.1:8000/docs