1.1.5. utils.scheduler package

1.1.5.1. Submodules

1.1.5.1.1. radical.utils.scheduler.scheduler_base module

class radical.utils.scheduler.scheduler_base.SchedulerBase(resources)[source]

Bases: object

alloc(req)[source]

allocate a slice of the available resources to satisfy the request, and return that allocation.

The returned allocation is a tuple [loc, req], where ‘req’ is the reqest passed as argument, and ‘loc’ is eithen one of the following:

  • int: start index from the beginning of the resource list

  • list of ints: set of indexes in the resource list

dealloc(res)[source]

deallocate a given allocation to return its resources to the pool of resources available for new allocations.

get_layout()[source]

return row/col info for visual representation

get_map()[source]

return a map indicating current resource allocation

1.1.5.1.2. radical.utils.scheduler.scheduler_bitarray module

class radical.utils.scheduler.scheduler_bitarray.BitarrayScheduler(resources=0)[source]

Bases: SchedulerBase

alloc(req)[source]

allocate a slice of the available resources to satisfy the request, and return that allocation.

The returned allocation is a tuple [loc, req], where ‘req’ is the reqest passed as argument, and ‘loc’ is eithen one of the following:

  • int: start index from the beginning of the resource list

  • list of ints: set of indexes in the resource list

dealloc(res)[source]

deallocate a given allocation to return its resources to the pool of resources available for new allocations.

get_layout()[source]

return row/col info for visual representation

get_map()[source]

return a map indicating current resource allocation

get_stats()[source]