Verification of Large Model Training Pipeline on Domestic AI Accelerators: Dual-Node 16-Card Configuration
Recently, a domestic AI accelerator platform successfully completed the adaptation and verification of a large language model training pipeline, running 400 training steps smoothly under a dual-node, 16-card configuration. This result indicates that the hardware environment possesses the foundational capabilities to support complex distributed training tasks, providing a starting point for future scale expansion, extended runtime, and performance optimization.
In large model training scenarios, being able to “launch a task” does not equate to a “fully functional training pipeline.” A truly valuable verification must cover the complete process: data reading, forward computation, backward propagation, gradient synchronization, parameter updates, checkpoint saving, and exception recovery. Recently, a domestic AI accelerator platform completed the adaptation verification of a large language model training pipeline, successfully running 400 training steps under a dual-node, 16-card configuration. This outcome demonstrates that the hardware environment is capable of handling complex distributed training tasks, serving as a starting point for subsequent scale expansion, extended runtime, and performance optimization.
1. Why Complete Training Pipeline Verification is Necessary
Large model training consists of multiple layers: the bottom layer includes accelerator drivers, runtimes, and compute libraries; the middle layer includes deep learning frameworks, distributed communication components, and mixed precision capabilities; the top layer includes model architecture, data pipelines, optimizers, and training scheduling logic. Compatibility issues in any layer can cause training tasks to fail.
Compared to single-card inference or simple operator testing, a complete training pipeline is significantly more complex, primarily in the following aspects:
More Complex Computation Graphs
Training requires not only forward computation but also saving intermediate activations, computing backward gradients, and updating parameters. Memory footprint, operator coverage, and execution sequence are stricter than in inference.Communication as a Critical Path
Multi-card training requires synchronizing gradients or parameters across devices. A dual-node environment also relies on inter-node networks for cross-host communication. Communication topology, bandwidth, latency, and stability directly impact training results.Data and Computation Must Collaborate
Insufficient data loading speed leaves compute devices idle; inconsistent sample splitting, batch organization, or random seed handling can cause abnormal training states across different processes.Long-Term Stability Cannot Be Ignored
Short-term success only proves basic functionality. As training steps increase, issues like memory fragmentation, communication timeouts, numerical overflow, and process desynchronization may emerge.
Therefore, 400 steps of training is better suited as a milestone acceptance test: it does not equate to final production-level performance conclusions, but it effectively proves that the main pipeline from task launch to parameter update is fully functional.
2. Basic Composition of the Dual-Node 16-Card Verification
This verification utilized a dual-node, 16-card configuration, meaning each host is equipped with eight accelerator cards, and both nodes participate in the same distributed training task. A typical logical structure is as follows:
Training Task├── Host 1│ ├── Accelerator Cards 0~7│ ├── Data Process│ └── Communication Process└── Host 2├── Accelerator Cards 0~7├── Data Process└── Communication Process
In practice, it is usually necessary to bind a training process to each card and differentiate execution units using global process ranks. Each process handles a portion of data and computation while participating in global gradient synchronization. The training process can be abstracted as:
Read Data↓Distribute to Training Processes↓Each Card Executes Forward Computation↓Each Card Executes Backward Computation↓Cross-Card and Cross-Node Gradient Synchronization↓Optimizer Updates Parameters↓Log and Proceed to Next Step
The dual-node environment adds network dependencies compared to a single-node multi-card setup. Beyond confirming the accelerator cards are available, it is necessary to check inter-node address connectivity, port availability, time synchronization, communication library loading, and software version consistency across nodes.
3. Key Points in Training Environment Preparation
1. Maintain Software Stack Consistency
In dual-node training, software version differences between hosts can cause subtle issues. For instance, if one host uses a different version of a runtime component, it might initialize successfully but fail during specific operator execution or communication phases. Therefore, it is recommended to unify the following:
- Operating system and kernel environment;
- Accelerator drivers and runtime components;
- Deep learning framework and its extension modules;
- Distributed communication components;
- Python and related dependencies;
- Model code, configuration files, and data processing scripts.
An environment list should be generated before task launch and compared between the two hosts. For containerized deployments, ensure that image digests match, not just the image tags.
2. Confirm Device Discovery and Topology
First, verify that each host correctly recognizes the eight accelerator cards and check if the device numbering is stable. Changes in device order can cause process binding errors or even result in some cards not participating in training.
Simultaneously, inspect the inter-card interconnect and inter-node network paths. Device topology affects communication efficiency for distributed training. While the functional verification phase may not require optimal performance, you should at least confirm that the communication path meets expectations to avoid transferring large amounts of gradients over low-speed links.
3. Verify Memory and Data Storage
Before training, estimate memory usage based on model size, sequence length, batch size, and parallelization strategy. It is recommended to start with a smaller batch size, gradually increase the load, and observe:
- Model parameter memory usage;
- Optimizer state memory usage;
- Activation memory usage;
- Communication buffer memory usage;
- Peak memory usage and its variation trend.
On the data side, ensure that training data is accessible by both hosts or properly sharded across nodes. Data reading anomalies will manifest as training processes waiting, batch time jitter, or even task interruption.
4. Model Adaptation Requires More Than Forward Computation
When migrating large models to a new compute platform, the training-specific path is the most easily overlooked. Inference running successfully does not guarantee that training will work. Adaptation work typically includes:
1. Check Core Operator Coverage
Focus on verifying common operators such as matrix multiplication, normalization, activation functions, attention computation, positional encoding, and loss computation. For some operators, the framework might automatically fall back to generic implementations. While functionally runnable, the performance and memory efficiency might be suboptimal.
2. Verify Backward Propagation
The backward path should be checked to ensure gradients are correctly generated, gradient tensor types are consistent, and no parameters are left out of the computation. You can run a few steps with small-scale inputs to check if gradients are all zeros, abnormally enlarged, or non-finite.
3. Handle Mixed Precision Issues
Large model training typically employs low-precision computation combined with high-precision accumulation to reduce memory footprint and improve throughput. During migration, confirm:
- Which operators use low precision;
- Which computations need to maintain high precision;
- Whether loss scaling is functioning normally;
- Whether updates are correctly skipped upon gradient overflow;
- Whether parameters and optimizer states are saved as expected.
If training proceeds normally for the first few dozen steps but then the loss becomes infinite or NaN, you often need to troubleshoot starting from the precision strategy, normalization computation, and gradient scaling mechanisms.
5. Distributed Communication is the Core of Dual-Node Training
16-card training must handle intra-card, intra-node, and inter-node communication simultaneously. A common data parallel workflow involves each card reading different samples, independently performing forward and backward computations, and then aggregating gradients through collective communication operations.
During the verification phase, it is recommended to monitor the following metrics:
- Whether communication initialization succeeds;
- Whether all processes can enter the same synchronization phase;
- Whether any process exits prematurely;
- Whether gradient synchronization time is abnormal;
- Whether communication timeouts or retries occur;
- Whether training step times jitter periodically.
A typical issue is “some processes finish computing while others are still waiting for data,” ultimately leading to a global synchronization block. Another issue is inter-node network connectivity, but the wrong network interface or route is used, causing a noticeable drop in communication performance.
Therefore, training logs should not only be viewed from the main process. Logs from all processes should be aggregated, recording the global rank, node ID, device ID, current training step, and the most recent communication status for each process. Only then can issues be quickly localized to a specific node or phase.
6. How to Judge Success for a 400-Step Run
Completing 400 steps is just a result; whether it is “fully functional” requires clear acceptance criteria. It is recommended to judge from at least four dimensions.
1. Task Integrity
All training processes can start normally, run continuously, and finish at step 400 without abnormal process exits, communication timeouts, or forced terminations.
2. Numerical Validity
The training loss should remain within a reasonable range, without persistent NaNs, infinities, or sudden explosions. Gradient statistics, learning rate changes, and parameter updates should also match training configuration expectations.
3. Resource Stability
Memory usage should not continuously grow, avoiding memory leaks or cache loss of control. Device utilization should match data supply and communication phases, without frequent prolonged idle times.
4. Checkpoint Recoverability
At least one model checkpoint should be saved and verified that it can be reloaded in an independent environment. Checkpoints should include not only model parameters but, as much as possible, optimizer states, learning rate scheduler states, random number states, and the current step. Otherwise, accurate resume training may not be possible after an interruption.
7. Moving from Functional Verification to Performance Optimization
After completing 400 steps on dual-node 16 cards, the next phase should not immediately scale up, but rather establish a repeatable performance baseline. It is recommended to record the following data:
- Average time per step;
- Steady-state throughput;
- Time taken by forward, backward, and communication respectively;
- Peak memory usage;
- Device utilization;
- Data loading wait time;
- Proportion of cross-node communication;
- Number of errors and retries during task execution.
Performance optimization should follow the principle of “localize first, adjust later.” If device utilization is low, it might be due to insufficient data supply; if communication takes up too much time, parallelization strategies or topology binding may need optimization; if memory is insufficient, batch size, sequence length, activation saving methods, and precision strategies should be re-evaluated.
Additionally, long-term stability testing should be conducted. 400 steps is suitable for verifying pipeline integrity, but production training often requires running for hours or even days. Long-run tests can reveal memory growth, network jitter, temperature changes, checkpoint anomalies, and occasional process disconnections that short tests easily miss.
8. Recommendation to Establish a Standardized Acceptance Process
To avoid relying on individual experience for every adaptation, the verification process can be solidified into a standard checklist:
- Complete hardware identification and device topology check;
- Complete software environment consistency check;
- Use small-scale tasks to verify single-card computation;
- Use single-node multi-card to verify intra-node communication;
- Use dual-node multi-card to verify cross-node communication;
- Scale up to dual-node 16-card;
- Run 400 steps and collect complete logs;
- Check loss, gradients, memory, and device utilization;
- Save and restore checkpoints;
- Conduct long-term stability and performance tests.
This process isolates problems by layers: the single-card phase uncovers operator and precision issues; the single-node multi-card phase uncovers device binding and intra-node communication issues; the dual-node phase focuses on network and cross-node synchronization issues. Compared to directly launching full-scale training, phased verification significantly reduces troubleshooting costs.
Overall, the significance of completing 400 training steps on a dual-node 16-card configuration is not just proving that a task can be launched, but demonstrating that the critical paths from model computation, distributed communication, data processing to parameter updates have formed a closed loop. To move towards production training, further work is needed, including precision alignment, performance baselining, long-term stability, fault recovery, and scale expansion. For any new compute platform, this verification methodology is highly universal and helps development teams assess whether the training environment is truly ready for engineering deployment in a quantifiable and reproducible manner.
