@@ -74,28 +74,7 @@ struct ProcessingLiveConfig {
|
||||
bool gpr_remove_sidelobe_objects_enabled = true;
|
||||
// BP image is computed in the y=imaging_plane_y_m slice of the 3D grid.
|
||||
// Default 0 keeps legacy 1D antenna layouts imaging in the antenna plane.
|
||||
// Used only when gpr_plane_mode == "const".
|
||||
float gpr_imaging_plane_y_m = 0.0F;
|
||||
// Acquisition timing model for motion correction (notebook
|
||||
// FREQUENCY_TIMING_MODE): "segmented_interleaved" — Tx outputs run in
|
||||
// sequential segments, each segment sweeps all frequencies over its window
|
||||
// while its Tx interleave per frequency; "interleaved" — legacy model where
|
||||
// all Tx interleave over the whole frame.
|
||||
std::string gpr_timing_mode = "segmented_interleaved";
|
||||
// Fallback segment size when per-trace capture timestamps are absent;
|
||||
// timestamp grouping wins when available.
|
||||
std::uint32_t gpr_tx_per_segment = 2U;
|
||||
// Imaging plane of the 2D BP map (notebook BP_PLANE_MODE): "ground" — the
|
||||
// plane follows the ground given the frame pitch, needed once the antennas
|
||||
// are spread vertically; "const" — legacy fixed y = gpr_imaging_plane_y_m.
|
||||
std::string gpr_plane_mode = "ground";
|
||||
// Height of the LOWER antenna row above the ground, metres (notebook
|
||||
// BP_GROUND_DEPTH_M; structural constant of the frame).
|
||||
float gpr_ground_depth_m = 1.25F;
|
||||
// Frame pitch used by the ground plane. Override disabled -> the pitch
|
||||
// falls back to gpr_look_angle_deg (notebook BP_GROUND_PITCH_DEG = None).
|
||||
bool gpr_ground_pitch_override_enabled = false;
|
||||
float gpr_ground_pitch_deg = 6.5F;
|
||||
// Coherent BP object visibility (window + the draw limits below) is applied in
|
||||
// the processor itself, matching Horns_motion_3libre.py — there is NO score
|
||||
// threshold for it. Only legacy GPR still thresholds, on a pair count.
|
||||
|
||||
@@ -67,20 +67,6 @@ using Json = nlohmann::json;
|
||||
throw std::runtime_error(field_name + " must be one of: int_minus, int_focus");
|
||||
}
|
||||
|
||||
[[nodiscard]] auto parse_gpr_timing_mode(const std::string& value, const std::string& field_name) -> std::string {
|
||||
if (value == "segmented_interleaved" || value == "interleaved") {
|
||||
return value;
|
||||
}
|
||||
throw std::runtime_error(field_name + " must be one of: segmented_interleaved, interleaved");
|
||||
}
|
||||
|
||||
[[nodiscard]] auto parse_gpr_plane_mode(const std::string& value, const std::string& field_name) -> std::string {
|
||||
if (value == "ground" || value == "const") {
|
||||
return value;
|
||||
}
|
||||
throw std::runtime_error(field_name + " must be one of: ground, const");
|
||||
}
|
||||
|
||||
void apply_legacy_gpr_algorithm_alias(ProcessingLiveConfig& config, const std::string& value) {
|
||||
if (value == "backprojection") {
|
||||
return;
|
||||
@@ -369,45 +355,6 @@ void apply_legacy_gpr_algorithm_alias(ProcessingLiveConfig& config, const std::s
|
||||
}
|
||||
config.gpr_imaging_plane_y_m = static_cast<float>(found->get<double>());
|
||||
}
|
||||
if (const auto found = root.find("gpr_timing_mode"); found != root.end()) {
|
||||
if (!found->is_string()) {
|
||||
throw std::runtime_error("processing.gpr_timing_mode must be string");
|
||||
}
|
||||
config.gpr_timing_mode = parse_gpr_timing_mode(found->get<std::string>(), "processing.gpr_timing_mode");
|
||||
}
|
||||
if (const auto found = root.find("gpr_tx_per_segment"); found != root.end()) {
|
||||
config.gpr_tx_per_segment = parse_u32_number(*found, "processing.gpr_tx_per_segment");
|
||||
if (config.gpr_tx_per_segment == 0U) {
|
||||
throw std::runtime_error("processing.gpr_tx_per_segment must be >= 1");
|
||||
}
|
||||
}
|
||||
if (const auto found = root.find("gpr_plane_mode"); found != root.end()) {
|
||||
if (!found->is_string()) {
|
||||
throw std::runtime_error("processing.gpr_plane_mode must be string");
|
||||
}
|
||||
config.gpr_plane_mode = parse_gpr_plane_mode(found->get<std::string>(), "processing.gpr_plane_mode");
|
||||
}
|
||||
if (const auto found = root.find("gpr_ground_depth_m"); found != root.end()) {
|
||||
if (!found->is_number()) {
|
||||
throw std::runtime_error("processing.gpr_ground_depth_m must be number");
|
||||
}
|
||||
config.gpr_ground_depth_m = static_cast<float>(found->get<double>());
|
||||
if (config.gpr_ground_depth_m < 0.0F) {
|
||||
throw std::runtime_error("processing.gpr_ground_depth_m must be >= 0");
|
||||
}
|
||||
}
|
||||
if (const auto found = root.find("gpr_ground_pitch_override_enabled"); found != root.end()) {
|
||||
if (!found->is_boolean()) {
|
||||
throw std::runtime_error("processing.gpr_ground_pitch_override_enabled must be bool");
|
||||
}
|
||||
config.gpr_ground_pitch_override_enabled = found->get<bool>();
|
||||
}
|
||||
if (const auto found = root.find("gpr_ground_pitch_deg"); found != root.end()) {
|
||||
if (!found->is_number()) {
|
||||
throw std::runtime_error("processing.gpr_ground_pitch_deg must be number");
|
||||
}
|
||||
config.gpr_ground_pitch_deg = static_cast<float>(found->get<double>());
|
||||
}
|
||||
for (const auto& [key, target] : {
|
||||
std::pair{"gpr_visible_x_min_m", &config.gpr_visible_x_min_m},
|
||||
std::pair{"gpr_visible_x_max_m", &config.gpr_visible_x_max_m},
|
||||
|
||||
Reference in New Issue
Block a user