Skip to content

Latest commit

 

History

History
87 lines (56 loc) · 3.58 KB

File metadata and controls

87 lines (56 loc) · 3.58 KB

Example Policies

This package contains baseline policy implementations that demonstrate different approaches to the cable insertion task. These examples serve as reference implementations and starting points for developing your own policies.

Note

Prerequisites: Before running these policies, ensure you have the evaluation environment running. See Getting Started for setup instructions.

Command Format:

  • If using the container workflow (recommended): Launch with distrobox enter -r aic_eval -- /entrypoint.sh [parameters]
  • If built from source: Launch with ros2 launch aic_bringup aic_gz_bringup.launch.py [parameters]
  • Run policies with pixi run ros2 run (Pixi workspace) or ros2 run (native ROS 2)

Available Policies

1. WaveArm - Minimal Example

Wave Arm Policy

A minimal example showing how to implement the insert_cable() callback and issue motion commands to the arm. This policy simply moves the robot arm back and forth in a waving motion without attempting to solve the task.

Purpose: Demonstrates the basic Policy API structure.

Launch the evaluation environment:

/entrypoint.sh ground_truth:=false start_aic_engine:=true

Run the policy:

pixi run ros2 run aic_model aic_model --ros-args -p use_sim_time:=true -p policy:=aic_example_policies.ros.WaveArm

Source: WaveArm.py


2. CheatCode - Ground Truth Policy

Cheat Code Policy

A "cheating" solution that uses the TF transformation tree provided by the simulation when ground_truth:=true is set at launch time. This policy uses the poses of the plug and port to calculate target poses to send to aic_controller.

Purpose: Useful for training and debugging. Ground truth data will not be available during official evaluation.

Launch simulation with ground truth:

/entrypoint.sh ground_truth:=true start_aic_engine:=true

Run the policy:

pixi run ros2 run aic_model aic_model --ros-args -p use_sim_time:=true -p policy:=aic_example_policies.ros.CheatCode

Source: CheatCode.py


3. RunACT - ACT Policy

Run ACT Policy

A proof-of-concept implementation of a LeRobot ACT (Action Chunking with Transformers) policy available on HuggingFace. This policy was trained on an NVIDIA RTX A5000 machine using lerobot-train with default parameters, on a small dataset collected using lerobot-record as explained in lerobot_robot_aic.

You may need to modify pixi.toml in order to run lerobot with your hardware setup. See Troubleshooting.

Purpose: Demonstrates integration of a trained neural network policy for the cable insertion task.

Launch the evaluation environment:

/entrypoint.sh ground_truth:=false start_aic_engine:=true

Run the policy:

pixi run ros2 run aic_model aic_model --ros-args -p use_sim_time:=true -p policy:=aic_example_policies.ros.RunACT

Source: RunACT.py


Scoring Examples

For expected scoring results and reproducible test commands for each policy, see the Scoring Test & Evaluation Guide.