torchsig.signals.builders.lfm.lfm_modulator

torchsig.signals.builders.lfm.lfm_modulator(lfm_type: str, bandwidth: float, sample_rate: float, num_samples: int, rng: Generator | None = None) ndarray[source]

LFM modulator.

Parameters:
  • lfm_type – Type of LFM signal (‘data’ or ‘radar’).

  • bandwidth – Desired 3 dB bandwidth of the signal (Hz).

  • sample_rate – Sampling rate for the IQ signal (Hz).

  • num_samples – Number of IQ samples to produce.

  • rng – Random number generator for reproducibility. If None, creates a new default generator.

Returns:

LFM modulated signal at the appropriate bandwidth.

Return type:

np.ndarray

Raises:
  • ValueError – If bandwidth or sample_rate are not positive.

  • ValueError – If bandwidth exceeds sample_rate/2.

  • ValueError – If num_samples is not positive.

  • ValueError – If lfm_type is not supported.