enumerate_indices#
- sionna.phy.utils.enumerate_indices(bounds: List[int] | torch.Tensor) torch.Tensor[source]#
Enumerates all indices between 0 (included) and
bounds(excluded) in lexicographic order.- Parameters:
bounds (List[int] | torch.Tensor) – Collection of index bounds
- Outputs:
indices – Collection of all indices, in lexicographic order, with shape [prod(bounds), len(bounds)]
Examples
from sionna.phy.utils import enumerate_indices print(enumerate_indices([2, 3]).numpy()) # [[0 0] # [0 1] # [0 2] # [1 0] # [1 1] # [1 2]]