dragon.workflows.batch.BatchTopology

class BatchTopology[source]

Bases: object

Describes the placement of managers and worker pools across nodes.

Returned by Batch.topology().

Each manager process is co-located on the first node of its worker pool. All physical cores on every pool node are available as workers; no core is reserved for the manager process.

Hostnames in the string representation are compressed into Slurm-style bracket notation (e.g. node[001-004]) when the python-hostlist package is installed (pip install python-hostlist). Without it, hostnames are listed verbatim, separated by commas.

__init__(total_nodes: int , manager_hostnames: list [str ], pool_hostnames: list [list [str ]], workers_per_pool: list [int ]) None [source]

Methods

__init__(total_nodes, manager_hostnames, ...)

Attributes

total_nodes

Total number of nodes used by this Batch instance.

manager_hostnames

Hostname of the pool node where each manager process is co-located (the first node of the respective pool).

pool_hostnames

List of hostname-lists, one inner list per worker pool.

workers_per_pool

Per-pool worker counts (physical cores x nodes in that pool).

__init__(total_nodes: int , manager_hostnames: list [str ], pool_hostnames: list [list [str ]], workers_per_pool: list [int ]) None [source]
total_nodes

Total number of nodes used by this Batch instance.

manager_hostnames

Hostname of the pool node where each manager process is co-located (the first node of the respective pool).

pool_hostnames

List of hostname-lists, one inner list per worker pool.

workers_per_pool

Per-pool worker counts (physical cores x nodes in that pool).