---
title: Conflict Fingerprint in MAPF
url: https://www.emergentmind.com/topics/conflict-fingerprint
type: topic
---

# Conflict Fingerprint in MAPF

A conflict fingerprint is a compact context-dependent encoding used in multi-agent path finding (MAPF) for car-like robots to efficiently represent the subset of constraints that influence the admissible heuristic value for a given path planning state. Originally introduced in the CAR-CHASE framework, conflict fingerprints enable precise, scalable, conflict-aware heuristic caching in algorithms such as Conflict-Based Search with Continuous Time (CL-CBS). By encoding only the constraints temporally, spatially, and geometrically relevant to a state-goal pair, conflict fingerprints allow both effective pruning and cache lookup, which drastically reduces redundant expensive computation while preserving admissibility and managing combinatorial cache growth. This concept is pivotal to making CBS tractable for nonholonomic agents where kinematic heuristics are computationally intensive [2512.12243].

## 1. Formal Definition and Mathematical Structure

Let $S$ be the set of hybrid-state nodes in CL-CBS; each state $s\in S$ encodes a $(x,y)$ pose and a timestamp. The global set of constraints generated by CBS conflict resolution is $\mathcal{C} = \{c_1, ..., c_M\}$. Given a constraint set $\mathcal{C}$, the admissible heuristic for reaching goal $g$ from state $s$ is
$$
h^*(s, g, \mathcal{C}) = \min_{\pi: s \to g,\, \pi \text{ satisfies } \mathcal{C}} \;\mathrm{cost}(\pi)
$$
A conflict fingerprint is a function
$$
\phi: 2^\mathcal{C} \times S \times G \longrightarrow F
$$
mapping each $(\mathcal{C}, s, g)$ triple to a fingerprint $\phi \in F$. This fingerprint is represented as:
$$
\phi = (B \in \{0,1\}^M,\, \{R_i\,|\,B_i=1\},\, \{T_i\,|\,B_i=1\})
$$
where $B$ is a length-$M$ bit-vector with $B_i = 1$ if constraint $c_i$ is relevant for $(s, g)$, $R_i \subset \mathbb{R}^2$ is the region blocked by $c_i$, and $T_i \subset \mathbb{R}$ specifies its active time window. This coding localizes constraint impact, focusing computational effort on only those constraints with direct effect on the nonholonomic heuristic at $(s, g)$.

## 2. Data Structure and Efficient Representation

The bit-vector $B$ is implemented as a fixed-size array of 64- or 128-bit words whose manipulation (set, test, hash) is $O(1)$ per machine word. Per relevant constraint, associated region and time-window metadata are stored in a small vector whose length $k = \sum_i B_i$ is typically much less than $M$. Each entry is
```cpp
struct ConstraintMeta {
  uint16_t constraint_id;
  float2   center;      // 2D position
  float    radius;      // spatial approx
  float    t_start, t_end; // temporal window
};
```
Total size is approximately 12–16 bytes per active constraint. Conflict fingerprints are rapidly hashable (first over $B$, with additional hashes for the metadata vector); cache fetches compare $B$ first, then scan metadata, making equality and lookup $O(1)$ amortized (with rare worst-case $O(k)$ overhead).

## 3. Constraint Relevance Filtering Mechanism

Constraint relevance is determined by spatial, temporal, and geometric tests. For conflict $c$ with pose $p_c$ and time $t_c$, it is deemed relevant for $(s, g)$ if:
- Temporal filter: $|t_c - t_s| \leq T_\mathrm{window}$;
- Spatial filter: $d_\mathrm{seg}(p_c, \ell) \leq \tau_\mathrm{spatial}$, with $\ell$ the path segment $p_s \to p_g$;
- Cone filter: $(p_c - p_s) \cdot \mathbf{u} \geq 0$ for $\mathbf{u} = (p_g - p_s)/\|p_g - p_s\|$.

Combined, these yield the predicate in LaTeX:
$$
\mathrm{Rel}(c, s, g) = \Big|t_c - t_s\Big|\leq T_w \,\wedge\, d_\mathrm{seg}(p_c, p_s, p_g)\leq\tau_s \,\vee\, (p_c - p_s)\cdot \frac{p_g-p_s}{\|p_g-p_s\|} \geq 0
$$
This multifaceted approach ensures only constraints within the local temporal and spatial horizon, and appropriate directionality, contribute to the fingerprint.

## 4. Fingerprint Extraction Algorithm

For each $(s,g,\mathcal{C})$, the fingerprint is built as:
```python
def ExtractFingerprint(s, g, C):
    B = zero_bitset(M)
    meta_list = []
    u = (g.pos - s.pos) / norm(g.pos - s.pos)
    for c in C: # O(|C|)
        if abs(c.time - s.time) > T_window: continue
        if DistanceToSegment(c.pos, s.pos, g.pos) <= τ_spatial or (c.pos - s.pos).dot(u) >= 0:
            B.set(c.id)
            meta_list.append(ConstraintMeta(c.id, c.pos, τ_spatial, c.time - T_w, c.time + T_w))
    return ConflictFingerprint(B, meta_list)
```
This process runs in $O(|\mathcal{C}|)$ time and maintains $O(k)$ space. The adaptive nature of the filtering is crucial for practicality.

## 5. Integration with Conflict-Aware Heuristic Caching

The fingerprint is used as a salient secondary cache key, yielding a mapping from state-key and fingerprint to heuristic value in an $unordered\_map$. For each query:
```python
def H_CARCHASE(s, g, C):
    φ = ExtractFingerprint(s, g, C)
    key = (encodeState(s), φ)
    if cache.contains(key):
        return cache[key]
    h = AdaptiveHybridHeuristic(s, g)
    cache[key] = h
    return h
```
The adaptive hybrid heuristic switches between $h_\mathrm{approx}$ and $h_\mathrm{exact}$:
- For $d > \tau$, $h_\mathrm{approx}$ uses table interpolation for $O(1)$ estimation.
- For $d \leq \tau$, $h_\mathrm{exact}$ invokes full nonholonomic (Reeds–Shepp) computation, which may involve $O(\log n)-O(1)$ complexity.
Only the constraints with positive $B_i$ are considered, yielding significant amortized savings.

## 6. Theoretical Properties and Quality Guarantees

CAR-CHASE’s analysis yields three main theorems:
1. **Admissibility Preservation:** If $h(s,g)$ is admissible, then the conflict-aware cache heuristic $h_{ca}(s,g,\mathcal{C}) \leq h^*(s,g,\mathcal{C})$ remains admissible under arbitrary constraint sets. The conservative relevance filter ensures all possible constraint impacts are considered.
2. **Bounded Cache Size:** Let $n$ be the number of distinct states visited, $k$ the mean number of relevant fingerprint contexts per state; then $|\mathrm{cache}| = O(n\cdot k)$, and empirically $k = O(a)$, $a$ being agent count, so cache size $O(n a)$.
3. **Bounded Suboptimality:** A* search using the hybrid heuristic finds solutions with
$$
C \leq (1+\epsilon) C^*
$$
where $\epsilon$ is the worst-case approximation factor of $h_\mathrm{approx}$. This ensures optimality near goals and bounded error elsewhere.

## 7. Empirical Performance and Impact

Evaluation on 480 instances over $100\times 100$ maps, for agent counts $\{10,20,25,30\}$ and obstacle densities $\{0\%, 50\%\}$ (with 120s timeout), yielded:

| Agent Count | Success Rate (%) | Avg Time (s) | Speedup ($\times$) |
| ----------- | --------------- | ------------ | ------------------ |
| 10 All      | 97.5 → 97.5     | 1.98 → 0.81  | 2.23               |
| 20 All      | 72.5 → 76.7     | 25.01 → 15.91| 2.40               |
| 25 All      | 68.3 → 81.7     | 23.01 → 16.06| 2.19               |
| 30 All      | 73.3 → 83.3     | 25.94 → 14.30| 3.19               |
| Overall     | 77.9 → 84.8 (+6.9 pp) | 17.59 → 11.21 | 2.46         |

Cases with high obstacle density and agent count achieved up to $4.06\times$ speedup. Cumulative runtime fell by 70.1%, and 33 instances that previously timed out were solved, indicating improved scalability. *A plausible implication is that the technique generalizes across other CBS variants where constraint-induced context dependency affects heuristic computation.*

## 8. Significance and Broader Context

Conflict fingerprints offer a rigorous mechanism for context-sensitive heuristic caching in nonholonomic MAPF problems. By encoding only the minimal set of relevant constraints, the technique preserves admissibility and restricts cache size to $O(n a)$, contrasting favorably with combinatorial explosion. The method’s empirical validation demonstrates that such fingerprints are not just theoretically compelling but also practically transformative for planning in cluttered, high-agent scenarios. This suggests conflict fingerprints could be central to future CBS extensions for other robotic domains where context-dependent constraints and expansive spaces challenge admissible heuristic computation.

Source: https://www.emergentmind.com/topics/conflict-fingerprint