CARS — SpaceNet UCSD WorldView-3#
Compare DEMs produced by ASP and CARS on the same WorldView-3 stereo pair:
ASP (NASA Ames Stereo Pipeline) — processed in the UCSD notebook
CARS (CNES open-source stereo pipeline)
About CARS#
CARS is an open-source Python tool developed by CNES (French Space Agency) for producing DSMs from satellite stereo imagery. Key features:
Dense matching: Uses Pandora (Census cost + SGM) with multiple presets for urban, mountain, vegetation.
Multi-resolution: Coarse-to-fine processing (default 16x → 4x → 1x) progressively narrows disparity search range.
Geometry: Uses Shareloc for RPC handling — reads RPCs directly from GeoTIFF metadata.
Tiled architecture: Processes data in tiles with configurable parallelism and per-worker memory limits.
No bundle adjustment in the standard pipeline. Instead, CARS corrects epipolar grids using sparse SIFT tie points. Separate
cars-bundleadjustmenttool available as an optional extra.
Source Data#
Same WorldView-3 stereo pair as the SETSM comparison:
Catalog ID |
Date |
Off-nadir |
Image size |
|---|---|---|---|
1040010007A93700 |
2015-02-12 |
8.4° |
43008 × 46080 px |
1040010007CA4D00 |
2015-02-24 |
12.9° |
43008 × 46080 px |
This is the same pair (21deg_12d, convergence 21.2°) used in the scene-selection notebook and the ASP processing notebook.
Processing Approach: ROI on Full Images#
CARS supports two approaches for sub-scene processing:
cars-extractroi— pre-crops images and writes adjusted RPCs as.RPBsidecar files.roiconfig parameter — uses full images for sparse matching / grid correction but only runs dense matching within the specified ROI.
We use approach 2 (roi) because full images give CARS more context for SIFT tie-point matching and epipolar grid correction, with no manual RPC adjustment needed.
The ROI matches the ASP processing crop area (UCSD campus region, ~4 km × 4 km):
Lon: -117.262 to -117.219
Lat: 32.854 to 32.890
Running CARS via Docker#
docker pull cnes/cars
docker run --platform linux/amd64 --rm \
--cpus 6 \
-v /path/to/input_images:/input:ro \
-v /path/to/output:/output \
cnes/cars /output/config.yaml
Full configuration file (config.yaml)
input:
sensors:
left:
image: /input/1040010007A93700_P001.tif
right:
image: /input/1040010007CA4D00_P001.tif
roi:
type: FeatureCollection
features:
- type: Feature
properties: {}
geometry:
type: Polygon
coordinates:
- - [-117.262, 32.854]
- [-117.219, 32.854]
- [-117.219, 32.890]
- [-117.262, 32.890]
- [-117.262, 32.854]
output:
directory: /output/results
resolution: 2.0
epsg: 32611
orchestrator:
mode: multiprocessing
nb_workers: 2
max_ram_per_worker: 1500
Key parameters:
output.resolution: 2.0— 2 m output to match ASP processingoutput.epsg: 32611— UTM 11N (same CRS as ASP DEM)orchestrator.nb_workers: 2— limit parallelism for 16 GB laptoporchestrator.max_ram_per_worker: 1500— 1.5 GB per worker
Expected outputs in results/:
dsm/dsm.tif— DSM as GeoTIFF (float32)dsm/image.tif— Ortho-imagemetadata.json— Processing parameters and statistics
Notes on configuration
Vertical reference: CARS defaults to EGM96 geoid heights. For comparison with ASP (ellipsoidal heights), set
geoid: falsein the output config or convert afterwards.Matching preset: Default is
census_sgm_default(Census5, P1=8, P2=32). For urban areas,census_sgm_urban(Census11, P1=20, P2=80) may perform better.Initial elevation: Providing a coarse DEM via
input.initial_elevation.demnarrows the disparity search range and speeds processing.
Run Metrics#
Metric |
Value |
|---|---|
Computation time |
~17 h 18 min |
Peak memory |
~10.3 GB (hit CARS’ |
Docker |
11 GB |
Output DSM |
2017 × 2001 px, 2 m, EPSG:32611 + EGM96 |
Output std dev (raw) |
134.6 m (inflated by edge blunders outside the 3 km comparison box) |
Output std dev (3 km comparison crop) |
48.7 m |
Convergence angle |
21.2° |
CARS is slower than SETSM, primarily because Pandora’s per-tile Census + SGM matching is done in pure Python multiprocessing with two workers at 1.5 GB each. The run reports RAM available < 500 Mb warnings during the final texture / dsm / dsm_weights passes but completes successfully. The raw DSM carries some edge blunders (min −321 m, max 1273 m) outside the canonical 3 km comparison area; inside the comparison crop the range collapses to approximately −200 m to +200 m with outliers concentrated at the seaward edge.
Hillshade Comparison#
CARS resolves the urban structure cleanly — buildings, streets, the I-5 freeway on the east. Natural valleys and sea cliffs are also resolved — comparable to ASP in detail. CARS does attempt to correlate more pixels, including over the ocean surface. Areas with more heavy vegetation are also correlated, whereas these are left as voids in the ASP DEM. Some of these correlated pixels appear to be blunders (pits and mounds) on close inspection. In general, ASP (with these carefully selected processing parameters) appears to take a more conservative approach to correlation.
ASP 2m DEM
CARS 2m DEM