Signal Extraction¶

The signal extraction evaluator collects full sample streams at transmitting and receiving DSP layers during simulation or hardware loop runtime.
1simulation = Simulation(num_samples=100)
2device_alpha = simulation.new_device()
3device_beta = simulation.new_device()
4
5# Create a transmitting and receiving modem for each device, respectively
6modem_alpha = TransmittingModem(waveform=RRCWaveform())
7device_alpha.transmitters.add(modem_alpha)
8modem_beta = ReceivingModem(waveform=RRCWaveform())
9device_beta.receivers.add(modem_beta)
10
11# Configure the simulation to extract generated signals
12simulation.add_evaluator(SignalExtractor(modem_alpha))
13simulation.add_evaluator(SignalExtractor(modem_beta))
14result = simulation.run()
- class SignalExtractor(target)[source]¶
Bases:
EvaluatorEvaluator extracting base-band sample sequences from DSP layour input or output streams.
Warning
Depending on the setup, this evaluator will create an enormous amount of data, which may lead to memory issues. If possible, signals should not be extracted from simulation runtimes.
- Parameters:
target (
Transmitter|Receiver) – The DSP layer to extract signals from.- Raises:
TypeError – If the target is not a transmitter or receiver instance.
- evaluate()[source]¶
Extracts the base-band sample sequences from the DSP layout input or output streams.
- Return type:
- initialize_result(grid)[source]¶
Initialize the respective result object for this evaluator.
- Parameters:
grid (
Sequence[GridDimensionInfo]) – The parameter grid over which the simulation iterates.- Return type:
Returns: The initialized evaluation result.
- class SignalExtraction(signal)[source]¶
Bases:
Evaluation[PlotVisualization],Artifact- Parameters:
signal (
Signal) – The base-band signal to extract.
- artifact()[source]¶
Returns the signal extraction as an artifact.
For signal extraction, the artifact is the same as the evaluation.
- Return type:
- class ExtractedSignals(grid, evaluator=None, base_dimension_index=0)[source]¶
Bases:
EvaluationResult[SignalExtraction]Result of a signal extraction evaluation.
Stores the extracted signal samples in a grid structure.
- Parameters:
grid (
Sequence[GridDimensionInfo]) – The grid of the evaluation result.evaluator (
Evaluator|None) – The evaluator that produced this result.base_dimension_index (
int) – The index of the base dimension used for plotting.
- add_artifact(coordinates, artifact, compute_confidence=True)[source]¶
Add an artifact to this evaluation result.
- Parameters:
coordinates (
tuple[int,...]) – Coordinates of the grid section to which the artifact belongs.artifact (
SignalExtraction) – Artifact to be added.compute_confidence (
bool) – Whether to compute the confidence level of the evaluation result for the given section coordinates.
- Return type:
- Returns:
Can the result be trusted? Always
Falseif compute_confidence is set toFalse.