RayleighBlockFading#
- class sionna.phy.channel.RayleighBlockFading(num_rx: int, num_rx_ant: int, num_tx: int, num_tx_ant: int, precision: str | None = None, device: str | None = None, **kwargs)[source]#
Bases:
sionna.phy.channel.channel_model.ChannelModelGenerates channel impulse responses corresponding to a Rayleigh block fading channel model
The channel impulse responses generated are formed of a single path with zero delay and a normally distributed fading coefficient. All time steps of a batch example share the same channel coefficient (block fading).
This class can be used in conjunction with the classes that simulate the channel response in time or frequency domain, i.e.,
OFDMChannel,TimeChannel,GenerateOFDMChannel,ApplyOFDMChannel,GenerateTimeChannel,ApplyTimeChannel.- Parameters:
num_rx (int) – Number of receivers (\(N_R\))
num_rx_ant (int) – Number of antennas per receiver (\(N_{RA}\))
num_tx (int) – Number of transmitters (\(N_T\))
num_tx_ant (int) – Number of antennas per transmitter (\(N_{TA}\))
precision (str | None) – Precision used for internal calculations and outputs. If set to None,
precisionis used.device (str | None) – Device for computation (e.g., ‘cpu’, ‘cuda:0’). If None,
deviceis used.
- Inputs:
batch_size – int. Batch size.
num_time_steps – int. Number of time steps.
sampling_frequency – float. Sampling frequency [Hz]. Not used but accepted for compatibility with the
ChannelModelinterface.
- Outputs:
a – [batch size, num_rx, num_rx_ant, num_tx, num_tx_ant, num_paths=1, num_time_steps], torch.complex. Path coefficients.
tau – [batch size, num_rx, num_tx, num_paths=1], torch.float. Path delays [s].
Examples
import torch from sionna.phy.channel import RayleighBlockFading channel_model = RayleighBlockFading(num_rx=1, num_rx_ant=2, num_tx=1, num_tx_ant=4) h, tau = channel_model(batch_size=32, num_time_steps=14) print(h.shape) # torch.Size([32, 1, 2, 1, 4, 1, 14]) print(tau.shape) # torch.Size([32, 1, 1, 1])
Attributes