Tags

c 2 c++ 2 BDB 7 database 15 transaction 4 groovy 1 DSL 1 Spring MVC 5 安全 1 操作系统 1 编程语言 1 Java 29 shell 6 linux 7 productivity 3 jekyll 4 博客 3 spring 15 quartz 1 junit 2 ant 2 maven 6 spring-security 1 tomcat 3 Debug 1 Productivity 1 JVM 3 mysql 8 aop 1 proxy 1 cglib 1 Mina 1 NIO 1 网络编程 1 BTrace 1 rpc 1 scala 1 architecture 1 jvm 1 classloader 1 zookeeper 2 分布式锁 1 HTTP 1 缓存 3 log4j 3 redis 7 消息队列 4 nginx 7 elasticsearch 12 移动互联网 1 uuid 1 DNS 1 生活 4 工作 1 分享 1 Tomcat 1 性能优化 3 主从复制 1 高可用 2 分布式 4 kafka 3 广告 1 git 3 高并发 3 过载保护 1 图数据库 8 neo4j 5 存储 1 aerospike 3 Titan 1 Bloom Filter 1 markdown 1 kramdown 1 瑜伽 1 呼吸 1 生活的艺术 1 antlr 1 parser 1 感恩节 1 puppeteer 1 chrome-headless 1 crawler 1 cluster 2 监控 1 Kubernetes 11 Docker 1 微服务 2 架构 3 AI 158 spark 6 hadoop 2 设计模式 1 RDD 1 shuffle 1 data skew 1 敏捷 3 gitlab 1 机器学习 2 特征工程 1 Parameter Server 1 埋点 1 TDD 1 Python 15 AI-Infra 97 LLM 64 Agent 4 Roadmap 4 Math 9 PyTorch 23 C++ 9 Machine Learning 8 Deep Learning 7 Transformer 14 Pretraining 5 Post-Training 9 RLHF 7 Reasoning 1 Distillation 1 Evaluation 3 Methodology 1 Inference 7 Quantization 3 Decoding 1 Speculative Decoding 1 KV Cache 1 Long Context 1 Pruning 1 Small Models 1 Multimodal 8 Diffusion 3 Vision 1 Contrastive Learning 1 VLM 2 Architecture 1 Training 1 Speech 1 Audio 1 Generative Models 1 Text-to-Image 1 Video Generation 1 Image Generation 1 Unified Models 1 CUDA 13 Triton 11 GPU 29 NCCL 10 RDMA 10 Megatron 11 DeepSpeed 6 Distributed Training 14 torchtitan 7 MFU 2 Parallelism 1 Checkpoint 1 torchft 1 Fault Tolerance 1 Data Pipeline 1 Observability 3 Blog 2 GitHub 1 大模型推理 15 RL 9 verl 9 vLLM 12 GRPO 2 Ray 2 FSDP 2 AReaL 1 Source Code 1 MLOps 2 DRA 1 Kueue 1 Volcano 1 Scheduling 1 MIG 1 HAMi 1 Demo 1 Slides 1 Storage 1 KServe 1 llm-d 2 Gateway API 1 Multi-Tenancy 1 FinOps 1 Open Source 3
操作系统

进程VS线程


网络编程

mina学习笔记


过载保护

过载保护


Kubernetes

AI 平台工程(08):可观测、成本与 FinOps

Observability, Cost and FinOps: from DCGM to the Token Bill


AI 平台工程(07):模型网关与多租户——路由、配额与灰度

The Model Gateway: KV-Aware Routing, Multi-Tenancy, Quotas and Canaries


AI 平台工程(06):Serving 平台——从 InferenceService 到 llm-d

Serving Platforms: KServe, Triton, Ray Serve, LeaderWorkerSet and llm-d


AI 平台工程(05):网络与存储——RDMA 进容器、并行文件系统与 checkpoint I/O

Networking and Storage: RDMA in Containers, Parallel File Systems and Checkpoint I/O


AI 平台工程(04):GPU 共享与切分——MIG、时间片、MPS 与 HAMi

Sharing and Partitioning GPUs: MIG, Time-Slicing, MPS and HAMi


AI 平台工程(03):AI 任务调度——gang scheduling、队列与拓扑感知

Scheduling AI Jobs: Gang Scheduling, Queues, Quotas and Topology Awareness


AI 平台工程(02):容器里的 GPU——驱动、CUDA、device plugin 与镜像

GPUs in Containers: Driver, CUDA, Device Plugin, DRA and Images


AI 平台工程(01):引擎的需求清单与平台的整体架构

What Engines Demand from the Platform, and the Platform's Two Layers


AI 平台工程:资源层与交付层(总纲)

AI Platform Engineering: the Resource Layer and the Delivery Layer


RL 后训练基础设施(06):Agentic rollout——多轮、工具、沙箱与环境服务

Agentic Rollout: Multi-Turn Trajectories, Tools, Sandboxes and Environment Services


kubernetes初体验


AI

AI-Infra 开源贡献指南(02):找到切入点——从 issue、RFC 到性能回归

Finding Your Entry Point: Issues, RFCs, Roadmaps, CI Failures and Regressions


AI-Infra 开源贡献指南(01):读懂一个百万行的代码库

Reading a Million-Line Codebase: Maps, Entry Points, Symbols, Tests and History


AI-Infra 开源贡献指南(总纲)

A Guide to Contributing to AI-Infra Open Source Projects


AI 平台工程(08):可观测、成本与 FinOps

Observability, Cost and FinOps: from DCGM to the Token Bill


AI 平台工程(07):模型网关与多租户——路由、配额与灰度

The Model Gateway: KV-Aware Routing, Multi-Tenancy, Quotas and Canaries


AI 平台工程(06):Serving 平台——从 InferenceService 到 llm-d

Serving Platforms: KServe, Triton, Ray Serve, LeaderWorkerSet and llm-d


AI 平台工程(05):网络与存储——RDMA 进容器、并行文件系统与 checkpoint I/O

Networking and Storage: RDMA in Containers, Parallel File Systems and Checkpoint I/O


AI 平台工程(04):GPU 共享与切分——MIG、时间片、MPS 与 HAMi

Sharing and Partitioning GPUs: MIG, Time-Slicing, MPS and HAMi


AI 平台工程(03):AI 任务调度——gang scheduling、队列与拓扑感知

Scheduling AI Jobs: Gang Scheduling, Queues, Quotas and Topology Awareness


AI 平台工程(02):容器里的 GPU——驱动、CUDA、device plugin 与镜像

GPUs in Containers: Driver, CUDA, Device Plugin, DRA and Images


AI 平台工程(01):引擎的需求清单与平台的整体架构

What Engines Demand from the Platform, and the Platform's Two Layers


AI 平台工程:资源层与交付层(总纲)

AI Platform Engineering: the Resource Layer and the Delivery Layer


RL 后训练基础设施(08):配置、可观测与排障——从一张卡的比例到一条 hang 的排查

Configuration, Observability and Troubleshooting for RL Post-Training Systems


RL 后训练基础设施(07):verl 源码导读——从一个 GRPO 配置追到每个 worker

Reading verl: From One GRPO Config to Every Worker


RL 后训练基础设施(06):Agentic rollout——多轮、工具、沙箱与环境服务

Agentic Rollout: Multi-Turn Trajectories, Tools, Sandboxes and Environment Services


RL 后训练基础设施(05):异步与 off-policy——把同步的墙拆掉之后要补什么

Asynchrony and Off-Policy: What You Owe After Tearing Down the Synchronization Wall


RL 后训练基础设施(04):权重同步——从训练分片到推理分片

Weight Synchronization: From Training Shards to Inference Shards


RL 后训练基础设施(03):共置——训练器与推理引擎在同一组 GPU 上共存

Colocation: Handing GPU Memory Back and Forth Between Trainer and Rollout Engine


RL 后训练基础设施(02):系统形态——共置、分离与异步

RL System Topologies: Colocated, Disaggregated and Asynchronous


RL 后训练基础设施(01):负载画像——一步 RL 里发生什么

Anatomy of an RL Step: Rollout, Reward and Train


RL 后训练基础设施:rollout 与训练如何共享一组 GPU(总纲)

RL Post-Training Infrastructure: How Rollout and Training Share the Same GPUs


大模型推理系统揭秘(14):回到源码:一次请求在 vLLM 内部的真实旅程


大模型推理系统揭秘(13):Serving Infra 的下一站:从模型执行器到分布式智能操作系统


大模型推理系统揭秘(12):PD 分离:从资源混部走向计算解耦


大模型推理系统揭秘(11):硬件解耦:如何不让芯片差异污染 Serving 核心?


大模型推理系统揭秘(10):请求形态的扩展:multi-LoRA 与多模态


大模型推理系统揭秘(09):模型适配:如何跟上变化极快的模型世界?


大模型推理系统揭秘(08):Multi-GPU:一张卡不够时如何扩展?


大模型推理系统揭秘(07):解码的扩展:采样、投机解码与结构化输出


大模型推理系统揭秘(06):GPU 执行:如何让每个 Token 算得更快?


大模型推理系统揭秘(05):KV Cache:LLM Serving 的第一号内存问题


大模型推理系统揭秘(04):Scheduler:GPU 这一轮到底给谁用?


大模型推理系统揭秘(03):鸟瞰 vLLM:一个请求如何穿过整个推理系统?


大模型推理系统揭秘(02):如何衡量一个 LLM Serving 系统?


大模型推理系统揭秘(01):为什么 LLM Serving 比传统 DL 推理难?


大模型推理系统揭秘:从 vLLM 看 LLM Serving Infra 核心技术(总纲)


大规模训练工程(08):长时训练的可观测与运维——从指标到 hang 排查

Observability and Operations for Long-Running Training


大规模训练工程(07):训练稳定性与数据管线——loss spike、梯度范数、数据混合与流式加载

Training Stability and the Data Pipeline


大规模训练工程(06):容错与弹性——故障率数学、straggler、SDC 与弹性训练

Fault Tolerance and Elasticity: Failure Math, Stragglers, SDC and Elastic Training


大规模训练工程(05):分布式 checkpoint——格式、异步保存与重分片恢复

Distributed Checkpoint: Format, Async Save and Resharding


大规模训练工程(04):千卡配置实战——并行搭配、micro-batch、激活重计算与 MFU 调优

Configuring a Thousand-GPU Job: Parallelism, Micro-batch, Recompute and MFU


大规模训练工程(03):三个框架——Megatron-LM、DeepSpeed 与 torchtitan 的架构对比与源码导读

Megatron-LM, DeepSpeed and torchtitan: Architecture and Source Guide


大规模训练工程(02):并行策略全景——每种并行切的是哪种状态

A Map of Parallelism: Which State Does Each Strategy Shard


大规模训练工程(01):训练任务的状态解剖——显存账与 MFU

Anatomy of Training State: Memory Accounting and MFU


大规模训练工程:从并行策略到容错恢复(总纲)

Large-Scale Training Engineering, from Parallelism to Fault Tolerance


通信与互联(08):MoE 的通信——all-to-all、DeepEP 与 GPU 发起的通信

Communication for MoE: All-to-All, DeepEP and GPU-Initiated Networking


通信与互联(07):推理侧的通信——custom all-reduce 与 KV 传输

Communication on the Inference Side: Custom All-Reduce and KV Cache Transfer


通信与互联(06):nccl-tests、调优与排障——从带宽曲线到 hang

nccl-tests, Tuning and Debugging Hangs: From Bandwidth Curves to Flight Recorder


通信与互联(05):PyTorch 的通信栈——ProcessGroupNCCL、stream 语义与计算通信重叠

PyTorch's Communication Stack: ProcessGroupNCCL, Stream Semantics, and Compute-Communication Overlap


通信与互联(04):NCCL 架构——拓扑探测、channel、算法与协议

NCCL Architecture: Topology Detection, Channels, Algorithms and Protocols


通信与互联(03):RDMA 与 GPUDirect——绕过 CPU 和主机内存的数据通路

RDMA and GPUDirect: Bypassing the CPU and Host Memory


通信与互联(02):硬件互联——PCIe、NVLink、NVSwitch 与网络拓扑

Hardware Interconnect: PCIe, NVLink, NVSwitch and Network Topology


通信与互联(01):集合通信原语与代价模型——α-β 模型与 ring all-reduce

Collective Communication Primitives and the Alpha-Beta Cost Model: Deriving Ring All-Reduce


通信与互联:从 NCCL 到 RDMA(总纲)

Communication and Interconnect for AI-Infra, from NCCL to RDMA


GPU Kernel 工程(10):剖析、测试与贡献——把 kernel 做成产品

Profiling, Testing and Contributing: Turning a Kernel into a Product


GPU Kernel 工程(09):量化与融合 kernel——推理系统的其余部分

Quantized and Fused Kernels: The Rest of the Inference Stack


GPU Kernel 工程(08):Attention Kernel——FlashAttention 与 PagedAttention

Attention Kernels: FlashAttention and PagedAttention from Derivation to Code


GPU Kernel 工程(07):Triton——块级编程与编译器的边界

Triton: Block-Level Programming and Where the Compiler Stops


GPU Kernel 工程(06):Tensor Core、CUTLASS 与 CuTe

Tensor Cores, CUTLASS and CuTe: Programming the Matrix Units


GPU Kernel 工程(05):GEMM——从 naive 到分块

GEMM from Naive to Tiled: Reaching the Compute Ceiling on CUDA Cores


GPU Kernel 工程(04):共享内存与 reduction——softmax、LayerNorm 与 online softmax

Shared Memory and Reductions: Softmax, LayerNorm and Online Softmax


GPU Kernel 工程(03):访存合并与 elementwise kernel

Memory Coalescing and Elementwise Kernels: Hitting the Bandwidth Ceiling


GPU Kernel 工程(02):CUDA 编程模型与第一个 kernel

The CUDA Programming Model and Your First Kernel, Measured


GPU Kernel 工程(01):GPU 为什么这样设计——硬件结构与 Roofline

Why GPUs Look the Way They Do: Architecture and the Roofline Model


GPU Kernel 工程:从 CUDA 执行模型到 FlashAttention(总纲)

GPU Kernel Engineering, from the CUDA Execution Model to FlashAttention


多模态(07):自回归图像生成与统一模型

Autoregressive Image Generation and Unified Understanding-Generation Models


多模态(06):Latent diffusion、DiT 与文生图配方

Latent Diffusion, DiT and How Text-to-Image Models Are Built


多模态(05):扩散模型:DDPM、score matching 与 flow matching

Diffusion Models: DDPM, Score Matching and Flow Matching Are One Thing


多模态(04):语音与全模态:音频编码器、codec 与全双工

Speech and Omni Models: Audio Encoders, Neural Codecs and Full-Duplex Dialogue


多模态(03):VLM 的训练:数据、阶段与评测

Training a VLM: Data, Stages, Evaluation and Hallucination


多模态(02):VLM 的结构:connector、注入方式与动态分辨率

VLM Architecture: Connectors, Injection Methods and Dynamic Resolution


多模态(01):视觉编码器:CLIP、SigLIP 与自监督 ViT

Vision Encoders: CLIP, SigLIP and Self-Supervised ViTs


多模态:从视觉编码器到扩散模型(总纲)

Multimodal Models: From Vision Encoders to Diffusion


高效推理与压缩(06):剪枝、深度缩放与小模型配方

Pruning, Depth Scaling and How Small Models Are Made


高效推理与压缩(05):KV cache 压缩:量化、驱逐与稀疏 attention

KV Cache Compression: Quantization, Eviction and Sparse Attention


高效推理与压缩(04):量化感知训练、低比特与量化模型的评测

Quantization-Aware Training, Extreme Low-Bit and How to Evaluate a Quantized Model


高效推理与压缩(03):训练后量化:误差模型、GPTQ、AWQ 与旋转

Post-Training Quantization: Error Models, GPTQ, AWQ and Rotation


高效推理与压缩(02):投机解码:草稿、接受率与树

Speculative Decoding: Drafters, Acceptance Rates and Draft Trees


高效推理与压缩(01):解码策略、采样与约束生成

Decoding Strategies: Sampling, Truncation, Penalties and Constrained Generation


高效推理与压缩(算法侧):解码、投机、量化与 KV(总纲)

Efficient Inference and Model Compression: The Algorithm Side


算法工程师的实验方法论:用有限的算力得出可信的结论

Experimental Methodology for AI Algorithm Engineers: Credible Conclusions on a Finite Compute Budget


后训练(08):评测:benchmark、LLM-as-judge、Arena 与污染

Evaluating LLMs: Benchmarks, LLM-as-Judge, Arenas and Contamination


后训练(07):蒸馏:logits 级、序列级与 on-policy

Knowledge Distillation for LLMs: Logit-Level, Sequence-Level and On-Policy


后训练(06):Agent 与工具调用的 RL:多轮环境、轨迹数据与延后的奖励

Agentic RL: Multi-Turn Environments, Trajectory Data and Delayed Rewards


后训练(05):推理模型与可验证奖励:R1 的配方、PRM 与 test-time compute

Reasoning Models and Verifiable Rewards: The R1 Recipe, Process Reward Models and Test-Time Compute


后训练(04):离线 RL:从 RLHF 目标推出 DPO 及其变体

Offline Preference Optimization: Deriving DPO from the RLHF Objective, and Its Family


后训练(03):在线 RL:PPO、GRPO 与 RLHF 三件套

Online RL for LLMs: PPO, GRPO and the Policy–Reward–Reference Trio


后训练(02):偏好数据与奖励模型:Bradley-Terry、pairwise loss 与 reward hacking

Preference Data and Reward Models: Bradley-Terry, Pairwise Loss and Reward Hacking


后训练(01):SFT:指令数据、chat template、loss mask 与参数高效微调

Supervised Fine-Tuning: Instruction Data, Chat Templates, Loss Masking and Parameter-Efficient Fine-Tuning


后训练:从 SFT 到可验证奖励(总纲)

Post-Training: From Supervised Fine-Tuning to Verifiable Rewards


预训练(04):训练配方与稳定性:学习率、batch、调度与 loss spike

Pretraining Recipes and Training Stability: Learning Rate, Batch Size, Schedules and Loss Spikes


预训练(03):预训练数据工程:从 Common Crawl 到 15T token,去重、过滤与配比的账

Pretraining Data Engineering: From Common Crawl to 15T Tokens, the Arithmetic of Deduplication, Filtering and Mixing


预训练(02):Scaling law:从 Chinchilla 到"过训练",算力怎么分给参数与数据

Scaling Laws: From Chinchilla to Over-Training, Splitting Compute between Parameters and Data


预训练(01):分词与词表:BPE、词表大小与 token 效率

Tokenizers and Vocabulary: BPE, Vocabulary Size and Token Efficiency


预训练:从 tokenizer 到训练配方(总纲)

Pretraining: Tokenizers, Scaling Laws, Data Pipelines and Training Recipes


Transformer 与 LLM(08):多模态:vision encoder 的算量与 image token 的 KV 代价

Multimodal LLMs: The Cost of Vision Encoders and Image Tokens


Transformer 与 LLM(07):量化、投机解码与 LoRA

Quantization, Speculative Decoding and LoRA: Three Ways to Reshape the Computation


Transformer 与 LLM(06):浮点格式、数值稳定性与混合精度

Floating-Point Formats, Numerical Stability and Mixed Precision


Transformer 与 LLM(05):MoE 的路由、激活参数量与通信形态

Mixture of Experts: Routing, Active Parameters and Communication Patterns


Transformer 与 LLM(04):位置编码与长上下文

Positional Encoding and Long Context: RoPE Wavelengths, Extrapolation and Cost


Transformer 与 LLM(03):Attention 变体与 KV cache

Attention Variants and the KV Cache: Deriving MHA, GQA, MQA and MLA


Transformer 与 LLM(02):前向的算量与访存量

FLOPs, Bytes and Roofline: Prefill versus Decode


Transformer 与 LLM(01):Transformer 解剖与参数量

Transformer Anatomy and Parameter Count: From config.json to 8.03B


Transformer 与 LLM:结构、算量与数值(总纲)

Transformers and LLMs for Infrastructure Engineers: Architecture, Arithmetic and Numerics


深度学习基础(06):RNN——从 LSTM 到 attention 的诞生

RNN: Backpropagation Through Time, the LSTM Gate as a Residual Path, and How Attention Was Born from the seq2seq Bottleneck


深度学习基础(05):CNN——从 LeNet 到 ResNet,再到 ViT

CNN: Convolution as a Constrained Linear Layer, the ResNet Legacy and How ViT Turns Images into Tokens


深度学习基础(04):正则化与泛化——为什么参数比样本多却不过拟合

Regularization and Generalization: Double Descent, Implicit Bias, Dropout, Weight Decay and When Overfitting Comes Back


深度学习基础(03):优化器——从 SGD 到 AdamW 与学习率调度

Optimizers: From SGD to AdamW, Warmup, Clipping and the Batch-Learning-Rate Scaling Rule


深度学习基础(02):训练为什么不稳定——初始化、归一化与残差

Why Deep Training Is Unstable: Variance Propagation, Initialization, Normalization and Residual Connections


深度学习基础(01):反向传播——手推一个两层网络

Backpropagation by Hand: Shapes, the 2x Rule and Why Activations Must Be Saved


深度学习基础:从反向传播到残差(总纲)

Deep Learning Foundations: From Backpropagation to Residual Connections


LLM 时代的经典机器学习(06):评估——从混淆矩阵到 judge 的一致性

Evaluation: Confusion Matrix, Thresholds, AUC, Calibration, Paired Tests and Multiple Comparisons


LLM 时代的经典机器学习(05):去重——MinHash 与 LSH 的概率

Deduplication: Jaccard, MinHash as an Unbiased Estimator, and the LSH S-Curve


LLM 时代的经典机器学习(04):无监督——K-Means、PCA 与 embedding 聚类

Unsupervised Learning: K-Means, DBSCAN, PCA and What a Corpus Looks Like in Embedding Space


LLM 时代的经典机器学习(03):分类器一家——从朴素贝叶斯到梯度提升

A Family of Classifiers: From Naive Bayes to Gradient Boosting, and Why Data Filters Use Small Models


LLM 时代的经典机器学习(02):线性回归与逻辑回归——奖励模型的骨架

Linear and Logistic Regression: The Skeleton of Every Classification Head and Every Reward Model


LLM 时代的经典机器学习(01):什么是学习——划分、泛化、过拟合与偏差-方差

What Is Learning: Splits, Generalization, Overfitting and the Bias-Variance Decomposition


LLM 时代还要学经典机器学习吗:只讲它在哪里重现(总纲)

Classical Machine Learning in the LLM Era: What Survives and Where It Reappears


PyTorch 深度实践(10):PyTorch 的工程体系——一次改动如何安全地到达用户

The Engineering System of PyTorch: How a Change Travels Safely from Commit to Production


PyTorch 深度实践(09):分布式 PyTorch

Distributed Training in PyTorch: Collectives, DDP, FSDP, TP, PP, CP and EP


PyTorch 深度实践(08):性能优化与调试

Performance Optimization and Debugging in PyTorch


PyTorch 深度实践(07):编译执行与图优化

Compilation and Graph Optimization in PyTorch


PyTorch 深度实践(06):C++ 扩展与自定义算子

C++ Extensions and Custom Operators in PyTorch


PyTorch 深度实践(05):Dispatcher 与算子系统

The Dispatcher and Operator System in PyTorch


PyTorch 深度实践(04):nn.Module 与训练系统

nn.Module and Training Systems in PyTorch


PyTorch 深度实践(03):自动求导与动态计算图

Autograd and Dynamic Computation Graphs in PyTorch


PyTorch 深度实践(02):Tensor 与内存布局

Tensor Abstraction and Memory Layout in PyTorch


PyTorch 深度实践(01):PyTorch 整体介绍

PyTorch Overall Introduction


PyTorch 深度实践:从 Tensor 到深度学习运行时(总纲)

Deep Dive into PyTorch, from Tensor to Deep Learning Runtime


C++ 在 AI-Infra(08):构建、调试与测试工具链

Build, Debug and Test Toolchain


C++ 在 AI-Infra(07):与 Python 之间——pybind11、Python C API 与 ABI

pybind11, the Python C API and ABI


C++ 在 AI-Infra(06):并发、内存模型、TLS 与守卫

Concurrency, Memory Model, TLS and Guards


C++ 在 AI-Infra(05):宏、静态注册与代码生成

Macros, Static Registration and Code Generation


C++ 在 AI-Infra(04):多态与类型擦除——运行时如何选择实现

Polymorphism and Type Erasure


C++ 在 AI-Infra(03):模板与泛型编程

Templates and Generic Programming


C++ 在 AI-Infra(02):值、引用与所有权——对象模型与 RAII

Value Semantics, Ownership and RAII


C++ 在 AI-Infra(01):从源码到二进制——编译模型与项目布局

Compilation Model and Project Layout


C++ 在 AI-Infra:从对象模型到算子扩展(总纲)

C++ for AI-Infra, from the Object Model to Operator Extensions


算法工程师的工具箱(05):GPU 直觉与实验管理——两个上限、四块显存、能复现

GPU Intuition and Experiment Management: Two Ceilings, Four Memory Buckets, and Reproducibility


算法工程师的工具箱(04):Hugging Face 生态——六个库与一次 LoRA SFT 的组装

The Hugging Face Ecosystem: Six Libraries, a Six-Line LoRA SFT, and Why Reading the Source Is the Fastest Way to Learn


算法工程师的工具箱(03):PyTorch 使用层(下)——混合精度、显存的账与多卡启用

PyTorch in Use, Part 2: Mixed Precision, the Memory Ledger and Turning On Multi-GPU


算法工程师的工具箱(02):PyTorch 使用层(上)——五个对象与二十行训练循环

PyTorch in Use, Part 1: Five Objects and a Twenty-Line Training Loop


算法工程师的工具箱(01):科学计算栈——NumPy 的形状直觉、Pandas 的错误分析、Matplotlib 的曲线

The Scientific Python Stack: Shapes and Broadcasting in NumPy, Error Analysis in Pandas, Reading Curves in Matplotlib


算法工程师的工具箱:从一个想法到一次能跑的实验(总纲)

Tooling for AI Algorithm Engineers: NumPy, PyTorch, Hugging Face and the GPU in Your Head


算法工程师的数学(08):统计推断与拟合——评测的置信区间与 scaling law

Statistical Inference and Curve Fitting: Confidence Intervals for Benchmarks and How Scaling Laws Are Fit


算法工程师的数学(07):导数、梯度与链式法则——softmax 的梯度与策略梯度

Derivatives, Gradients and the Chain Rule: The Softmax Gradient and the Policy Gradient


算法工程师的数学(06):熵、交叉熵与 KL——从困惑度到 DPO

Entropy, Cross-Entropy and KL Divergence: From Perplexity to the DPO Loss


算法工程师的数学(05):从最大似然到交叉熵——第一个要会推的 loss

From Maximum Likelihood to Cross-Entropy: The First Loss You Should Be Able to Derive


算法工程师的数学(04):概率入门——语言模型是一个条件分布

Probability Basics: A Language Model Is a Conditional Distribution


算法工程师的数学(03):正交与旋转、特征值与 SVD——从 RoPE 到 LoRA

Orthogonal Matrices, Rotations, Eigenvalues and SVD: Why RoPE Encodes Relative Position and Why LoRA Works


算法工程师的数学(02):内积、范数与余弦相似度

Inner Product, Norms and Cosine Similarity: One Language for Attention, Retrieval, Regularization and Quantization Error


算法工程师的数学(01):向量、矩阵与形状——一个 token 过一层要算多少

Vectors, Matrices and Shapes: How Much Compute Does One Token Through One Layer Take


算法工程师的数学:读公式不卡壳的最小集(总纲)

Mathematics for AI Algorithm Engineers: The Minimal Set to Read Papers and Derive Losses


AI 应用工程师学习地图:在非确定性组件之上做可靠产品

A Learning Roadmap for AI Application Engineers


AI-Infra 工程师学习地图:从后端工程师到基础设施贡献者

A Learning Roadmap for AI Infrastructure Engineers


AI 算法工程师学习地图:从数学基础到大模型训练

A Learning Roadmap for AI Algorithm Engineers in the LLM Era


AI 全栈学习地图:造模型、跑模型、用模型的三张图

One System, Three Roles — an Overview of the Three AI Learning Roadmaps


AI基础架构:从大数据到深度学习


Parameter Server

参数服务器


Python

Python 在 AI-Infra(07):项目工程化与生产交付

Python Project Engineering and Production Delivery


Python 在 AI-Infra(06):单元测试、问题定位与调试实践

Python Unit Testing, Troubleshooting, and Debugging


Python 在 AI-Infra(05):内存管理与优化

Python Memory Management and Optimization


Python 在 AI-Infra(04):Python的动态机制及工程实践

Python Dynamic Mechanisms and Practice


Python 在 AI-Infra(03):并发、异步与任务协作

Python Concurrency, Asynchrony, and Task Collaboration in AI Systems


Python 在 AI-Infra(02):类型系统与数据契约设计

Python Type System and Data Contract Design


Python 在 AI-Infra(01):语言机制与运行时原理

Python Language Mechanisms and Runtime Internals


Python 在 AI-Infra:从语言机制到生产交付(总纲)

Python for AI-Infra, from Language Mechanisms to Production Delivery (Overview)


算法工程师的工具箱(05):GPU 直觉与实验管理——两个上限、四块显存、能复现

GPU Intuition and Experiment Management: Two Ceilings, Four Memory Buckets, and Reproducibility


算法工程师的工具箱(04):Hugging Face 生态——六个库与一次 LoRA SFT 的组装

The Hugging Face Ecosystem: Six Libraries, a Six-Line LoRA SFT, and Why Reading the Source Is the Fastest Way to Learn


算法工程师的工具箱(03):PyTorch 使用层(下)——混合精度、显存的账与多卡启用

PyTorch in Use, Part 2: Mixed Precision, the Memory Ledger and Turning On Multi-GPU


算法工程师的工具箱(02):PyTorch 使用层(上)——五个对象与二十行训练循环

PyTorch in Use, Part 1: Five Objects and a Twenty-Line Training Loop


算法工程师的工具箱(01):科学计算栈——NumPy 的形状直觉、Pandas 的错误分析、Matplotlib 的曲线

The Scientific Python Stack: Shapes and Broadcasting in NumPy, Error Analysis in Pandas, Reading Curves in Matplotlib


算法工程师的工具箱:从一个想法到一次能跑的实验(总纲)

Tooling for AI Algorithm Engineers: NumPy, PyTorch, Hugging Face and the GPU in Your Head


Python中如何定义POJO


AI-Infra

AI-Infra 开源贡献指南(02):找到切入点——从 issue、RFC 到性能回归

Finding Your Entry Point: Issues, RFCs, Roadmaps, CI Failures and Regressions


AI-Infra 开源贡献指南(01):读懂一个百万行的代码库

Reading a Million-Line Codebase: Maps, Entry Points, Symbols, Tests and History


AI-Infra 开源贡献指南(总纲)

A Guide to Contributing to AI-Infra Open Source Projects


AI 平台工程(08):可观测、成本与 FinOps

Observability, Cost and FinOps: from DCGM to the Token Bill


AI 平台工程(07):模型网关与多租户——路由、配额与灰度

The Model Gateway: KV-Aware Routing, Multi-Tenancy, Quotas and Canaries


AI 平台工程(06):Serving 平台——从 InferenceService 到 llm-d

Serving Platforms: KServe, Triton, Ray Serve, LeaderWorkerSet and llm-d


AI 平台工程(05):网络与存储——RDMA 进容器、并行文件系统与 checkpoint I/O

Networking and Storage: RDMA in Containers, Parallel File Systems and Checkpoint I/O


AI 平台工程(04):GPU 共享与切分——MIG、时间片、MPS 与 HAMi

Sharing and Partitioning GPUs: MIG, Time-Slicing, MPS and HAMi


AI 平台工程(03):AI 任务调度——gang scheduling、队列与拓扑感知

Scheduling AI Jobs: Gang Scheduling, Queues, Quotas and Topology Awareness


AI 平台工程(02):容器里的 GPU——驱动、CUDA、device plugin 与镜像

GPUs in Containers: Driver, CUDA, Device Plugin, DRA and Images


AI 平台工程(01):引擎的需求清单与平台的整体架构

What Engines Demand from the Platform, and the Platform's Two Layers


AI 平台工程:资源层与交付层(总纲)

AI Platform Engineering: the Resource Layer and the Delivery Layer


RL 后训练基础设施(08):配置、可观测与排障——从一张卡的比例到一条 hang 的排查

Configuration, Observability and Troubleshooting for RL Post-Training Systems


RL 后训练基础设施(07):verl 源码导读——从一个 GRPO 配置追到每个 worker

Reading verl: From One GRPO Config to Every Worker


RL 后训练基础设施(06):Agentic rollout——多轮、工具、沙箱与环境服务

Agentic Rollout: Multi-Turn Trajectories, Tools, Sandboxes and Environment Services


RL 后训练基础设施(05):异步与 off-policy——把同步的墙拆掉之后要补什么

Asynchrony and Off-Policy: What You Owe After Tearing Down the Synchronization Wall


RL 后训练基础设施(04):权重同步——从训练分片到推理分片

Weight Synchronization: From Training Shards to Inference Shards


RL 后训练基础设施(03):共置——训练器与推理引擎在同一组 GPU 上共存

Colocation: Handing GPU Memory Back and Forth Between Trainer and Rollout Engine


RL 后训练基础设施(02):系统形态——共置、分离与异步

RL System Topologies: Colocated, Disaggregated and Asynchronous


RL 后训练基础设施(01):负载画像——一步 RL 里发生什么

Anatomy of an RL Step: Rollout, Reward and Train


RL 后训练基础设施:rollout 与训练如何共享一组 GPU(总纲)

RL Post-Training Infrastructure: How Rollout and Training Share the Same GPUs


大模型推理系统揭秘(14):回到源码:一次请求在 vLLM 内部的真实旅程


大模型推理系统揭秘(13):Serving Infra 的下一站:从模型执行器到分布式智能操作系统


大模型推理系统揭秘(12):PD 分离:从资源混部走向计算解耦


大模型推理系统揭秘(11):硬件解耦:如何不让芯片差异污染 Serving 核心?


大模型推理系统揭秘(10):请求形态的扩展:multi-LoRA 与多模态


大模型推理系统揭秘(09):模型适配:如何跟上变化极快的模型世界?


大模型推理系统揭秘(08):Multi-GPU:一张卡不够时如何扩展?


大模型推理系统揭秘(07):解码的扩展:采样、投机解码与结构化输出


大模型推理系统揭秘(06):GPU 执行:如何让每个 Token 算得更快?


大模型推理系统揭秘(05):KV Cache:LLM Serving 的第一号内存问题


大模型推理系统揭秘(04):Scheduler:GPU 这一轮到底给谁用?


大模型推理系统揭秘(03):鸟瞰 vLLM:一个请求如何穿过整个推理系统?


大模型推理系统揭秘(02):如何衡量一个 LLM Serving 系统?


大模型推理系统揭秘(01):为什么 LLM Serving 比传统 DL 推理难?


大模型推理系统揭秘:从 vLLM 看 LLM Serving Infra 核心技术(总纲)


大规模训练工程(08):长时训练的可观测与运维——从指标到 hang 排查

Observability and Operations for Long-Running Training


大规模训练工程(07):训练稳定性与数据管线——loss spike、梯度范数、数据混合与流式加载

Training Stability and the Data Pipeline


大规模训练工程(06):容错与弹性——故障率数学、straggler、SDC 与弹性训练

Fault Tolerance and Elasticity: Failure Math, Stragglers, SDC and Elastic Training


大规模训练工程(05):分布式 checkpoint——格式、异步保存与重分片恢复

Distributed Checkpoint: Format, Async Save and Resharding


大规模训练工程(04):千卡配置实战——并行搭配、micro-batch、激活重计算与 MFU 调优

Configuring a Thousand-GPU Job: Parallelism, Micro-batch, Recompute and MFU


大规模训练工程(03):三个框架——Megatron-LM、DeepSpeed 与 torchtitan 的架构对比与源码导读

Megatron-LM, DeepSpeed and torchtitan: Architecture and Source Guide


大规模训练工程(02):并行策略全景——每种并行切的是哪种状态

A Map of Parallelism: Which State Does Each Strategy Shard


大规模训练工程(01):训练任务的状态解剖——显存账与 MFU

Anatomy of Training State: Memory Accounting and MFU


大规模训练工程:从并行策略到容错恢复(总纲)

Large-Scale Training Engineering, from Parallelism to Fault Tolerance


通信与互联(08):MoE 的通信——all-to-all、DeepEP 与 GPU 发起的通信

Communication for MoE: All-to-All, DeepEP and GPU-Initiated Networking


通信与互联(07):推理侧的通信——custom all-reduce 与 KV 传输

Communication on the Inference Side: Custom All-Reduce and KV Cache Transfer


通信与互联(06):nccl-tests、调优与排障——从带宽曲线到 hang

nccl-tests, Tuning and Debugging Hangs: From Bandwidth Curves to Flight Recorder


通信与互联(05):PyTorch 的通信栈——ProcessGroupNCCL、stream 语义与计算通信重叠

PyTorch's Communication Stack: ProcessGroupNCCL, Stream Semantics, and Compute-Communication Overlap


通信与互联(04):NCCL 架构——拓扑探测、channel、算法与协议

NCCL Architecture: Topology Detection, Channels, Algorithms and Protocols


通信与互联(03):RDMA 与 GPUDirect——绕过 CPU 和主机内存的数据通路

RDMA and GPUDirect: Bypassing the CPU and Host Memory


通信与互联(02):硬件互联——PCIe、NVLink、NVSwitch 与网络拓扑

Hardware Interconnect: PCIe, NVLink, NVSwitch and Network Topology


通信与互联(01):集合通信原语与代价模型——α-β 模型与 ring all-reduce

Collective Communication Primitives and the Alpha-Beta Cost Model: Deriving Ring All-Reduce


通信与互联:从 NCCL 到 RDMA(总纲)

Communication and Interconnect for AI-Infra, from NCCL to RDMA


GPU Kernel 工程(10):剖析、测试与贡献——把 kernel 做成产品

Profiling, Testing and Contributing: Turning a Kernel into a Product


GPU Kernel 工程(09):量化与融合 kernel——推理系统的其余部分

Quantized and Fused Kernels: The Rest of the Inference Stack


GPU Kernel 工程(08):Attention Kernel——FlashAttention 与 PagedAttention

Attention Kernels: FlashAttention and PagedAttention from Derivation to Code


GPU Kernel 工程(07):Triton——块级编程与编译器的边界

Triton: Block-Level Programming and Where the Compiler Stops


GPU Kernel 工程(06):Tensor Core、CUTLASS 与 CuTe

Tensor Cores, CUTLASS and CuTe: Programming the Matrix Units


GPU Kernel 工程(05):GEMM——从 naive 到分块

GEMM from Naive to Tiled: Reaching the Compute Ceiling on CUDA Cores


GPU Kernel 工程(04):共享内存与 reduction——softmax、LayerNorm 与 online softmax

Shared Memory and Reductions: Softmax, LayerNorm and Online Softmax


GPU Kernel 工程(03):访存合并与 elementwise kernel

Memory Coalescing and Elementwise Kernels: Hitting the Bandwidth Ceiling


GPU Kernel 工程(02):CUDA 编程模型与第一个 kernel

The CUDA Programming Model and Your First Kernel, Measured


GPU Kernel 工程(01):GPU 为什么这样设计——硬件结构与 Roofline

Why GPUs Look the Way They Do: Architecture and the Roofline Model


GPU Kernel 工程:从 CUDA 执行模型到 FlashAttention(总纲)

GPU Kernel Engineering, from the CUDA Execution Model to FlashAttention


Transformer 与 LLM(08):多模态:vision encoder 的算量与 image token 的 KV 代价

Multimodal LLMs: The Cost of Vision Encoders and Image Tokens


Transformer 与 LLM(07):量化、投机解码与 LoRA

Quantization, Speculative Decoding and LoRA: Three Ways to Reshape the Computation


Transformer 与 LLM(06):浮点格式、数值稳定性与混合精度

Floating-Point Formats, Numerical Stability and Mixed Precision


Transformer 与 LLM(05):MoE 的路由、激活参数量与通信形态

Mixture of Experts: Routing, Active Parameters and Communication Patterns


Transformer 与 LLM(04):位置编码与长上下文

Positional Encoding and Long Context: RoPE Wavelengths, Extrapolation and Cost


Transformer 与 LLM(03):Attention 变体与 KV cache

Attention Variants and the KV Cache: Deriving MHA, GQA, MQA and MLA


Transformer 与 LLM(02):前向的算量与访存量

FLOPs, Bytes and Roofline: Prefill versus Decode


Transformer 与 LLM(01):Transformer 解剖与参数量

Transformer Anatomy and Parameter Count: From config.json to 8.03B


Transformer 与 LLM:结构、算量与数值(总纲)

Transformers and LLMs for Infrastructure Engineers: Architecture, Arithmetic and Numerics


PyTorch 深度实践(10):PyTorch 的工程体系——一次改动如何安全地到达用户

The Engineering System of PyTorch: How a Change Travels Safely from Commit to Production


PyTorch 深度实践(09):分布式 PyTorch

Distributed Training in PyTorch: Collectives, DDP, FSDP, TP, PP, CP and EP


PyTorch 深度实践(08):性能优化与调试

Performance Optimization and Debugging in PyTorch


PyTorch 深度实践(07):编译执行与图优化

Compilation and Graph Optimization in PyTorch


PyTorch 深度实践(06):C++ 扩展与自定义算子

C++ Extensions and Custom Operators in PyTorch


PyTorch 深度实践(05):Dispatcher 与算子系统

The Dispatcher and Operator System in PyTorch


PyTorch 深度实践(04):nn.Module 与训练系统

nn.Module and Training Systems in PyTorch


PyTorch 深度实践(03):自动求导与动态计算图

Autograd and Dynamic Computation Graphs in PyTorch


PyTorch 深度实践(02):Tensor 与内存布局

Tensor Abstraction and Memory Layout in PyTorch


PyTorch 深度实践(01):PyTorch 整体介绍

PyTorch Overall Introduction


PyTorch 深度实践:从 Tensor 到深度学习运行时(总纲)

Deep Dive into PyTorch, from Tensor to Deep Learning Runtime


C++ 在 AI-Infra(08):构建、调试与测试工具链

Build, Debug and Test Toolchain


C++ 在 AI-Infra(07):与 Python 之间——pybind11、Python C API 与 ABI

pybind11, the Python C API and ABI


C++ 在 AI-Infra(06):并发、内存模型、TLS 与守卫

Concurrency, Memory Model, TLS and Guards


C++ 在 AI-Infra(05):宏、静态注册与代码生成

Macros, Static Registration and Code Generation


C++ 在 AI-Infra(04):多态与类型擦除——运行时如何选择实现

Polymorphism and Type Erasure


C++ 在 AI-Infra(03):模板与泛型编程

Templates and Generic Programming


C++ 在 AI-Infra(02):值、引用与所有权——对象模型与 RAII

Value Semantics, Ownership and RAII


C++ 在 AI-Infra(01):从源码到二进制——编译模型与项目布局

Compilation Model and Project Layout


C++ 在 AI-Infra:从对象模型到算子扩展(总纲)

C++ for AI-Infra, from the Object Model to Operator Extensions


Python 在 AI-Infra:从语言机制到生产交付(总纲)

Python for AI-Infra, from Language Mechanisms to Production Delivery (Overview)


AI-Infra 工程师学习地图:从后端工程师到基础设施贡献者

A Learning Roadmap for AI Infrastructure Engineers


AI 全栈学习地图:造模型、跑模型、用模型的三张图

One System, Three Roles — an Overview of the Three AI Learning Roadmaps


LLM

多模态:从视觉编码器到扩散模型(总纲)

Multimodal Models: From Vision Encoders to Diffusion


高效推理与压缩(06):剪枝、深度缩放与小模型配方

Pruning, Depth Scaling and How Small Models Are Made


高效推理与压缩(05):KV cache 压缩:量化、驱逐与稀疏 attention

KV Cache Compression: Quantization, Eviction and Sparse Attention


高效推理与压缩(04):量化感知训练、低比特与量化模型的评测

Quantization-Aware Training, Extreme Low-Bit and How to Evaluate a Quantized Model


高效推理与压缩(03):训练后量化:误差模型、GPTQ、AWQ 与旋转

Post-Training Quantization: Error Models, GPTQ, AWQ and Rotation


高效推理与压缩(02):投机解码:草稿、接受率与树

Speculative Decoding: Drafters, Acceptance Rates and Draft Trees


高效推理与压缩(01):解码策略、采样与约束生成

Decoding Strategies: Sampling, Truncation, Penalties and Constrained Generation


高效推理与压缩(算法侧):解码、投机、量化与 KV(总纲)

Efficient Inference and Model Compression: The Algorithm Side


算法工程师的实验方法论:用有限的算力得出可信的结论

Experimental Methodology for AI Algorithm Engineers: Credible Conclusions on a Finite Compute Budget


后训练(08):评测:benchmark、LLM-as-judge、Arena 与污染

Evaluating LLMs: Benchmarks, LLM-as-Judge, Arenas and Contamination


后训练(07):蒸馏:logits 级、序列级与 on-policy

Knowledge Distillation for LLMs: Logit-Level, Sequence-Level and On-Policy


后训练(06):Agent 与工具调用的 RL:多轮环境、轨迹数据与延后的奖励

Agentic RL: Multi-Turn Environments, Trajectory Data and Delayed Rewards


后训练(05):推理模型与可验证奖励:R1 的配方、PRM 与 test-time compute

Reasoning Models and Verifiable Rewards: The R1 Recipe, Process Reward Models and Test-Time Compute


后训练(04):离线 RL:从 RLHF 目标推出 DPO 及其变体

Offline Preference Optimization: Deriving DPO from the RLHF Objective, and Its Family


后训练(03):在线 RL:PPO、GRPO 与 RLHF 三件套

Online RL for LLMs: PPO, GRPO and the Policy–Reward–Reference Trio


后训练(02):偏好数据与奖励模型:Bradley-Terry、pairwise loss 与 reward hacking

Preference Data and Reward Models: Bradley-Terry, Pairwise Loss and Reward Hacking


后训练(01):SFT:指令数据、chat template、loss mask 与参数高效微调

Supervised Fine-Tuning: Instruction Data, Chat Templates, Loss Masking and Parameter-Efficient Fine-Tuning


后训练:从 SFT 到可验证奖励(总纲)

Post-Training: From Supervised Fine-Tuning to Verifiable Rewards


预训练(04):训练配方与稳定性:学习率、batch、调度与 loss spike

Pretraining Recipes and Training Stability: Learning Rate, Batch Size, Schedules and Loss Spikes


预训练(03):预训练数据工程:从 Common Crawl 到 15T token,去重、过滤与配比的账

Pretraining Data Engineering: From Common Crawl to 15T Tokens, the Arithmetic of Deduplication, Filtering and Mixing


预训练(02):Scaling law:从 Chinchilla 到"过训练",算力怎么分给参数与数据

Scaling Laws: From Chinchilla to Over-Training, Splitting Compute between Parameters and Data


预训练(01):分词与词表:BPE、词表大小与 token 效率

Tokenizers and Vocabulary: BPE, Vocabulary Size and Token Efficiency


预训练:从 tokenizer 到训练配方(总纲)

Pretraining: Tokenizers, Scaling Laws, Data Pipelines and Training Recipes


Transformer 与 LLM(08):多模态:vision encoder 的算量与 image token 的 KV 代价

Multimodal LLMs: The Cost of Vision Encoders and Image Tokens


Transformer 与 LLM(07):量化、投机解码与 LoRA

Quantization, Speculative Decoding and LoRA: Three Ways to Reshape the Computation


Transformer 与 LLM(06):浮点格式、数值稳定性与混合精度

Floating-Point Formats, Numerical Stability and Mixed Precision


Transformer 与 LLM(05):MoE 的路由、激活参数量与通信形态

Mixture of Experts: Routing, Active Parameters and Communication Patterns


Transformer 与 LLM(04):位置编码与长上下文

Positional Encoding and Long Context: RoPE Wavelengths, Extrapolation and Cost


Transformer 与 LLM(03):Attention 变体与 KV cache

Attention Variants and the KV Cache: Deriving MHA, GQA, MQA and MLA


Transformer 与 LLM(02):前向的算量与访存量

FLOPs, Bytes and Roofline: Prefill versus Decode


Transformer 与 LLM(01):Transformer 解剖与参数量

Transformer Anatomy and Parameter Count: From config.json to 8.03B


Transformer 与 LLM:结构、算量与数值(总纲)

Transformers and LLMs for Infrastructure Engineers: Architecture, Arithmetic and Numerics


深度学习基础(06):RNN——从 LSTM 到 attention 的诞生

RNN: Backpropagation Through Time, the LSTM Gate as a Residual Path, and How Attention Was Born from the seq2seq Bottleneck


深度学习基础(05):CNN——从 LeNet 到 ResNet,再到 ViT

CNN: Convolution as a Constrained Linear Layer, the ResNet Legacy and How ViT Turns Images into Tokens


深度学习基础(04):正则化与泛化——为什么参数比样本多却不过拟合

Regularization and Generalization: Double Descent, Implicit Bias, Dropout, Weight Decay and When Overfitting Comes Back


深度学习基础(03):优化器——从 SGD 到 AdamW 与学习率调度

Optimizers: From SGD to AdamW, Warmup, Clipping and the Batch-Learning-Rate Scaling Rule


深度学习基础(02):训练为什么不稳定——初始化、归一化与残差

Why Deep Training Is Unstable: Variance Propagation, Initialization, Normalization and Residual Connections


深度学习基础(01):反向传播——手推一个两层网络

Backpropagation by Hand: Shapes, the 2x Rule and Why Activations Must Be Saved


深度学习基础:从反向传播到残差(总纲)

Deep Learning Foundations: From Backpropagation to Residual Connections


LLM 时代的经典机器学习(06):评估——从混淆矩阵到 judge 的一致性

Evaluation: Confusion Matrix, Thresholds, AUC, Calibration, Paired Tests and Multiple Comparisons


LLM 时代的经典机器学习(05):去重——MinHash 与 LSH 的概率

Deduplication: Jaccard, MinHash as an Unbiased Estimator, and the LSH S-Curve


LLM 时代的经典机器学习(04):无监督——K-Means、PCA 与 embedding 聚类

Unsupervised Learning: K-Means, DBSCAN, PCA and What a Corpus Looks Like in Embedding Space


LLM 时代的经典机器学习(03):分类器一家——从朴素贝叶斯到梯度提升

A Family of Classifiers: From Naive Bayes to Gradient Boosting, and Why Data Filters Use Small Models


LLM 时代的经典机器学习(02):线性回归与逻辑回归——奖励模型的骨架

Linear and Logistic Regression: The Skeleton of Every Classification Head and Every Reward Model


LLM 时代的经典机器学习(01):什么是学习——划分、泛化、过拟合与偏差-方差

What Is Learning: Splits, Generalization, Overfitting and the Bias-Variance Decomposition


LLM 时代还要学经典机器学习吗:只讲它在哪里重现(总纲)

Classical Machine Learning in the LLM Era: What Survives and Where It Reappears


算法工程师的工具箱(05):GPU 直觉与实验管理——两个上限、四块显存、能复现

GPU Intuition and Experiment Management: Two Ceilings, Four Memory Buckets, and Reproducibility


算法工程师的工具箱(04):Hugging Face 生态——六个库与一次 LoRA SFT 的组装

The Hugging Face Ecosystem: Six Libraries, a Six-Line LoRA SFT, and Why Reading the Source Is the Fastest Way to Learn


算法工程师的工具箱(03):PyTorch 使用层(下)——混合精度、显存的账与多卡启用

PyTorch in Use, Part 2: Mixed Precision, the Memory Ledger and Turning On Multi-GPU


算法工程师的工具箱(02):PyTorch 使用层(上)——五个对象与二十行训练循环

PyTorch in Use, Part 1: Five Objects and a Twenty-Line Training Loop


算法工程师的工具箱(01):科学计算栈——NumPy 的形状直觉、Pandas 的错误分析、Matplotlib 的曲线

The Scientific Python Stack: Shapes and Broadcasting in NumPy, Error Analysis in Pandas, Reading Curves in Matplotlib


算法工程师的工具箱:从一个想法到一次能跑的实验(总纲)

Tooling for AI Algorithm Engineers: NumPy, PyTorch, Hugging Face and the GPU in Your Head


算法工程师的数学(08):统计推断与拟合——评测的置信区间与 scaling law

Statistical Inference and Curve Fitting: Confidence Intervals for Benchmarks and How Scaling Laws Are Fit


算法工程师的数学(07):导数、梯度与链式法则——softmax 的梯度与策略梯度

Derivatives, Gradients and the Chain Rule: The Softmax Gradient and the Policy Gradient


算法工程师的数学(06):熵、交叉熵与 KL——从困惑度到 DPO

Entropy, Cross-Entropy and KL Divergence: From Perplexity to the DPO Loss


算法工程师的数学(05):从最大似然到交叉熵——第一个要会推的 loss

From Maximum Likelihood to Cross-Entropy: The First Loss You Should Be Able to Derive


算法工程师的数学(04):概率入门——语言模型是一个条件分布

Probability Basics: A Language Model Is a Conditional Distribution


算法工程师的数学(03):正交与旋转、特征值与 SVD——从 RoPE 到 LoRA

Orthogonal Matrices, Rotations, Eigenvalues and SVD: Why RoPE Encodes Relative Position and Why LoRA Works


算法工程师的数学(02):内积、范数与余弦相似度

Inner Product, Norms and Cosine Similarity: One Language for Attention, Retrieval, Regularization and Quantization Error


算法工程师的数学(01):向量、矩阵与形状——一个 token 过一层要算多少

Vectors, Matrices and Shapes: How Much Compute Does One Token Through One Layer Take


算法工程师的数学:读公式不卡壳的最小集(总纲)

Mathematics for AI Algorithm Engineers: The Minimal Set to Read Papers and Derive Losses


AI 应用工程师学习地图:在非确定性组件之上做可靠产品

A Learning Roadmap for AI Application Engineers


AI 算法工程师学习地图:从数学基础到大模型训练

A Learning Roadmap for AI Algorithm Engineers in the LLM Era


AI 全栈学习地图:造模型、跑模型、用模型的三张图

One System, Three Roles — an Overview of the Three AI Learning Roadmaps


Math

算法工程师的数学(08):统计推断与拟合——评测的置信区间与 scaling law

Statistical Inference and Curve Fitting: Confidence Intervals for Benchmarks and How Scaling Laws Are Fit


算法工程师的数学(07):导数、梯度与链式法则——softmax 的梯度与策略梯度

Derivatives, Gradients and the Chain Rule: The Softmax Gradient and the Policy Gradient


算法工程师的数学(06):熵、交叉熵与 KL——从困惑度到 DPO

Entropy, Cross-Entropy and KL Divergence: From Perplexity to the DPO Loss


算法工程师的数学(05):从最大似然到交叉熵——第一个要会推的 loss

From Maximum Likelihood to Cross-Entropy: The First Loss You Should Be Able to Derive


算法工程师的数学(04):概率入门——语言模型是一个条件分布

Probability Basics: A Language Model Is a Conditional Distribution


算法工程师的数学(03):正交与旋转、特征值与 SVD——从 RoPE 到 LoRA

Orthogonal Matrices, Rotations, Eigenvalues and SVD: Why RoPE Encodes Relative Position and Why LoRA Works


算法工程师的数学(02):内积、范数与余弦相似度

Inner Product, Norms and Cosine Similarity: One Language for Attention, Retrieval, Regularization and Quantization Error


算法工程师的数学(01):向量、矩阵与形状——一个 token 过一层要算多少

Vectors, Matrices and Shapes: How Much Compute Does One Token Through One Layer Take


算法工程师的数学:读公式不卡壳的最小集(总纲)

Mathematics for AI Algorithm Engineers: The Minimal Set to Read Papers and Derive Losses


PyTorch

AI-Infra 开源贡献指南(02):找到切入点——从 issue、RFC 到性能回归

Finding Your Entry Point: Issues, RFCs, Roadmaps, CI Failures and Regressions


AI-Infra 开源贡献指南(01):读懂一个百万行的代码库

Reading a Million-Line Codebase: Maps, Entry Points, Symbols, Tests and History


AI-Infra 开源贡献指南(总纲)

A Guide to Contributing to AI-Infra Open Source Projects


大规模训练工程(08):长时训练的可观测与运维——从指标到 hang 排查

Observability and Operations for Long-Running Training


大规模训练工程(06):容错与弹性——故障率数学、straggler、SDC 与弹性训练

Fault Tolerance and Elasticity: Failure Math, Stragglers, SDC and Elastic Training


大规模训练工程(05):分布式 checkpoint——格式、异步保存与重分片恢复

Distributed Checkpoint: Format, Async Save and Resharding


PyTorch 深度实践(10):PyTorch 的工程体系——一次改动如何安全地到达用户

The Engineering System of PyTorch: How a Change Travels Safely from Commit to Production


PyTorch 深度实践(09):分布式 PyTorch

Distributed Training in PyTorch: Collectives, DDP, FSDP, TP, PP, CP and EP


PyTorch 深度实践(08):性能优化与调试

Performance Optimization and Debugging in PyTorch


PyTorch 深度实践(07):编译执行与图优化

Compilation and Graph Optimization in PyTorch


PyTorch 深度实践(06):C++ 扩展与自定义算子

C++ Extensions and Custom Operators in PyTorch


PyTorch 深度实践(05):Dispatcher 与算子系统

The Dispatcher and Operator System in PyTorch


PyTorch 深度实践(04):nn.Module 与训练系统

nn.Module and Training Systems in PyTorch


PyTorch 深度实践(03):自动求导与动态计算图

Autograd and Dynamic Computation Graphs in PyTorch


PyTorch 深度实践(02):Tensor 与内存布局

Tensor Abstraction and Memory Layout in PyTorch


PyTorch 深度实践(01):PyTorch 整体介绍

PyTorch Overall Introduction


PyTorch 深度实践:从 Tensor 到深度学习运行时(总纲)

Deep Dive into PyTorch, from Tensor to Deep Learning Runtime


算法工程师的工具箱(05):GPU 直觉与实验管理——两个上限、四块显存、能复现

GPU Intuition and Experiment Management: Two Ceilings, Four Memory Buckets, and Reproducibility


算法工程师的工具箱(04):Hugging Face 生态——六个库与一次 LoRA SFT 的组装

The Hugging Face Ecosystem: Six Libraries, a Six-Line LoRA SFT, and Why Reading the Source Is the Fastest Way to Learn


算法工程师的工具箱(03):PyTorch 使用层(下)——混合精度、显存的账与多卡启用

PyTorch in Use, Part 2: Mixed Precision, the Memory Ledger and Turning On Multi-GPU


算法工程师的工具箱(02):PyTorch 使用层(上)——五个对象与二十行训练循环

PyTorch in Use, Part 1: Five Objects and a Twenty-Line Training Loop


算法工程师的工具箱(01):科学计算栈——NumPy 的形状直觉、Pandas 的错误分析、Matplotlib 的曲线

The Scientific Python Stack: Shapes and Broadcasting in NumPy, Error Analysis in Pandas, Reading Curves in Matplotlib


算法工程师的工具箱:从一个想法到一次能跑的实验(总纲)

Tooling for AI Algorithm Engineers: NumPy, PyTorch, Hugging Face and the GPU in Your Head


Transformer

预训练(04):训练配方与稳定性:学习率、batch、调度与 loss spike

Pretraining Recipes and Training Stability: Learning Rate, Batch Size, Schedules and Loss Spikes


预训练(03):预训练数据工程:从 Common Crawl 到 15T token,去重、过滤与配比的账

Pretraining Data Engineering: From Common Crawl to 15T Tokens, the Arithmetic of Deduplication, Filtering and Mixing


预训练(02):Scaling law:从 Chinchilla 到"过训练",算力怎么分给参数与数据

Scaling Laws: From Chinchilla to Over-Training, Splitting Compute between Parameters and Data


预训练(01):分词与词表:BPE、词表大小与 token 效率

Tokenizers and Vocabulary: BPE, Vocabulary Size and Token Efficiency


预训练:从 tokenizer 到训练配方(总纲)

Pretraining: Tokenizers, Scaling Laws, Data Pipelines and Training Recipes


Transformer 与 LLM(08):多模态:vision encoder 的算量与 image token 的 KV 代价

Multimodal LLMs: The Cost of Vision Encoders and Image Tokens


Transformer 与 LLM(07):量化、投机解码与 LoRA

Quantization, Speculative Decoding and LoRA: Three Ways to Reshape the Computation


Transformer 与 LLM(06):浮点格式、数值稳定性与混合精度

Floating-Point Formats, Numerical Stability and Mixed Precision


Transformer 与 LLM(05):MoE 的路由、激活参数量与通信形态

Mixture of Experts: Routing, Active Parameters and Communication Patterns


Transformer 与 LLM(04):位置编码与长上下文

Positional Encoding and Long Context: RoPE Wavelengths, Extrapolation and Cost


Transformer 与 LLM(03):Attention 变体与 KV cache

Attention Variants and the KV Cache: Deriving MHA, GQA, MQA and MLA


Transformer 与 LLM(02):前向的算量与访存量

FLOPs, Bytes and Roofline: Prefill versus Decode


Transformer 与 LLM(01):Transformer 解剖与参数量

Transformer Anatomy and Parameter Count: From config.json to 8.03B


Transformer 与 LLM:结构、算量与数值(总纲)

Transformers and LLMs for Infrastructure Engineers: Architecture, Arithmetic and Numerics


CUDA

AI 平台工程(02):容器里的 GPU——驱动、CUDA、device plugin 与镜像

GPUs in Containers: Driver, CUDA, Device Plugin, DRA and Images


RL 后训练基础设施(03):共置——训练器与推理引擎在同一组 GPU 上共存

Colocation: Handing GPU Memory Back and Forth Between Trainer and Rollout Engine


GPU Kernel 工程(10):剖析、测试与贡献——把 kernel 做成产品

Profiling, Testing and Contributing: Turning a Kernel into a Product


GPU Kernel 工程(09):量化与融合 kernel——推理系统的其余部分

Quantized and Fused Kernels: The Rest of the Inference Stack


GPU Kernel 工程(08):Attention Kernel——FlashAttention 与 PagedAttention

Attention Kernels: FlashAttention and PagedAttention from Derivation to Code


GPU Kernel 工程(07):Triton——块级编程与编译器的边界

Triton: Block-Level Programming and Where the Compiler Stops


GPU Kernel 工程(06):Tensor Core、CUTLASS 与 CuTe

Tensor Cores, CUTLASS and CuTe: Programming the Matrix Units


GPU Kernel 工程(05):GEMM——从 naive 到分块

GEMM from Naive to Tiled: Reaching the Compute Ceiling on CUDA Cores


GPU Kernel 工程(04):共享内存与 reduction——softmax、LayerNorm 与 online softmax

Shared Memory and Reductions: Softmax, LayerNorm and Online Softmax


GPU Kernel 工程(03):访存合并与 elementwise kernel

Memory Coalescing and Elementwise Kernels: Hitting the Bandwidth Ceiling


GPU Kernel 工程(02):CUDA 编程模型与第一个 kernel

The CUDA Programming Model and Your First Kernel, Measured


GPU Kernel 工程(01):GPU 为什么这样设计——硬件结构与 Roofline

Why GPUs Look the Way They Do: Architecture and the Roofline Model


GPU Kernel 工程:从 CUDA 执行模型到 FlashAttention(总纲)

GPU Kernel Engineering, from the CUDA Execution Model to FlashAttention


Triton

GPU Kernel 工程(10):剖析、测试与贡献——把 kernel 做成产品

Profiling, Testing and Contributing: Turning a Kernel into a Product


GPU Kernel 工程(09):量化与融合 kernel——推理系统的其余部分

Quantized and Fused Kernels: The Rest of the Inference Stack


GPU Kernel 工程(08):Attention Kernel——FlashAttention 与 PagedAttention

Attention Kernels: FlashAttention and PagedAttention from Derivation to Code


GPU Kernel 工程(07):Triton——块级编程与编译器的边界

Triton: Block-Level Programming and Where the Compiler Stops


GPU Kernel 工程(06):Tensor Core、CUTLASS 与 CuTe

Tensor Cores, CUTLASS and CuTe: Programming the Matrix Units


GPU Kernel 工程(05):GEMM——从 naive 到分块

GEMM from Naive to Tiled: Reaching the Compute Ceiling on CUDA Cores


GPU Kernel 工程(04):共享内存与 reduction——softmax、LayerNorm 与 online softmax

Shared Memory and Reductions: Softmax, LayerNorm and Online Softmax


GPU Kernel 工程(03):访存合并与 elementwise kernel

Memory Coalescing and Elementwise Kernels: Hitting the Bandwidth Ceiling


GPU Kernel 工程(02):CUDA 编程模型与第一个 kernel

The CUDA Programming Model and Your First Kernel, Measured


GPU Kernel 工程(01):GPU 为什么这样设计——硬件结构与 Roofline

Why GPUs Look the Way They Do: Architecture and the Roofline Model


GPU Kernel 工程:从 CUDA 执行模型到 FlashAttention(总纲)

GPU Kernel Engineering, from the CUDA Execution Model to FlashAttention


GPU

AI 平台工程(08):可观测、成本与 FinOps

Observability, Cost and FinOps: from DCGM to the Token Bill


AI 平台工程(07):模型网关与多租户——路由、配额与灰度

The Model Gateway: KV-Aware Routing, Multi-Tenancy, Quotas and Canaries


AI 平台工程(06):Serving 平台——从 InferenceService 到 llm-d

Serving Platforms: KServe, Triton, Ray Serve, LeaderWorkerSet and llm-d


AI 平台工程(05):网络与存储——RDMA 进容器、并行文件系统与 checkpoint I/O

Networking and Storage: RDMA in Containers, Parallel File Systems and Checkpoint I/O


AI 平台工程(04):GPU 共享与切分——MIG、时间片、MPS 与 HAMi

Sharing and Partitioning GPUs: MIG, Time-Slicing, MPS and HAMi


AI 平台工程(03):AI 任务调度——gang scheduling、队列与拓扑感知

Scheduling AI Jobs: Gang Scheduling, Queues, Quotas and Topology Awareness


AI 平台工程(02):容器里的 GPU——驱动、CUDA、device plugin 与镜像

GPUs in Containers: Driver, CUDA, Device Plugin, DRA and Images


AI 平台工程(01):引擎的需求清单与平台的整体架构

What Engines Demand from the Platform, and the Platform's Two Layers


AI 平台工程:资源层与交付层(总纲)

AI Platform Engineering: the Resource Layer and the Delivery Layer


通信与互联(08):MoE 的通信——all-to-all、DeepEP 与 GPU 发起的通信

Communication for MoE: All-to-All, DeepEP and GPU-Initiated Networking


通信与互联(07):推理侧的通信——custom all-reduce 与 KV 传输

Communication on the Inference Side: Custom All-Reduce and KV Cache Transfer


通信与互联(06):nccl-tests、调优与排障——从带宽曲线到 hang

nccl-tests, Tuning and Debugging Hangs: From Bandwidth Curves to Flight Recorder


通信与互联(05):PyTorch 的通信栈——ProcessGroupNCCL、stream 语义与计算通信重叠

PyTorch's Communication Stack: ProcessGroupNCCL, Stream Semantics, and Compute-Communication Overlap


通信与互联(04):NCCL 架构——拓扑探测、channel、算法与协议

NCCL Architecture: Topology Detection, Channels, Algorithms and Protocols


通信与互联(03):RDMA 与 GPUDirect——绕过 CPU 和主机内存的数据通路

RDMA and GPUDirect: Bypassing the CPU and Host Memory


通信与互联(02):硬件互联——PCIe、NVLink、NVSwitch 与网络拓扑

Hardware Interconnect: PCIe, NVLink, NVSwitch and Network Topology


通信与互联(01):集合通信原语与代价模型——α-β 模型与 ring all-reduce

Collective Communication Primitives and the Alpha-Beta Cost Model: Deriving Ring All-Reduce


通信与互联:从 NCCL 到 RDMA(总纲)

Communication and Interconnect for AI-Infra, from NCCL to RDMA


GPU Kernel 工程(10):剖析、测试与贡献——把 kernel 做成产品

Profiling, Testing and Contributing: Turning a Kernel into a Product


GPU Kernel 工程(09):量化与融合 kernel——推理系统的其余部分

Quantized and Fused Kernels: The Rest of the Inference Stack


GPU Kernel 工程(08):Attention Kernel——FlashAttention 与 PagedAttention

Attention Kernels: FlashAttention and PagedAttention from Derivation to Code


GPU Kernel 工程(07):Triton——块级编程与编译器的边界

Triton: Block-Level Programming and Where the Compiler Stops


GPU Kernel 工程(06):Tensor Core、CUTLASS 与 CuTe

Tensor Cores, CUTLASS and CuTe: Programming the Matrix Units


GPU Kernel 工程(05):GEMM——从 naive 到分块

GEMM from Naive to Tiled: Reaching the Compute Ceiling on CUDA Cores


GPU Kernel 工程(04):共享内存与 reduction——softmax、LayerNorm 与 online softmax

Shared Memory and Reductions: Softmax, LayerNorm and Online Softmax


GPU Kernel 工程(03):访存合并与 elementwise kernel

Memory Coalescing and Elementwise Kernels: Hitting the Bandwidth Ceiling


GPU Kernel 工程(02):CUDA 编程模型与第一个 kernel

The CUDA Programming Model and Your First Kernel, Measured


GPU Kernel 工程(01):GPU 为什么这样设计——硬件结构与 Roofline

Why GPUs Look the Way They Do: Architecture and the Roofline Model


GPU Kernel 工程:从 CUDA 执行模型到 FlashAttention(总纲)

GPU Kernel Engineering, from the CUDA Execution Model to FlashAttention


NCCL

RL 后训练基础设施(04):权重同步——从训练分片到推理分片

Weight Synchronization: From Training Shards to Inference Shards


通信与互联(08):MoE 的通信——all-to-all、DeepEP 与 GPU 发起的通信

Communication for MoE: All-to-All, DeepEP and GPU-Initiated Networking


通信与互联(07):推理侧的通信——custom all-reduce 与 KV 传输

Communication on the Inference Side: Custom All-Reduce and KV Cache Transfer


通信与互联(06):nccl-tests、调优与排障——从带宽曲线到 hang

nccl-tests, Tuning and Debugging Hangs: From Bandwidth Curves to Flight Recorder


通信与互联(05):PyTorch 的通信栈——ProcessGroupNCCL、stream 语义与计算通信重叠

PyTorch's Communication Stack: ProcessGroupNCCL, Stream Semantics, and Compute-Communication Overlap


通信与互联(04):NCCL 架构——拓扑探测、channel、算法与协议

NCCL Architecture: Topology Detection, Channels, Algorithms and Protocols


通信与互联(03):RDMA 与 GPUDirect——绕过 CPU 和主机内存的数据通路

RDMA and GPUDirect: Bypassing the CPU and Host Memory


通信与互联(02):硬件互联——PCIe、NVLink、NVSwitch 与网络拓扑

Hardware Interconnect: PCIe, NVLink, NVSwitch and Network Topology


通信与互联(01):集合通信原语与代价模型——α-β 模型与 ring all-reduce

Collective Communication Primitives and the Alpha-Beta Cost Model: Deriving Ring All-Reduce


通信与互联:从 NCCL 到 RDMA(总纲)

Communication and Interconnect for AI-Infra, from NCCL to RDMA


RDMA

AI 平台工程(05):网络与存储——RDMA 进容器、并行文件系统与 checkpoint I/O

Networking and Storage: RDMA in Containers, Parallel File Systems and Checkpoint I/O


通信与互联(08):MoE 的通信——all-to-all、DeepEP 与 GPU 发起的通信

Communication for MoE: All-to-All, DeepEP and GPU-Initiated Networking


通信与互联(07):推理侧的通信——custom all-reduce 与 KV 传输

Communication on the Inference Side: Custom All-Reduce and KV Cache Transfer


通信与互联(06):nccl-tests、调优与排障——从带宽曲线到 hang

nccl-tests, Tuning and Debugging Hangs: From Bandwidth Curves to Flight Recorder


通信与互联(05):PyTorch 的通信栈——ProcessGroupNCCL、stream 语义与计算通信重叠

PyTorch's Communication Stack: ProcessGroupNCCL, Stream Semantics, and Compute-Communication Overlap


通信与互联(04):NCCL 架构——拓扑探测、channel、算法与协议

NCCL Architecture: Topology Detection, Channels, Algorithms and Protocols


通信与互联(03):RDMA 与 GPUDirect——绕过 CPU 和主机内存的数据通路

RDMA and GPUDirect: Bypassing the CPU and Host Memory


通信与互联(02):硬件互联——PCIe、NVLink、NVSwitch 与网络拓扑

Hardware Interconnect: PCIe, NVLink, NVSwitch and Network Topology


通信与互联(01):集合通信原语与代价模型——α-β 模型与 ring all-reduce

Collective Communication Primitives and the Alpha-Beta Cost Model: Deriving Ring All-Reduce


通信与互联:从 NCCL 到 RDMA(总纲)

Communication and Interconnect for AI-Infra, from NCCL to RDMA


Megatron

RL 后训练基础设施(04):权重同步——从训练分片到推理分片

Weight Synchronization: From Training Shards to Inference Shards


RL 后训练基础设施:rollout 与训练如何共享一组 GPU(总纲)

RL Post-Training Infrastructure: How Rollout and Training Share the Same GPUs


大规模训练工程(08):长时训练的可观测与运维——从指标到 hang 排查

Observability and Operations for Long-Running Training


大规模训练工程(07):训练稳定性与数据管线——loss spike、梯度范数、数据混合与流式加载

Training Stability and the Data Pipeline


大规模训练工程(06):容错与弹性——故障率数学、straggler、SDC 与弹性训练

Fault Tolerance and Elasticity: Failure Math, Stragglers, SDC and Elastic Training


大规模训练工程(05):分布式 checkpoint——格式、异步保存与重分片恢复

Distributed Checkpoint: Format, Async Save and Resharding


大规模训练工程(04):千卡配置实战——并行搭配、micro-batch、激活重计算与 MFU 调优

Configuring a Thousand-GPU Job: Parallelism, Micro-batch, Recompute and MFU


大规模训练工程(03):三个框架——Megatron-LM、DeepSpeed 与 torchtitan 的架构对比与源码导读

Megatron-LM, DeepSpeed and torchtitan: Architecture and Source Guide


大规模训练工程(02):并行策略全景——每种并行切的是哪种状态

A Map of Parallelism: Which State Does Each Strategy Shard


大规模训练工程(01):训练任务的状态解剖——显存账与 MFU

Anatomy of Training State: Memory Accounting and MFU


大规模训练工程:从并行策略到容错恢复(总纲)

Large-Scale Training Engineering, from Parallelism to Fault Tolerance


Distributed Training

RL 后训练基础设施(08):配置、可观测与排障——从一张卡的比例到一条 hang 的排查

Configuration, Observability and Troubleshooting for RL Post-Training Systems


RL 后训练基础设施(05):异步与 off-policy——把同步的墙拆掉之后要补什么

Asynchrony and Off-Policy: What You Owe After Tearing Down the Synchronization Wall


RL 后训练基础设施(02):系统形态——共置、分离与异步

RL System Topologies: Colocated, Disaggregated and Asynchronous


RL 后训练基础设施(01):负载画像——一步 RL 里发生什么

Anatomy of an RL Step: Rollout, Reward and Train


RL 后训练基础设施:rollout 与训练如何共享一组 GPU(总纲)

RL Post-Training Infrastructure: How Rollout and Training Share the Same GPUs


大规模训练工程(08):长时训练的可观测与运维——从指标到 hang 排查

Observability and Operations for Long-Running Training


大规模训练工程(07):训练稳定性与数据管线——loss spike、梯度范数、数据混合与流式加载

Training Stability and the Data Pipeline


大规模训练工程(06):容错与弹性——故障率数学、straggler、SDC 与弹性训练

Fault Tolerance and Elasticity: Failure Math, Stragglers, SDC and Elastic Training


大规模训练工程(05):分布式 checkpoint——格式、异步保存与重分片恢复

Distributed Checkpoint: Format, Async Save and Resharding


大规模训练工程(04):千卡配置实战——并行搭配、micro-batch、激活重计算与 MFU 调优

Configuring a Thousand-GPU Job: Parallelism, Micro-batch, Recompute and MFU


大规模训练工程(03):三个框架——Megatron-LM、DeepSpeed 与 torchtitan 的架构对比与源码导读

Megatron-LM, DeepSpeed and torchtitan: Architecture and Source Guide


大规模训练工程(02):并行策略全景——每种并行切的是哪种状态

A Map of Parallelism: Which State Does Each Strategy Shard


大规模训练工程(01):训练任务的状态解剖——显存账与 MFU

Anatomy of Training State: Memory Accounting and MFU


大规模训练工程:从并行策略到容错恢复(总纲)

Large-Scale Training Engineering, from Parallelism to Fault Tolerance


vLLM

AI-Infra 开源贡献指南(02):找到切入点——从 issue、RFC 到性能回归

Finding Your Entry Point: Issues, RFCs, Roadmaps, CI Failures and Regressions


AI-Infra 开源贡献指南(01):读懂一个百万行的代码库

Reading a Million-Line Codebase: Maps, Entry Points, Symbols, Tests and History


AI-Infra 开源贡献指南(总纲)

A Guide to Contributing to AI-Infra Open Source Projects


AI 平台工程(06):Serving 平台——从 InferenceService 到 llm-d

Serving Platforms: KServe, Triton, Ray Serve, LeaderWorkerSet and llm-d


RL 后训练基础设施(08):配置、可观测与排障——从一张卡的比例到一条 hang 的排查

Configuration, Observability and Troubleshooting for RL Post-Training Systems


RL 后训练基础设施(07):verl 源码导读——从一个 GRPO 配置追到每个 worker

Reading verl: From One GRPO Config to Every Worker


RL 后训练基础设施(06):Agentic rollout——多轮、工具、沙箱与环境服务

Agentic Rollout: Multi-Turn Trajectories, Tools, Sandboxes and Environment Services


RL 后训练基础设施(04):权重同步——从训练分片到推理分片

Weight Synchronization: From Training Shards to Inference Shards


RL 后训练基础设施(03):共置——训练器与推理引擎在同一组 GPU 上共存

Colocation: Handing GPU Memory Back and Forth Between Trainer and Rollout Engine


RL 后训练基础设施(02):系统形态——共置、分离与异步

RL System Topologies: Colocated, Disaggregated and Asynchronous


RL 后训练基础设施(01):负载画像——一步 RL 里发生什么

Anatomy of an RL Step: Rollout, Reward and Train


RL 后训练基础设施:rollout 与训练如何共享一组 GPU(总纲)

RL Post-Training Infrastructure: How Rollout and Training Share the Same GPUs


×