polaris.e3sm.init.partitions.build_partitions
- polaris.e3sm.init.partitions.build_partitions(regions, cores, basename, ncells, process_count, logger)[source]
Write the partition file for each core count, several at a time.
Each region’s graph is partitioned into
npieces on its own, and pieceiof every region goes to corei, so every core gets a share of every region. With one region covering the whole mesh, that is a plain partition of the mesh’s graph.Each partition is written under another name and renamed once it is complete, so a job killed at its walltime cannot leave a truncated file under the name E3SM reads.
- Parameters:
regions (list of RegionGraph) – The graphs to partition, one per region.
cores (iterable of int) – The core counts to build a partition file for.
basename (str) – The partition filenames without the
.part.<n>suffix.ncells (int) – The number of cells in the full mesh.
process_count (int) – The most
gpmetisprocesses to run at once.logger (logging.Logger) – The logger to report progress to.