Adapting a Domestic AI Computing Platform to Train a 2.8T Multimodal Large Model: Validation Results
This article documents the successful adaptation and validation of a 2.8-trillion-parameter multimodal large model training pipeline on a domestic AI computing platform. It covers the key challenges of training massive multimodal models—architectural complexity, uneven memory pressure, and communication topology sensitivity—and details the solutions implemented, including FSDP2 sharding, the MCCL communication library, custom KDA operators, and Chunk Loss computation. Readers will learn the training configuration, measured loss convergence and memory usage results, and practical engineering lessons for scaling multimodal LLM training to larger clusters.
Background: Systemic Challenges in Multimodal Large Model Training
Large-scale multimodal models have evolved from single-modality text processing to joint image-text understanding and generation, with parameter counts jumping from hundreds of billions to the trillion scale. The training pipeline for such models is far more complex than that of pure text models, primarily in three dimensions:
- Architectural complexity: Take a certain open-source native multimodal model as an example. It has approximately 2.8 trillion total parameters and combines a hybrid attention mechanism (KDA and Gated DSA) with a Mixture of Experts (MoE) architecture, while also incorporating dynamic sparse retrieval and a vision encoder. The model contains a large number of non-uniform computation paths.
- Uneven memory pressure: The Vision Tower, cross-modal projection layers, and the language backbone differ significantly in memory footprint and compute density. Naive data parallelism or tensor parallelism strategies can easily lead to memory fragmentation and single-GPU OOM (Out of Memory) risks.
- Communication topology sensitivity: Multimodal training typically involves interleaved image-text inputs, with sequence lengths often reaching thousands or even tens of thousands of tokens. The traditional All-Reduce communication pattern can become a throughput bottleneck in cross-node scenarios. In particular, the dynamic All-to-All communication generated by expert routing places higher demands on network bandwidth and scheduling strategies.
Given these challenges, simply stacking hardware compute is no longer sufficient. Progress must be made in a coordinated manner across three layers: distributed training frameworks, memory management strategies, and communication optimization.
Adaptation Approach: Rebuilding Distributed Training for MoE and Multimodal Workloads
The core idea of this adaptation work was not to hard-code modifications for a specific model, but to build a reusable adaptation paradigm for multimodal training. The overall solution retains the industry-standard NeMo AutoModel native pipeline, ensuring compatibility with mainstream training ecosystems, while focusing optimization efforts on the following four key modules.
1. FSDP2: Breaking Trillion-Parameter Models into Manageable Pieces
At the 2.8-trillion-parameter scale, no single GPU’s memory can hold a complete model replica. The technical team adopted Fully Sharded Data Parallelism (FSDP2), sharding model parameters, gradients, and optimizer states (such as Adam’s first and second moments) across all participating GPUs. Compared with earlier FSDP versions, FSDP2 offers finer sharding granularity, supports fine-grained communication and compute overlap scheduling at the parameter-subset level, and significantly reduces peak memory usage.
From an engineering perspective, the key to FSDP2 lies in its “prefetch” mechanism—before backpropagation computes the gradients for the current layer, a background thread prefetches the parameter shards for the next layer. This effectively hides communication latency and keeps compute units as busy as possible.
2. MCCL Communication Library: Resolving Dynamic Routing Communication Bottlenecks
Expert routing (Top-8 Router) in MoE architectures produces complex token distribution patterns—tokens are dynamically assigned to different experts based on routing weights, causing the volume of cross-GPU communication to fluctuate continuously during training. Fixed communication topologies struggle to accommodate this dynamism.
To address this, the adaptation introduces the MCCL communication library as the infrastructure for cross-GPU and cross-node communication. MCCL applies low-level optimizations for dynamic sparse communication, adjusting communication paths in real time based on routing results and providing efficient gradient aggregation algorithms that minimize synchronization overhead while ensuring communication correctness.
3. High-Performance KDA Operators and Chunk Loss Computation
Beyond distributed strategies, per-GPU operator efficiency also matters. The KDA hybrid attention mechanism used by this model involves intensive sparse retrieval computation, and a generic matrix multiplication implementation would be far less efficient. The technical team developed dedicated high-performance operators tailored to KDA’s computation patterns—using instruction-level pipeline optimization and register reuse to significantly improve compute density in the sparse attention portion.
Additionally, to handle memory pressure in scenarios with 1-million-token ultra-long contexts, the system implements Chunk Loss computation. Standard loss computation requires maintaining the full prediction logits matrix, which alone can exceed memory limits for long sequences. The chunking strategy splits the sequence into equal-length segments, computes cross-entropy loss chunk by chunk, and accumulates gradients. This is mathematically equivalent to global computation, but peak memory demand decreases linearly with the number of chunks.
4. Ensuring the Vision Encoder Is Actually Trained
In multimodal training, the vision tower and cross-modal projection modules are often marginalized—some implementations feed vision outputs into the language backbone as static features, with no substantive updates to the vision parameters. This adaptation specifically verified gradient flow in the vision branch: over 400 training steps, the team checked gradient values in the first and last layers of the vision tower, the image embedding layer, and the cross-modal projection module, confirming that all produced non-zero gradients and parameter updates. This shows the vision encoder genuinely participates in end-to-end optimization rather than serving merely as a data preprocessing pipeline.
Measured Results and Convergence
The validation test was conducted on a dual-node, 16-GPU setup with the following configuration:
- Hardware environment: 2 AI computing servers, each with 8 flagship AI training-and-inference accelerator cards, with per-card memory sufficient to hold the sharded model states;
- Model slice configuration: A 13-layer language backbone with 16 routed experts (Top-8 routing), retaining the full 27-layer vision tower;
- Dataset: The MedPix-VQA image-text question answering dataset, with a global batch size of 16 and sequence length of 1024;
- Training steps: 16 training processes completed 400 consecutive optimizer updates.
Training loss convergence:
Average loss dropped from 8.9365 (steps 21–70) to 2.1802 over the final 50 steps—a reduction of nearly 76%, indicating the model entered a rapid convergence channel early in training. Validation loss also decreased from 6.5297 at step 100 to 4.6873 at step 400, ruling out overfitting risk.
Memory usage:
The sampled peak memory usage was 44.80 GiB. Under the 16-GPU sharding strategy, this is well below the per-card physical memory limit, demonstrating that FSDP2 effectively controlled memory growth and left headroom for scaling to larger batches or longer sequences.
Stability verification:
During the 400 consecutive training steps, no numerical overflow (NaN/Inf) or abnormal process interruptions occurred, and all 16 training processes remained synchronized and healthy. This validates that the complete pipeline—from data loading and forward computation to gradient synchronization and parameter updates—is reliable and reproducible in engineering terms.
It should be emphasized that this validation used a randomly initialized, trimmed configuration (not a full-scale 2.8-trillion-parameter pretraining run). Its purpose was to verify the functional correctness, stability, and performance baseline of the training pipeline on the hardware and software stack—not to pursue final model accuracy.
Engineering Lessons: Scaling from 400 Steps to Large-Scale Training
Based on this adaptation work, three reusable lessons can be distilled for similar multimodal large model training efforts:
- Sharding granularity determines the memory ceiling: For models at the tens-of-billions scale and above, coarse-grained sharding (sharding by Transformer layer) is no longer sufficient. FSDP2’s parameter-subset sharding approach keeps the memory “waterline” within a healthy range more precisely.
- Dynamic communication requires hardware-software co-design: MoE’s All-to-All communication places extreme demands on topology awareness. Upper-level framework scheduling alone cannot achieve peak bandwidth; the underlying communication library and high-level routing modules must be designed jointly.
- Vision branch convergence requires active verification: “The vision tower never updates” is a common hidden problem in multimodal training. We recommend periodically checking gradient norms of non-language modules early in training to ensure multimodal alignment is genuinely happening—not just going through the motions at the data-flow level.
Of the four optimizations—FSDP2 with expert parallelism, parameter prefetching with gradient communication scheduling, high-performance KDA operators, and Chunk Loss computation—Chunk Loss was enabled in this 400-step test, while the other three are ready for integration and can support larger-scale training cluster configurations.
Conclusion: Multimodal Training Enters the “Engineering Refinement” Era
A single 400-step validation is limited in scale, but its significance lies in establishing a complete technical chain from “multimodal architecture to distributed framework to low-level hardware acceleration.” As model parameters reach the trillion scale and context windows reach the million-token scale, any performance bottleneck in any layer can be amplified without limit. This adaptation practice demonstrates that, through FSDP2-based fine-grained memory management, MCCL dynamic communication scheduling, and deep optimization of custom operators, the domestic AI computing platform has built the foundational capability to support frontier-level multimodal model training. Validating the feasibility of this path lays a solid foundation for subsequent full-parameter pretraining and linear scaling tests on larger clusters.
