Practical LLM Training Adaptation on Domestic GPUs: A Stable 400-Step Run on 16 Accelerators
This article analyzes a reported 400-step continuous training adaptation for a nearly 3-trillion-parameter open-source LLM on 16 domestic AI accelerators. It clarifies the difference between inference operator validation, training adaptation, and base-model pretraining, explains FSDP-based sharded data parallelism, and summarizes the stability checks and engineering capabilities required for reliable multi-node training.
1. What the 400-Step Run Demonstrates
A domestic GPU vendor recently completed a training adaptation for a nearly 3-trillion-parameter open-source flagship model. The adaptation was performed on two nodes with 16 flagship AI training and inference accelerator cards. Sixteen training processes jointly trained across nodes, executed 400 consecutive optimizer updates, and kept the loss and gradient norm finite throughout. There was no numerical overflow or abnormal interruption.
The 400 steps represent 400 “effective parameter updates.” Gradient accumulation, data loading, and related processes may correspond to more micro-batch forward and backward computations.
From an engineering perspective, this validation answers two questions:
- Can the pipeline work end to end? Can the model load, shard, perform forward and backward passes, synchronize gradients, and update parameters on domestic accelerators?
- Can the pipeline remain stable? After 400 consecutive iterations, do numerical values stay stable and do processes avoid unexpected exits?
The second question is often more informative than the first. A successful single step can be achieved through manual troubleshooting, but hundreds of stable steps require coordinated support from the framework, communication libraries, operator libraries, and hardware.
2. Clarifying the Concepts: Training Adaptation Is Not Base-Model Pretraining
Many readers interpret “a model has been adapted to a domestic chip” as “the model was pretrained on that chip.” This is a common misunderstanding.
2.1 Three easily confused levels
| Level | Core goal | Typical validation method | Typical scale |
|---|---|---|---|
| Inference operator validation | Verify correctness and performance of one or a few operators | Small-batch forward computation compared with reference results | Single GPU or small-scale cluster |
| Training adaptation | Verify correctness and stable operation of the full training pipeline | Multi-GPU or multi-node training over multiple steps, with loss and gradient monitoring | A few GPUs to tens of GPUs |
| Base-model pretraining | Train a complete base model from random initialization | Long-duration training with a complete data mixture and final quality evaluation | Large-scale clusters and long training runs |
A recent technical report from a large-model team compared fine-grained expert parallelism approaches on both NPU and mainstream GPU routes. The industry generally considers this to be inference-operator-level validation. The team did not disclose the original compute used for base-model pretraining. This is not necessarily concealment; technical reports typically cover only what the authors actually validated.
2.2 Why training adaptation is harder than inference adaptation
Inference mainly requires forward computation. Training must perform both forward and backward propagation while maintaining updatable model state, which significantly increases complexity:
- Higher memory overhead: In addition to parameters and activations, gradients and optimizer states must be stored. For the common mixed-precision setup with “parameters + gradients + Adam optimizer states,” each parameter typically requires about 16 bytes. Parameters and gradients take 2 bytes each, while FP32 master weights and the first and second Adam moments take 4 bytes each. Actual numbers may vary by implementation, but this provides a rough memory estimate.
- Different operator requirements: Backward operators, gradient reduction, mixed-precision handling, and optimizer updates are all absent from inference.
- More complex communication patterns: In data parallelism, each training step usually involves one gradient reduction and one parameter broadcast. In sharded schemes, reduce-scatter and all-gather operations are used instead. Communication volume is approximately the model parameter count multiplied by bytes per parameter, and compute-communication overlap directly affects overall efficiency.
- Stricter numerical constraints: Learning-rate warmup, loss scaling, gradient clipping, and weight decay are coupled. A single misconfiguration can cause the loss to diverge after tens of steps.
Therefore, completing training adaptation means the platform has moved beyond inference validation and has the basic capability to support training workloads. However, it still does not prove that a base model was pretrained on that platform.
3. Core Path Breakdown: Native FSDP Training
The adaptation used a “native” sharded data parallel training path, specifically Fully Sharded Data Parallel (FSDP).
“Native” has two meanings:
- The training capability is built on the hardware vendor’s own software stack rather than relying on adaptation layers from another ecosystem.
- Sharding, communication, and computation scheduling are controlled by the vendor, making step-by-step tuning easier.
3.1 Core idea of sharded data parallelism
In traditional data parallelism, every GPU holds a complete model replica and synchronizes gradients only at the end of each step. Sharded data parallelism partitions parameters, gradients, and optimizer states across GPUs along the data-parallel dimension:
- Forward pass: Before computing a layer, the required complete parameters are gathered temporarily and released immediately after computation.
- Backward pass: Each GPU computes its local gradient shard, then uses reduce-scatter to reduce gradients and distribute them to the GPUs that own the corresponding shards.
- Parameter update: Each GPU updates only the shard it owns. Parameters are gathered again on demand in the next iteration.
With this design, per-GPU resident memory is approximately inversely proportional to the data-parallel degree. More accelerators can therefore translate into more usable memory.
3.2 Combining multiple parallelism strategies
| Parallelism strategy | What is split | Main communication pattern | Typical scenario |
|---|---|---|---|
| Data parallel / sharded data parallel | Training samples; sharding also splits parameters, gradients, and optimizer states | Gradient reduction, parameter gathering | When the model fits on one GPU and throughput scaling is the goal |
| Tensor parallelism | Weight matrices within a layer | Intra-layer collective communication | When a single layer is too large to fit on one GPU |
| Pipeline parallelism | Model layers are divided into stages | Point-to-point transfer between adjacent stages | When the model has many layers and needs cross-node expansion |
| Sequence parallelism | Sequence dimension | Used together with adjacent strategies | Long-context training with high activation memory pressure |
| Expert parallelism | Experts in a mixture-of-experts model | Sample routing and expert result aggregation | Sparse expert architectures |
For petabyte-scale large models, these strategies often need to be combined, commonly referred to as “3D/4D parallelism.” The adaptation team must choose splitting ratios across dimensions based on model structure and cluster topology. This is fundamentally different from tensor or expert parallelism in inference: inference focuses on latency and throughput, while training must also handle gradients, optimizer states, and long-term stability.
3.3 Simplified training loop
# Illustrative pseudocode: shows the general logic of sharded data parallel training.# It does not correspond to any specific product API.for step, batch in enumerate(dataloader, start=1):# 1. Forward: gather current-layer parameters on demand, then release themloss = model(batch)# 2. Backward: each GPU computes its local gradient shardloss.backward()# 3. Gradient synchronization: reduce-scatter places gradients in their shardssync_gradients(model)# 4. Gradient clipping: global norm must be reduced across all GPUs and shards.# This is an error-prone point in sharded training.grad_norm = global_grad_norm(model)clip_gradients(model, grad_norm, max_norm=1.0)# 5. Each GPU updates its parameter shard and corresponding optimizer stateoptimizer.step()optimizer.zero_grad(set_to_none=True)# 6. Log loss, gradient norm, and other metrics for stability assessmentlog_metrics(step, loss, grad_norm)
In a sharded setup, “gradient synchronization is complete” can easily be misjudged. Each shard corresponds to only a slice of the parameter. If clipping is performed before gradient reduction, each GPU sees only a local gradient norm. The clipping threshold becomes distorted, and the global norm may be underestimated. Such issues may not appear in a single-step run, but they can trigger numerical anomalies after hundreds of steps.
4. Key Pipeline: From Model Loading to Gradient Synchronization
The vendor’s “complete training pipeline from model loading, sharding, and scheduling to gradient synchronization” can be understood in four parts.
4.1 Model loading
A trillion-parameter model cannot be fully loaded into a single GPU’s memory. Common approaches include:
- Saving weights in sharded format, so each GPU loads only the portion it needs.
- Using memory mapping to stream-load layer by layer.
- Using a meta device for lazy allocation to avoid memory spikes during loading.
Regardless of the method, the shard mapping must be correct, and format conversion for tensor-parallel weights must be handled properly when saving and loading.
4.2 Sharding and scheduling
The framework needs to maintain a shard mapping table for each parameter. It records shard ownership, whether the shard is currently gathered, and when it can be released, and uses this information to schedule communication. Common optimizations include:
- Compute-communication overlap: Gather parameters for later layers while the backward pass is still running.
- Bucket merging: Combine small collective communication operations into larger batches to reduce call count and launch overhead.
- Proactive prefetching: Predict the next parameters to be gathered based on computation order.
4.3 Gradient synchronization
In distributed training, gradients must be reduced through collective communication. Common primitives include:
- All-reduce: Synchronizes complete gradients in data parallel scenarios.
- Reduce-scatter: First sums gradients, then distributes them to the GPUs that own the corresponding shards.
- All-gather: Gathers parameters during the forward pass and gathers gradients during the backward pass.
These primitives can have different numerical behavior. Different reduction orders may introduce small floating-point differences. In fast training scenarios, keeping FP32 master weights and using FP32 accumulation for key reductions are common ways to control error.
4.4 Optimizer updates
Optimizer states are also stored in shards. Each GPU only updates its own shard, reads the corresponding gradient shard, and performs momentum updates, second-moment updates, and weight decay. If sharded checkpoints are used, each GPU can restore its shard according to the mapping table when resuming training, without requiring the entire cluster to reload the full model.
5. Stability Validation: How to Judge 400 Continuous Steps
5.1 Why “continuous” matters
There is a clear gap between “can run one step” and “can train stably”:
- Some numerical issues only appear under specific data distributions, such as abnormal values in a few samples being amplified into gradient spikes.
- Some issues appear only after accumulation, such as repeated loss-range rescaling in mixed precision or continuous memory fragmentation.
- Some issues are related to optimizer state, such as abnormal growth of momentum terms.
Hundreds of consecutive updates can cover typical scenarios such as learning-rate warmup, data order changes, and periodic checkpoint saving. This is a basic test of numerical stability.
5.2 Stability criteria: finite loss and gradient norms
“Finite throughout” means the loss and gradient norm at every step are neither NaN nor positive or negative infinity. For example, in FP16 mixed precision, the maximum representable value is about 65504. A single gradient spike can trigger overflow and cause an optimizer update to be skipped.
Common stability criteria include:
- The loss remains finite and its overall trend matches expectations.
- The gradient norm remains finite, without continuous growth or collapse toward zero.
- The number of skipped steps is low, meaning few updates are skipped due to overflow or anomalies.
- Optimizer state, including momentum, second moments, and loss scale factor, remains normal.
- Processes do not exit abnormally, and synchronization does not time out.
- Memory usage remains stable, with no continuous leakage.
5.3 Stability monitoring metrics
| Metric | Observation method | Anomaly signal |
|---|---|---|
| Loss | Record each step and sliding average | Spikes, NaN/Inf, persistent non-decrease |
| Gradient norm | Compute global norm every step; record before and after clipping | Sudden increase, sudden drop, periodic spikes |
| Loss scale factor | Record changes during mixed-precision training | Frequent rollback, consecutive skipped steps |
| Memory usage | Record peak usage and fragmentation per GPU | Continuous growth with steps |
| Collective communication time | Record waiting time for synchronization and gathering | Sudden step-time increase, straggler |
| Optimizer state norm | Periodically sample momentum and second moments | Deviation from reference values |
6. From “Can Train” to “Ready to Train”: Three Engineering Layers
The vendor claims to have formed a mature engineering system. This can be broken down into three layers.
6.1 Operator layer: from “runs” to “runs correctly”
- Coverage: Supporting trillion-parameter training requires more than general matrix computation. It also involves normalization, attention variants, mixture-of-experts routing, and optimizer updates.
- Consistency: Key operators must be compared with industry reference implementations, often called “golden references.” Errors must be within acceptable ranges.
- Performance: Operators must be tuned for the accelerator architecture. Otherwise, even if training is correct, each step may take several times longer than expected.
6.2 Parallelism and communication layer
A mature system needs to:
- Support flexible combinations of multiple parallelism strategies.
- Ensure collective communication libraries work well with high-speed interconnects.
- Provide topology awareness to minimize cross-node communication.
- Quickly localize single-GPU or single-link failures.
6.3 Toolchain layer
From model onboarding to training execution, a standard set of operations is usually required. This is key to turning “can train” into “ready to train out of the box”:
- Automatic model structure conversion and splitting.
- One-click distributed launch and environment checks.
- Training metric visualization and anomaly alerts.
- Checkpoint recovery and failure self-healing.
- Performance profiling and bottleneck localization.
“Ready to train out of the box” means users do not need to manually adapt each item. With a model and dataset, users can start training with a unified configuration, and the system can handle splitting, scheduling, synchronization, and monitoring.
7. Practical Validation: From Single-Model Testing to Multi-Scenario Deployment
Single-model adaptation verifies whether training is possible. Multi-scenario training with different model structures verifies whether it is stable and general.
Public information indicates that the vendor has reported results for training domestic models on its chips in several areas:
- Scientific computing foundation model: A 236-billion-parameter scientific foundation model completed training from scratch. Training from zero covers initialization, data onboarding, optimizer warmup, and convergence, making it a complete test of the training pipeline.
- Physical-world model: The vendor supported full-stack native training for a 5D physical-world model. Such models have high requirements for spatiotemporal consistency and multimodal data, with more complex compute and communication patterns.
- Embodied AI model: With research institutions, the vendor completed full-process training of an embodied brain model. Such models need to integrate vision, language, and action, and organizing the training data is itself an engineering challenge.
- Trillion-parameter large model: The vendor is working with partners to advance trillion-parameter-scale model training.
As model scale increases from tens of billions to hundreds of billions and then to trillions, parallelism strategies, communication overhead, and fault tolerance must be redesigned at each level. Multi-scenario deployment suggests these capabilities are reusable engineering capabilities rather than one-off results.
8. Practical Lessons for Training Adaptation
- Clarify the validation goal: First determine whether the goal is inference adaptation, training adaptation, or full pretraining. Avoid inferring long-term behavior from a single-step result.
- Establish a baseline comparison: Under the same data and hyperparameters, align loss curves and gradient norms with industry reference training results. This is one of the most direct ways to assess adaptation quality.
- Validate scale in stages: Expand from single GPU to single-node multi-GPU and then to multi-node multi-GPU. At each stage, run enough optimizer update steps rather than only validating one forward and backward pass.
- Include stability metrics in routine monitoring: Loss, gradient norm, skipped steps, memory trends, and collective communication time should be collected routinely, similar to latency metrics in inference services.
- Keep reproducible configurations: Fix parallelism strategy, random seeds, and data order to support debugging and result comparison.
- Build an operator regression mechanism: After every software stack or driver upgrade, rerun accuracy tests for key operators to prevent upgrade-induced regressions.
9. Conclusion
The value of the reported “two-node, 16-card, 400-step stable run” is not the number itself. It shows that the software stack of a domestic accelerator can support the full training pipeline of a trillion-parameter-scale model and maintain stability over a continuous period.
For the industry, clearer technical standards are needed:
- Inference adaptation answers whether the model can be used.
- Training adaptation answers whether the model can be trained.
- Base-model pretraining answers whether the model is trained well.
These are progressive engineering steps. Conclusions from one level should not be used to replace conclusions from another.
For developers, the more important question is not a single adaptation result, but whether operator coverage, multi-GPU efficiency, and automated toolchains can continue to accumulate. Only when these capabilities become standardized processes can frontier large models steadily move from “can train” to “ready to train out of the box” on domestic full-function GPUs.
