|
1 | 1 | # LeRobot |
2 | 2 |
|
3 | | -2025 • *The project involves mechanical assembly, servo control, embedded programming, and software integration, with an emphasis on understanding how hardware and software interact in practical robotics systems.* |
| 3 | +2025 • *I assembled a robotic arm and built a teleoperation system to teach it tasks through imitation learning.* |
4 | 4 |
|
5 | 5 | <video src="cover/cover.mp4" controls autoplay muted loop playsinline height="50vh"></video> |
6 | 6 |
|
7 | 7 | --- |
8 | 8 |
|
9 | 9 | ## Overview |
10 | 10 |
|
11 | | -**LeRobot** is a real-time teleoperation setup using a leader–follower robotic arm system. |
12 | | -The leader arm captures joint motions, which are mapped and mirrored live onto the follower arm through a custom control stack on Ubuntu. |
| 11 | +## What I Built |
13 | 12 |
|
14 | | -This setup allows **intuitive, low-latency human control** and forms the foundation for **learning from demonstration**, where the robot can later learn to perform tasks autonomously based on these human-guided trajectories. |
| 13 | +I wanted to teach a robot to perform tasks just by showing it how. |
| 14 | +To do this, I set up a **teleoperation system** with two robotic arms: a "leader" that I move by hand, and a "follower" that mirrors every movement in real-time. |
| 15 | + |
| 16 | +I wrote a custom control stack on Ubuntu that maps the joint angles from the first arm to the second one with very low latency. This makes controlling the robot feel natural—almost like an extension of my own arm. |
| 17 | + |
| 18 | +A lot of the complexity lived in the low-level details: **power sequencing, serial communication, USB permissions, and precise calibration**. Mastering these elements was crucial to ensuring reliable, real-time control. |
15 | 19 |
|
16 | 20 | --- |
17 | 21 |
|
18 | | -## Automation & Dataset Creation |
| 22 | +## From Teleoperation to Autonomy |
| 23 | + |
| 24 | +The goal of this setup is **Imitation Learning**. |
| 25 | +By recording the camera feed and the motor commands while I perform a task (like picking up an object), I create a dataset of "expert demonstrations." |
| 26 | + |
| 27 | +Each recording captures: |
| 28 | +- What the robot sees (video frames) |
| 29 | +- How it moves (motor commands) |
| 30 | +- Its internal state |
| 31 | + |
| 32 | +I can then use this data to train a neural network. |
| 33 | + |
| 34 | +### Technical Approach: ACT Policy |
19 | 35 |
|
20 | | -After a large number of episodes are recorded (consisting of time-synchronised camera frames and robot actions), the data is consolidated into a single dataset. |
21 | | -Every episode is stored as an ordered sequence of observations, including: |
| 36 | +To solve this, I utilized an **Action Chunking with Transformers (ACT)** policy. This architecture is effective because it mitigates the compounding errors typical in simple behavior cloning by predicting *sequences* of actions rather than single time-steps. |
22 | 37 |
|
23 | | -- Image frames |
24 | | -- Actuator commands |
25 | | -- Relevant state information |
| 38 | +**The Pipeline:** |
26 | 39 |
|
27 | | -This structured collection captures both successful executions and natural variation, providing a reliable foundation for training robotic control models. |
| 40 | +1. **Vision Encoder:** A **ResNet-18** backbone extracts features from the **wrist-mounted camera**, which provides an egocentric view crucial for precision manipulation. |
| 41 | +2. **State Encoding:** These visual features are concatenated with the robot's current proprioception (joint angles). |
| 42 | +3. **Policy Network:** A **Transformer (CVAE-based)** processes this multimodal input to predict a "chunk" of future actions ($k$ steps). Because it uses a Variational Autoencoder, it learns a latent space of valid behaviors, allowing it to handle variability in human demonstrations. |
| 43 | +4. **Temporal Ensembling:** During inference, overlapping action chunks are weighted and averaged. This yields extremely smooth trajectory generation, avoiding the jitter common in frame-by-frame policies. |
28 | 44 |
|
29 | 45 | --- |
30 | 46 | ## Videos |
|
0 commit comments