Large-Scale Model Training on Domestic AI Clusters: A 10,000-GPU Practical Guide

    This article breaks down the engineering practices required to train large models on 10,000-GPU heterogeneous domestic AI clusters. It covers how to plan for effective throughput rather than peak FLOPS, align parallelism strategies with cluster topology, tune communication and memory usage, build fault tolerance for large-scale jobs, and evaluate training efficiency through cost per token. A phased rollout path is included for teams moving from small-scale validation to 10,000-GPU production training.

    1. Background: The Bottleneck Is Shifting from GPU Availability to GPU Efficiency

    Over the past two years, models with parameter counts moving from hundreds of billions to trillions have become a major industry direction. The compute supply structure has changed accordingly, with a growing share of training workloads now running on domestic accelerators. One representative pattern from the source material: during a model release cycle, platform invocation volume grew roughly tenfold, and the traffic spike was absorbed by a domestic compute cluster deployed in advance; the team subsequently raised its annual recurring revenue guidance.

    The real technical question here is not whether a particular piece of hardware is good enough. It is a general engineering problem: on a 10,000-GPU heterogeneous domestic cluster, how do you convert theoretical compute into effective throughput that is sustainable, measurable, and cost-controlled? This article addresses that question.

    To be clear, this article does not benchmark any specific hardware model or commercial product. All figures are illustrative and used only to explain the methodology.

    2. Compute Planning: From Stacking GPUs to Measuring Effective FLOPS

    2.1 Effective Compute, Not Peak Compute

    Peak compute is of limited value when evaluating a training cluster. More useful metrics are end-to-end effective throughput (tokens/s) and Model FLOPs Utilization (MFU). As a rule of thumb, if MFU for large-scale dense model training stays below 20% over time, the bottleneck is most likely not the compute units themselves, but communication, data supply, or frequent recomputation.

    2.2 Cluster Topology Determines the Parallelism Strategy

    A 10,000-GPU cluster is typically divided into several high-bandwidth domains. The parallelism strategy must align with that topology:

    • Tensor parallelism (TP) is the most communication-intensive and should be confined to a single machine or a single high-bandwidth domain.
    • Pipeline parallelism (PP) has low communication volume but introduces bubbles, making it suitable across domains.
    • Data parallelism (DP) requires gradient synchronization, is usually applied over the widest range, and is combined with sharded optimizer states to reduce memory pressure.

    A common misconfiguration is spreading TP across domains, which amplifies AllReduce latency several times over. The result: the more GPUs you add, the slower it gets.

    1. # Illustrative: constraint checks for aligning parallelism dimensions with topology
    2. def validate_parallel_plan(tp, pp, dp, gpus_per_domain):
    3. assert tp <= gpus_per_domain, "TP should not cross high-bandwidth domain boundaries"
    4. assert tp * pp * dp == world_size, "The product of parallelism degrees must equal the total GPU count"
    5. # Too many PP stages amplify bubbles; match against the number of micro-batches
    6. assert num_micro_batches >= pp * 4, "Not enough micro-batches to hide pipeline bubbles"

    3. Communication and Memory: Tuning Checklists for the Two Main Fronts

    3.1 Communication Optimization

    • Gradient compression and bucket merging: merge small gradients into large buckets and transfer them in a single pass to reduce launch overhead.
    • Compute-communication overlap: trigger communication in layer-ready order during backpropagation to hide latency.
    • Sequence parallelism: for long-context workloads, split activations such as LayerNorm and Dropout along the sequence dimension to significantly reduce activation memory.
    • Topology-aware scheduling: place adjacent ranks of the same PP stage on physically adjacent nodes where possible.

    3.2 Memory Optimization

    The memory budget breaks down into four parts: parameters, optimizer states, gradients, and activations. Mixed-precision training (BF16/FP16 compute with FP32 master weights) and sharded optimizer states are standard practice. On the activation side, selective recomputation is the answer: recompute only heavy operators such as attention, avoiding the roughly 30% extra compute cost that full recomputation brings.

    1. # Illustrative training configuration snippet
    2. precision: bf16
    3. optimizer_state_sharding: true
    4. recompute:
    5. strategy: selective
    6. layers: [attention]
    7. parallel:
    8. tp: 8
    9. pp: 4
    10. dp: 256

    4. Stability: The First-Order Problem in 10,000-GPU Training

    Once you pass a thousand GPUs, failures are not exceptions but the norm. Three capabilities must be built:

    1. Fast fault localization: use logging services and monitoring/alerting to converge hardware GPU loss, slow nodes (stragglers), and communication timeouts into searchable metric dimensions.
    2. High-frequency checkpointing: adopt asynchronous, tiered checkpoints that write state to object storage to shorten the recovery window.
    3. Automatic elastic fault tolerance: the training framework should support node removal and rescheduling; task-level restart is preferable to manual intervention.

    The evaluation criteria are straightforward: mean time between failures and single-recovery duration. Their product determines the effective compute discount of large-scale training.

    5. The Cost Perspective: Cost per Token Is the Ultimate Metric

    When institutions assess hardware efficiency, the truly comparable measure is training cost per million tokens. It consists of three parts: hardware amortization, energy consumption, and time wasted on failures and bubbles. The recommended optimization order is: fix stability first (reduce waste), then raise throughput (spread amortization), and only then discuss hardware unit price. Skipping the first two steps and comparing unit prices directly usually leads to distorted conclusions.

    To start trillion-parameter training on a domestic cluster, a practical sequence is: validate the parallelism strategy and numerical correctness at small scale, stress-test communication and throughput baselines at the thousand-GPU level, roll out gradually at the 10,000-GPU level while enabling fault tolerance and monitoring, and establish a cost dashboard centered on cost per token. General cloud capabilities such as the container platform, object storage, logging service, and monitoring/alerting offered by Baidu AI Cloud can serve as the infrastructure foundation for these engineering stages, helping teams focus their effort on training algorithms and tuning themselves.