FERS 1.0.0
The Flexible Extensible Radar Simulator
Loading...
Searching...
No Matches
finalizer.cpp File Reference

Implements the asynchronous receiver data processing and output pipelines. More...

#include "finalizer.h"
#include <algorithm>
#include <chrono>
#include <cmath>
#include <format>
#include <highfive/highfive.hpp>
#include <ranges>
#include <tuple>
#include "core/logging.h"
#include "core/parameters.h"
#include "core/rendering_job.h"
#include "core/sim_threading.h"
#include "processing/signal_processor.h"
#include "radar/receiver.h"
#include "radar/target.h"
#include "radar/transmitter.h"
#include "serial/hdf5_handler.h"
#include "signal/dsp_filters.h"
#include "simulation/channel_model.h"
#include "timing/timing.h"
+ Include dependency graph for finalizer.cpp:

Go to the source code of this file.

Namespaces

namespace  processing
 

Functions

void processing::runPulsedFinalizer (radar::Receiver *receiver, const std::vector< std::unique_ptr< radar::Target > > *targets, std::shared_ptr< core::ProgressReporter > reporter)
 The main function for a dedicated pulsed-mode receiver finalizer thread.
 
void processing::finalizeCwReceiver (radar::Receiver *receiver, pool::ThreadPool *pool, std::shared_ptr< core::ProgressReporter > reporter)
 The finalization task for a continuous-wave (CW) mode receiver.
 

Detailed Description

Implements the asynchronous receiver data processing and output pipelines.

This file contains the core logic for finalizing received radar data. Finalization is performed asynchronously to the main simulation loop to avoid blocking physics calculations with expensive tasks like signal rendering, processing, and file I/O.

Two distinct finalization pipelines are implemented:

  1. runPulsedFinalizer: A long-running function executed in a dedicated thread for each pulsed-mode receiver. It processes data in chunks (RenderingJob) as they become available from the simulation loop.
  2. finalizeCwReceiver: A one-shot task submitted to the main thread pool for each continuous-wave receiver at the end of its operation. It processes the entire collected data buffer at once.

Both pipelines apply effects like thermal noise, phase noise (jitter), interference, downsampling, and ADC quantization before writing the final I/Q data to an HDF5 file.

Definition in file finalizer.cpp.