tilus.ir.layout.compose¶
- tilus.ir.layout.compose(outer, inner)[source]¶
Compose two layouts together.
Given two layouts with shapes (d_0, d_1, …, d_{n-1}) and (d’_0, d’_1, …, d’_{n-1}), the compose function will return a new layout with shape (d_0 * d’_0, d_1 * d’_1, …, d_{n-1} * d’_{n-1}). The modes of the new layout will be the concatenation of the modes of the two layouts. The spatial dimensions of the new layout will be the concatenation of the spatial dimensions of the two layouts. The local dimensions of the new layout will be the concatenation of the local dimensions of the two layouts. The spatial_modes and local_modes of the new layout will be the concatenation of the spatial_modes and local_modes of the two layouts, respectively, where the outer layout’s spatial_modes and local_modes come first, followed by the inner layout’s spatial_modes and local_modes.
- Parameters:
outer (RegisterLayout) – The outer layout.
inner (RegisterLayout) – The inner layout.
- Returns:
ret – The composed layout.
- Return type: