sar3d: port the Multi_antenna_3D_clean_v1 notebook algorithm
The old sar3d core was a port of the superseded Horns_3D notebook and produced wrong volumes. The compute core now follows the reference notebook exactly: - segmented_interleaved frame timing rebuilt from per-trace capture stamps (uniform tx_per_segment split as the no-stamps fallback), with the coarse inter-segment dtau and the intra-sweep dtau applied as one phase ramp before the IFFT; - ground scene coordinates with the ground_depth_m lift (scene Y=0 is the ground), full-region grid instead of a window around a center depth, geo_ref compensation anchored on the ground plane, power 0.3; - notebook finalization in C++: |acc/cnt|, depth mask, normalization without the Y-edge planes, separable Gaussian over (Z, X), level; - CUDA kernel computes geometry in double: float32 loses ~3e-4 of an A-scan sample in tau and drifts ~1e-4 from the float64 reference. Live-config keys follow: the center_depth/half_width/grid_n window knobs are replaced by ground/voxel/y-range/margin/sigma/power/tx_per_segment. Parity against the notebook npz exports (frames 0034-0036 of the 20260922_mine_fast_true dataset): max|diff| <= 1.6e-6 off the depth-mask knife edge, identical argmax, level rel diff <= 7e-7. Verified via make sar3d_parity --dump-dir + scripts/sar3d_volume_compare.py; the executable spec lives in scripts/sar3d_reference_check.py (bit-tight against the npz, including the animation shifted-grid arithmetic). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -145,11 +145,14 @@ all: $(TARGETS)
|
||||
|
||||
kamil_adc_collector: $(BIN_DIR)/kamil_adc_collector
|
||||
|
||||
# On-demand parity check of the sar3d processor against the gpr_cpp
|
||||
# standalone_bp example (same .npy dataset). Not part of `all`.
|
||||
# On-demand parity check of the sar3d processor against the reference notebook
|
||||
# volumes (scripts/sar3d_volume_compare.py diffs the dumped volume against a
|
||||
# *_volume.npz export). Not part of `all`.
|
||||
SAR3D_PARITY_OBJS := $(addprefix $(BUILD_DIR)/, \
|
||||
data_acq_and_processing/processing/tools/sar3d_parity_main.o \
|
||||
data_acq_and_processing/processing/processors/src/sar3d_processor.o)
|
||||
data_acq_and_processing/processing/processors/src/sar3d_processor.o \
|
||||
data_acq_and_processing/common_cpp/config/src/run_config.o \
|
||||
data_acq_and_processing/common_cpp/ipc/src/shared_types.o)
|
||||
|
||||
sar3d_parity: $(BIN_DIR)/sar3d_parity
|
||||
|
||||
|
||||
Reference in New Issue
Block a user