Round Robin Scheduler

In 5G networks, a Round Robin scheduler is a type of scheduling algorithm used by the base station (gNodeB) to allocate resources among multiple user equipment (UEs) in a fair and equitable manner. The Round Robin scheduler ensures that each UE gets an equal opportunity to access network resources over time, regardless of factors such as channel conditions or priority levels.

Here’s how the Round Robin scheduler works:

  • Resource Allocation: The Round Robin scheduler allocates resources, such as frequency bands, time slots, or transmission power, to UEs in a sequential manner, cycling through each UE in a round-robin fashion.

  • Fairness: The scheduler ensures fairness by giving each UE an equal share of available resources during each scheduling cycle. This prevents any single UE from monopolizing network resources and ensures that all UEs have an opportunity to transmit data or receive service.

  • Scheduling Cycles: In each scheduling cycle, the Round Robin scheduler iterates through the list of active UEs and assigns resources to each UE in turn. Once all UEs have been served, the scheduler begins a new cycle, repeating the process.

  • Efficiency: While the Round Robin scheduler provides fairness among UEs, it may not always be the most efficient scheduling algorithm in terms of maximizing system throughput or meeting quality of service (QoS) requirements. Other scheduling algorithms, such as proportional fair scheduling or dynamic scheduling based on channel conditions, may be employed to optimize resource allocation and improve overall system performance.

  • Use Cases: Round Robin scheduling is often used in scenarios where fairness is a primary concern and there are no strict QoS requirements or variations in channel conditions among UEs. It is commonly employed in low-complexity systems or in situations where the network load is relatively balanced across UEs.

Overall, the Round Robin scheduler provides a simple and straightforward approach to resource allocation in 5G networks, ensuring fairness among UEs while maintaining a relatively uniform distribution of network resources. However, in more complex scenarios, alternative scheduling algorithms may be employed to achieve better performance and efficiency.

class toolkit5G.Scheduler.RoundRobinScheduler(numRB=10, numSymbol=12, numUEscheduledAcrossFreq=2, numUEscheduledAcrossTime=1, firstAcrossTime=False)[source]

The round robin scheduler allocated equal amount of resources to numUEscheduledAcrossFreq \(\times\) numUEscheduledAcrossTime UEs. The resource will allocated to UEs sequentially either accorss time first or accorss frequency first based on firstAcrossTime flag. The function returns the symbols and resources blocks allocated to each UE where total number of contending for resource allocation is given by numUEscheduledAcrossFreq \(\times\) numUEscheduledAcrossTime.

Parameters:
  • numRB (integer) – Defines the number of consecutive resource blocks (RBs) available for resource allocation. Default value is 10.

  • numSymbol (integer) – Defines the number of consecutive OFDM symbols available for resource allocation. Default value is 12.

  • numUEscheduledAcrossFreq (integer) – Defines the number of UEs scheduled across frequency (resource blocks). It should be an integer values and shall be selected such that numRB is an integer muliple of numUEscheduledAcrossFreq. The default value for this parameter is 2.

  • numUEscheduledAcrossTime (integer) – Defines the number of UEs scheduled across time (OFDM symbols). It should be an integer values and shall be selected such that numSymbol is an integer muliple of numUEscheduledAcrossTime. The default value for this parameter is 1.

  • firstAcrossTime (bool) – It’s a flag indicating whether UEs will be scheduled across frequency first or time first in the resource grid. If the flag is true, the UEs will be scheduled across time first.

Note

numRB and numSymbol shall be integer multiples of numUEscheduledAcrossFreq and numUEscheduledAcrossTime respectively.

Input:

None

Output:
  • (numUE, numSymbolPerUE) 2D numpy array – defines the indices of the OFDM symbols allocated to each UE where

    • numUE = numUEscheduledAcrossFreq \(\times\) numUEscheduledAcrossTime

    • numSymbolPerUE = \(\frac{\text{numSymbol}}{\text{numUEscheduledAcrossTime}}\)

  • (numUE, numRBPerUE) 2D numpy array – defines the indices of the resource blocks (RBs) allocated to each UE.

    • numUE = numUEscheduledAcrossFreq \(\times\) numUEscheduledAcrossTime

    • numRBPerUE = \(\frac{\text{numRB}}{\text{numUEscheduledAcrossFreq}}\)

Attributes:

resGrid ((numSymbol x numRB) matrix) – this parameter indicates the index of the UE which has been allocated each OFDM symbol and resource block.

Raises:
  • ValueError – “[Error-RoundRobinScheduler]: ‘numRB’ must be a positive integer less than or equal to 272!”

  • ValueError – “[Error-RoundRobinScheduler]: ‘numSymbol’ must be a postive integer less than or equal to 12!”

  • ValueError – “[Error-RoundRobinScheduler]: Its not possible to allocate equal frequency resources to {value} UEs in {self.numRB} RBs!”

  • ValueError – “[Error-RoundRobinScheduler]: ‘numUEscheduledAcrossFreq’ must be a positive integer!”

  • ValueError – “[Error-RoundRobinScheduler]: Its not possible to allocate equal time resources to {value} UEs in {self.numSymbol} OFDM symbols!”

  • ValueError – “[Error-RoundRobinScheduler]: ‘numUEscheduledAcrossTime’ must be a positive integer!”

  • ValueError – “[Error-RoundRobinScheduler]: ‘firstAcrossTime’ must be a boolean!”

property firstAcrossTime

Defines the flag to indicate whether UEs should be schedule across Time first. If false, the UEs will be filled accross frequency first.

property numRB

Defines total number of RBs available for resource allocation

property numSymbol

Defines total number of symbols available for resource allocation.

property numUEscheduledAcrossFreq

Defines number of UEs to schedule across Frequency

property numUEscheduledAcrossTime

Defines number of UEs to schedule across Time

RoundRobinScheduler.displayUEallocation()[source]

A method to display the time-frequency resource allocated to each UE from the total resource availble in the resource grid.