> ## Documentation Index
> Fetch the complete documentation index at: https://avala.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# 3D Point Cloud Annotation

> Annotate LiDAR point clouds with 3D cuboids using multi-camera projection

This tutorial covers annotating 3D point cloud data with cuboids and using multi-camera projection.

<iframe width="560" height="315" src="https://www.youtube.com/embed/Wfj1CbJUJcs" title="AV Annotation Project" frameBorder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowFullScreen />

## What You'll Learn

* How to upload and view point cloud data
* How to draw 3D cuboids in point clouds
* How to use multi-camera views for verification
* How to track objects across frames

## Prerequisites

* Point cloud data (MCAP, PCD, or PLY format)
* Camera images (optional, for multi-view)
* Camera calibration data (for projection)

## Step 1: Upload Point Cloud Data

### MCAP Files (Recommended)

1. Create a new dataset with type **LiDAR**
2. Upload your MCAP file containing:
   * Point cloud messages (e.g., `sensor_msgs/PointCloud2`)
   * Camera images (optional)
   * Calibration data (optional)

### Individual Point Clouds

1. Create a dataset with type **LiDAR**
2. Upload PCD or PLY files
3. Files are treated as individual scans

<Tip>
  MCAP files with embedded camera data enable automatic multi-camera projection of 3D annotations.
</Tip>

## Step 2: Open the 3D Viewer

1. Navigate to your dataset → **Sequences**
2. Click on a sequence to open the viewer
3. The interface shows:
   * **3D viewport**: Point cloud visualization
   * **Camera views**: Synchronized camera images
   * **Timeline**: Frame navigation
   * **Object list**: Annotated objects

## Step 3: Navigate the 3D View

### Mouse Controls

| Action      | Control            |
| ----------- | ------------------ |
| Rotate view | Left-click + drag  |
| Pan view    | Right-click + drag |
| Zoom        | Scroll wheel       |
| Reset view  | Press `R`          |

### Display Options

* **Point size**: Adjust point rendering size
* **Color mode**: Height, intensity, or RGB
* **Ground plane**: Toggle ground visualization

## Step 4: Draw 3D Cuboids

1. Select the **Cuboid tool** from the toolbar
2. Click in the point cloud to place the cuboid center
3. Adjust the cuboid:
   * **Drag corners**: Resize dimensions
   * **Drag edges**: Adjust individual dimensions
   * **Drag center**: Move position
   * **Drag rotation handle**: Rotate around Z-axis
4. Assign a label from the dropdown
5. Click **Save**

### Cuboid Tips

* **Fit to points**: Adjust cuboid to tightly enclose points
* **Use camera views**: Verify cuboid position in 2D
* **Ground contact**: Align bottom with ground plane
* **Orientation**: Match vehicle/object heading

## Step 5: Multi-Camera Projection

When camera data is available:

1. 3D cuboids automatically project onto camera images
2. Verify projections in each camera view
3. Adjust cuboid position if projection is misaligned
4. Check occlusion and truncation

### Calibration

If projections are misaligned:

1. Go to **Settings** → **Camera Calibration**
2. Adjust intrinsic/extrinsic parameters
3. Save calibration
4. Projections update automatically

## Step 6: Object Tracking

For sequences with multiple frames:

1. Create a cuboid on the first frame
2. Navigate to the next frame
3. The object persists (tracking mode)
4. Adjust position for object movement
5. Repeat for each frame

### Tracking Tips

* **Interpolation**: System can interpolate between keyframes
* **ID consistency**: Keep the same object ID across frames
* **Lost objects**: Mark as occluded when not visible

## Step 7: Review and Export

1. Review annotations in the 3D viewer
2. Check multi-camera projections
3. Export in your preferred format:
   * **KITTI**: Standard AV format
   * **nuScenes**: Multi-frame format
   * **Avala Format**: Full metadata

## Keyboard Shortcuts

| Shortcut  | Action              |
| --------- | ------------------- |
| `C`       | Cuboid tool         |
| `V`       | Select tool         |
| `R`       | Reset view          |
| `G`       | Toggle ground plane |
| `←` / `→` | Previous/Next frame |
| `Space`   | Play/Pause sequence |
| `Delete`  | Delete selected     |

## Next Steps

* Learn about [Managing Datasets](/docs/annotation/guides/managing-datasets) for organizing data
* Explore [Supported Formats](/docs/annotation/reference/supported-formats) for details on data formats
* Check [Keyboard Shortcuts](/docs/annotation/reference/keyboard-shortcuts) for all shortcuts
