> For the complete documentation index, see [llms.txt](https://stage-precision.gitbook.io/grid/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://stage-precision.gitbook.io/grid/spatial-interactive-experiences/building-an-interactive-tracking-project/refine-the-tracked-clusters.md).

# Refine the Tracked Clusters

Once clustering produces reliable detections, the next step is to improve how those detections behave over time.

There are two separate processing stages after clustering:

**Clustering → Cluster Tracking → Cluster Filter**

**Cluster Tracking** controls how IDs are assigned and preserved between successive clustering results.

**Cluster Filters** operate on the resulting cluster data and can be used for processing such as smoothing or prediction.

***

## Configure Cluster Tracking

Select the **Point Cloud Volume**, open **Pipeline** in the Inspector, and locate **Cluster Tracking**.

Cluster Tracking is an identity-association stage. It determines whether a newly detected cluster should continue an existing ID or receive a new one.

It does **not** modify the actual cluster position, Bounding Box, or other spatial data.

The main settings are:

* **Distance Tolerance**
* **Id Lifetime**
* **Max Id**

### Distance Tolerance

**Distance Tolerance** defines how far a newly detected cluster may be from a previous cluster position while still being considered the same tracked object.

A larger tolerance allows an ID to survive larger positional changes between detections.

A value that is too small can cause unnecessary ID changes when an object moves quickly or the detected cluster position jumps slightly.

A value that is too large can increase the chance of an ID being associated with the wrong nearby object.

### Id Lifetime

**Id Lifetime** defines how long an ID remains available after its cluster disappears.

This is useful when an object is temporarily lost because of:

* Occlusion
* Missing measurements
* Short interruptions in clustering
* Temporary sensor coverage issues

If a compatible cluster reappears within the configured lifetime, Grid Studio can continue using the previous ID instead of assigning a new one.

A longer lifetime can make tracking more tolerant of temporary loss, while a shorter lifetime releases IDs more quickly.

### Max Id

**Max Id** defines the size of the available ID range.

Once the configured range has been used, IDs can be reused as they become available.

For most projects, this value simply needs to be large enough for the maximum number of tracked objects expected during operation.

{% hint style="info" %}
Cluster Tracking only affects **ID association**.

Changing these settings does not smooth, predict, resize, or otherwise modify the actual cluster data. Spatial refinement happens afterwards through **Cluster Filters**.
{% endhint %}

***

## Add Cluster Filters

Cluster Filters are processed after Cluster Tracking.

To add a Cluster Filter:

1. Select the **Point Cloud Volume**.
2. Open **Pipeline** in the Inspector.
3. Locate **Cluster Filter**.
4. Click the **+** button.
5. Select the required filter.

Multiple Cluster Filters can be added.

They are processed **from top to bottom**, and their order can be changed by dragging filters to a different position in the list.

{% hint style="info" %}
As with Input Filters, the order of Cluster Filters matters. Each filter receives the result of the filters above it.
{% endhint %}
