|
4 | 4 | # |
5 | 5 | # Priority order prefers partitions most likely to have availability. |
6 | 6 | # V100 is last due to slower performance near the test time limit. |
7 | | -# Falls back to gpu-l40s if no partition meets the idle node threshold. |
| 7 | +# Falls back to gpu-a100 if no partition meets the idle node threshold. |
| 8 | +# |
| 9 | +# gpu-l40s is out of rotation: it has been failing jobs for weeks, and it was |
| 10 | +# also the partition CI kept selecting and then starving on. |
| 11 | +# |
| 12 | +# Only fully idle nodes count. A "mix" node is partially allocated and may have |
| 13 | +# no free GPU, so counting it overstates availability: run 33553417354 picked |
| 14 | +# gpu-l40s on "1 idle/mix nodes", then sat in the queue until the 3-5.5h job |
| 15 | +# timeout without ever starting. |
| 16 | +# |
| 17 | +# The match is anchored at both ends. sinfo's %t suffixes a state to flag it -- |
| 18 | +# "*" not responding, "$" reserved for maintenance, "~" powered down -- and this |
| 19 | +# cluster does emit them (drain*, down*, alloc$, drain$ are all live right now). |
| 20 | +# A bare "^idle" would count idle* and idle$ as available and starve the job on |
| 21 | +# nodes that cannot take it. |
8 | 22 | # RTX 6000 nodes are excluded (too slow for the test suite time limit). |
9 | 23 | # |
10 | 24 | # Optional: set GPU_PARTITION_MIN_NODES before sourcing to require a minimum |
11 | | -# number of idle/mix nodes (e.g. GPU_PARTITION_MIN_NODES=2 for parallel bench jobs). |
| 25 | +# number of idle nodes (e.g. GPU_PARTITION_MIN_NODES=2 for parallel bench jobs). |
12 | 26 | # |
13 | 27 | # Usage: source .github/scripts/select-gpu-partition.sh |
14 | 28 |
|
15 | | -_GPU_PARTITION_PRIORITY="gpu-l40s gpu-h200 gpu-h100 gpu-a100 gpu-v100" |
16 | | -_GPU_PARTITION_FALLBACK="gpu-l40s" |
| 29 | +_GPU_PARTITION_PRIORITY="gpu-h200 gpu-h100 gpu-a100 gpu-v100" |
| 30 | +_GPU_PARTITION_FALLBACK="gpu-a100" |
17 | 31 | _GPU_PARTITION_MIN_NODES="${GPU_PARTITION_MIN_NODES:-1}" |
18 | 32 |
|
19 | 33 | SELECTED_GPU_PARTITION="" |
20 | 34 | for _part in $_GPU_PARTITION_PRIORITY; do |
21 | | - _idle=$(sinfo -p "$_part" --noheader -o "%t" 2>/dev/null | grep -cE "^(idle|mix)" || true) |
| 35 | + _idle=$(sinfo -p "$_part" --noheader -o "%t" 2>/dev/null | grep -cE "^idle$" || true) |
22 | 36 | if [ "${_idle:-0}" -ge "$_GPU_PARTITION_MIN_NODES" ]; then |
23 | 37 | SELECTED_GPU_PARTITION="$_part" |
24 | | - echo "Selected GPU partition: $SELECTED_GPU_PARTITION ($_idle idle/mix nodes)" |
| 38 | + echo "Selected GPU partition: $SELECTED_GPU_PARTITION ($_idle idle nodes)" |
25 | 39 | break |
26 | 40 | fi |
27 | 41 | done |
|
0 commit comments