Skip to content

CFAR Detection and Thresholding

CFAR Detection and Thresholding curated visual

Visual: CFAR sliding window with cell-under-test, guard cells, training cells, clutter estimate, adaptive threshold, and detection output.

Constant false alarm rate (CFAR) detection adapts a threshold to the local noise or clutter floor. The first-principles reason is that a fixed threshold cannot work across all ranges, angles, weather, terrain, interference, and antenna sidelobes. CFAR decides what becomes a radar detection before tracking, classification, or fusion sees it.



Why it matters for AV, perception, SLAM, and mapping

Radar perception begins with thresholding a range-Doppler-angle power field. If CFAR is too aggressive, low-RCS pedestrians, cones, FOD, and distant vehicles never become detections. If it is too permissive, trackers must handle a flood of clutter and ghosts. The threshold policy therefore changes object recall, false positives, track stability, and radar map quality.

CFAR parameters are also scenario-dependent. Airport aprons, highways, tunnels, wet pavement, parked aircraft, guardrails, vegetation, and rain all create different clutter statistics.


Core math and algorithm steps

Cell under test

For a power map P, define a cell under test (CUT):

P_cut = P[r, d]

Use guard cells around the CUT so target energy does not contaminate the noise estimate. Use training cells around the guard region to estimate local clutter.

training cells | guard | CUT | guard | training cells

CA-CFAR

Cell-averaging CFAR estimates noise as:

Z = mean(training_cell_powers)
threshold = alpha * Z
detect if P_cut > threshold

For exponentially distributed noise power and N training cells, a common CA-CFAR scale for desired false alarm probability P_fa is:

alpha = N * (P_fa^(-1/N) - 1)

This formula assumes independent homogeneous training cells. Real automotive radar often violates that assumption.

GO, SO, and OS-CFAR

VariantRuleUseful whenRisk
CA-CFARmean all training cellshomogeneous backgroundfails at clutter edges and multi-target cells
GO-CFARuse greater of leading/trailing estimatesclutter edge protectioncan miss weak targets near clutter
SO-CFARuse smaller of leading/trailing estimatestarget masking reductionmore false alarms at clutter edges
OS-CFARsort training cells and use selected rankinterfering targets and nonhomogeneous clutterrank and scale need tuning

Ordered-statistic CFAR:

sorted_training = sort(training_powers)
Z = sorted_training[k]
threshold = alpha_os * Z

The rank k controls robustness against outliers inside the training window.

Two-dimensional CFAR

In range-Doppler maps, use 2D training and guard windows:

for each range bin r and Doppler bin d:
  collect training cells around (r, d), excluding guard cells
  estimate local noise/clutter
  compare CUT to threshold

Some stacks run CFAR separately by range and Doppler; others run 2D CFAR or apply CFAR after noncoherent antenna accumulation. The decision changes what weak or extended targets survive.

Detection post-processing

After thresholding:

group adjacent detections
keep local maxima
estimate SNR/noise floor
estimate angle for selected cells
attach Doppler, range, power, and covariance metadata
send detections to clustering or tracking

Peak grouping is not cosmetic. Without it, one physical target can produce many detections from adjacent bins and sidelobes.


Implementation notes

  • Tune CFAR on power, not arbitrary display dB values, unless the algorithm is explicitly derived for log-domain statistics.
  • Keep guard cells large enough for the main lobe and window sidelobes.
  • Do not use training cells that cross known invalid regions, range wrap zones, or strong static leakage zones.
  • Parameterize by range and angle when the noise floor varies over the field of view.
  • Record per-detection threshold, estimated noise, SNR, and CFAR variant. These fields make downstream tracker failures explainable.
  • Evaluate CFAR jointly with tracker metrics. A detector setting that improves per-frame precision may harm track continuity.
  • Use replay slices with corner cases: rain, wet ground, tunnels, metal fences, aircraft, close bright vehicles, and sparse low-RCS targets.

Failure modes and diagnostics

Failure modeSymptomDiagnostic
Target maskingWeak target near strong target disappears.Inspect training cells contaminated by strong return.
Clutter edge false alarmsDetections line up along walls, guardrails, or ground transitions.Compare CA-CFAR with GO/OS-CFAR in same region.
Too few guard cellsThreshold rises around true target.Main lobe leaks into training cells.
Too many training cellsLocal adaptation too slow.Threshold ignores localized clutter patch.
Log-domain errorFalse alarm rate not close to design value.Validate with simulated exponential noise.
Sidelobe detectionsMultiple detections around one bright reflector.Check windowing and peak grouping.
Nonstationary interferenceBursty false detections across many bins.Time-frequency plots and raw ADC inspection.

Sources

Public research notes collected from public sources.