goalie.has_cpu

goalie.has_cpu(n: int) bool

Check whether the machine has at least n CPU cores.

Parameters:

n (int) – Minimum number of logical CPU cores required.

Returns:

True if the machine has at least n cores.

Return type:

bool

Raises:

RuntimeError – If the CPU count cannot be determined.

Examples

>>> has_cpu(1)
True