Running End-to-End LLM Training on Domestic AI Chips: A Two-Node, 16-Card Practice

    This article explains why validating a complete training pipeline matters for domestic AI chips, and walks through a two-node, 16-card verification of LLM training. It covers model onboarding and compute graph adaptation, parallel partitioning strategies combining tensor and data parallelism, communication efficiency optimization, and the key metrics for stability validation—offering practical insights for teams evaluating domestic AI compute platforms.

    1. Background: Why “Running the Full Training Pipeline” Matters

    In large model development, the real challenge is not whether a chip can compute, but whether it can compute continuously, stably, and efficiently. A complete training pipeline involves model structure parsing, distributed parallel partitioning, communication topology optimization, operator precision alignment, checkpointing, and fault recovery. A failure in any of these stages can cause training interruptions, convergence anomalies, or severe efficiency losses.

    For domestic AI chips, the ability to run an end-to-end training pipeline on real large models is the core benchmark of software stack maturity. Recently, a team used two machines with sixteen domestic accelerator cards to validate the training workflow of a mainstream open-source LLM, completing several hundred training steps with a normally converging loss curve. Although the scale was modest, the significance lies in proving end-to-end technical feasibility—from framework adaptation and operator coverage to multi-node interconnect.

    2. Key Technical Stages of the Training Pipeline

    2.1 Model Onboarding and Compute Graph Adaptation

    Large models typically include Transformer attention mechanisms, feed-forward networks, RMSNorm normalization, and various routing and sampling logic. The training framework must map all of these structures onto the underlying hardware:

    • Operator coverage: High-frequency operators—matrix multiplication, rotary position embeddings, FlashAttention-style fused operators, and grouped quantization—must have efficient implementations;
    • Precision alignment: Mixed-precision training (e.g., BF16 compute with FP32 master weights) must be validated for numerical consistency on domestic cards to prevent accumulated errors from causing divergence;
    • Dynamic logic support: Variable-length sequences and gradient checkpointing require the compiler to handle dynamic graphs and recomputation effectively.

    2.2 Parallel Partitioning on Two Nodes with 16 Cards

    At the sixteen-card scale, the typical approach combines data parallelism and tensor parallelism:

    • Within each eight-card node, tensor parallelism is used, leveraging high-bandwidth intra-node interconnects (such as PCIe Switch or custom high-speed buses) to reduce communication overhead;
    • Across nodes, data parallelism is applied, with gradient synchronization over an RDMA network;
    • Pipeline parallelism can optionally be introduced to split the model by layers, further reducing per-card memory pressure.

    An illustrative initialization configuration looks like this:

    1. # Pseudocode: distributed training initialization
    2. init_distributed(world_size=16, pp=2, tp=4, dp=2)
    3. model = build_model(tensor_parallel=tp, pipeline_parallel=pp)
    4. optimizer = build_optimizer(model, precision="bf16")
    5. for step in range(max_steps):
    6. loss = train_step(model, batch)
    7. if step % save_interval == 0:
    8. save_checkpoint(model, optimizer, step)

    2.3 Communication Efficiency Optimization

    Cross-node communication is the bottleneck for scaling efficiency. In practice, attention should be paid to:

    • Gradient AllReduce bucketing and compute-communication overlap;
    • The maturity of the collective communication library’s adaptation to the domestic interconnect protocol;
    • Topology-aware communication scheduling to reduce cross-switch traffic.

    Over several hundred validation steps, communication stability is typically assessed by observing the variance in per-step time (step time).

    3. Stability Validation: Metrics More Important Than “It Runs”

    A successful pipeline validation usually requires confirming the following:

    1. Loss convergence: Compared against a reference implementation, the loss curve follows a consistent trend with no abnormal spikes;
    2. Throughput stability: Throughput fluctuation over several hundred consecutive steps stays within a reasonable range, with no noticeable performance degradation;
    3. Memory and power consumption: No memory leaks or abnormal card temperatures during extended runs;
    4. Fault tolerance: Periodic checkpoint saving is supported, and training can resume from a checkpoint after a simulated failure without corrupting the training state;
    5. Numerical correctness: Sampled weight gradients show relative errors within an acceptable threshold compared to the reference implementation.

    4. Implications for the Industry

    • The software stack is the lifeline of domestic compute: Peak hardware FLOPS are only the starting point. Operator library completeness, compiler optimization capability, and framework ecosystem compatibility determine the actual usable compute;
    • There is still a gap between small-scale validation and large-scale training: Moving from two nodes with sixteen cards to thousand-card clusters brings qualitative changes in communication patterns, failure rates, and scheduling complexity, requiring progressive scaling validation;
    • Cloud platform capabilities can accelerate adoption: General-purpose cloud capabilities such as container platforms, object storage, monitoring and alerting, and log services can significantly reduce the cost of setting up and operating training environments.

    5. Conclusion

    Validating several hundred training steps on two nodes with sixteen cards marks an important step for domestic AI chips moving from “usable” to “practical.” As software stacks continue to iterate and parallel strategies keep improving, domestic compute platforms are expected to take on a core role in larger-scale model training. For developers and enterprises, paying attention to the details of such pipeline-level validations is far more valuable than simply comparing specification sheets.