翻篇收录说明
翻篇网页快照

What is Pathways? Single-controller training for large models - Google Developers Blog

https://developers.googleblog.com/what-is-pathways-single-controller-training-for-large-models/

最近抓取:2026-12-04 06:18:17(北京时间)

最近内容变化:2026-12-01 05:45:32(北京时间)

这是最近一次有效抓取的文本快照,不含网页脚本、图片和动态交互内容。实际网页可能已更新。

访问原网页

页面简介

Discover how Pathways on Google Cloud enables single-client distributed training for large AI models, addressing scaling and coordination challenges across TPU clusters.

正文摘录

What is Pathways? Single-controller training for large models NOV. 9, 2026 Sujeeth Jinesh Software Engineer Shaurya Gupta Software Engineer Luke Baumann Software Engineer Monica Song Product Manager Ivan Nardini AI Developer Relations Akanksha Gupta Software Engineer Anthony Owusu Software Engineer Jing Yang Software Engineer Sadi Kneipp Software Engineer Yu Li Software Engineer Share Facebook Twitter LinkedIn Mail Sorry, your browser doesn't support playback for this video TLDRToday, we announce the General Availability of Pathways on Google Cloud Platform. In this post, you will learn about Pathways, the distributed system Google built to train its own large models, including Gemini. We discuss how Pathways addresses the coordination challenge by introducing one client that describes the whole computation as a graph, and how the distributed runtime places it, moves the tensors, and keeps the accelerators busy.Most large-model training runs as Single Program, Multiple Data (SPMD) programs. Every accelerator runs the same program in lockstep and coordinates through collectives like AllReduce.It works well when your job is the same program running on every device. It struggles when the job is no longer uniform, like a pipeline whose stages wait on each other or an RL loop where a sampler, a reward model, and a trainer are different programs that have to overlap.Large runs also have to survive hardware failures, which interrupted Gemini 2.5 training multiple times per hour. In SPMD, one lost machine stops every process and sends the run back to its last checkpoint. In each case, the challenge is coordination. You have to decide what runs where and in what order, how tensors move between devices, and how the job keeps going when a machine drops out.In this post of the series “Pathways on Google Cloud”, you will learn about Pathways, the distributed system Google built to train its own large models, including Gemini. The post discusses how Pathways addresses the coordination challenge by introducing one client that describes the whole computation as a graph, and how the distributed runtime places it, moves the tensors, and keeps the accelerators busy.By the end, you'll know where SPMD is suboptimal, what single-controller execution changes, and how Pathways coordinates a whole training job across a cluster.When scaling becomes a coordination problemIf you train PyTorch models, you almost certainly use Distributed Data Parallel (DDP) or Fully Sharded Data Parallel (FSDP). DDP runs a copy of your script on every accelerator and averages gradients with a collective operation such as AllReduce. FSDP shards parameters, gradients, and optimizer states across workers so that the model fits at all. Sorry, your browser doesn't support playback for this video Figure 1: One training step with DDP and with FSDP. DDP and FSDP both follow the Single Program, Multiple Data (SPMD) execution model. Every process runs the same copy of your script, owns its accelerators for the whole run, and moves in lockstep with the others, because the only way they coordinate is through collectives like AllReduce. Inside one tightly connected group of accelerators those collectives run over a fast interconnect and are cheap. Scale the job across groups and the same collectives cross the datacenter network, which is far slower. On a TPU v5p, for example, each chip gets 1,200 GB/s of bidirectional chip-to-chip bandwidth inside its group, but only 50 Gb/s (gigabits, about 6 GB/s) to the datacenter network which is roughly two orders of magnitude less.And because every step blocks on its collectives, that communication lands directly in step time. The more groups you span, the larger the share of each step spent moving data, so throughput grows slower than the number of accelerators you add.As long as your training job is one program that fills the hardware you give it, this execution model fits well. You write your model as if there were one device, and the collectives do the rest. But fitting a model into memory is only part of the problem. Keeping every accelerator busy is the harder part, and this is where the SPMD model starts to show its limits.Take pipeline parallelism as an example. You split a model into blocks across devices, and each device now runs different code over smaller micro-batches. Activations flow forward, activation gradients flow back, and while device 0 works on the first micro-batch, devices 1 and 2 wait. Apart from the idle accelerators you keep paying for, this drops utilization and throughput, even though every device has work in the steady state. Sorry, your browser doesn't support playback for this video Figure 2: Three devices, four micro-batches. The hatched slots are the pipeline bubble. Another example is RL post-training for an LLM. You have a sampler that generates rollouts, a reward model that scores them, and a trainer that updates the policy and sends the new weights back to the sampler. These are three different programs that should overlap; otherwise the sampler is idle while the trainer runs, and the trainer is idle while the sampler generates. Sorry, your browser doesn't support playback for this video Figure 3: The same RL loop, run one after another and overlapped (toy schedule). In both scenarios, the job is now several different programs running on different devices, and their dependencies can no longer be managed through a single collective. You now have to coordinate which devices share which tensors, which processes run while others are still finishing, and how early to enqueue the next buffer so an accelerator never waits for input. Because each worker only has visibility into its local devices and data, no individual process can manage all of these dependencies itself. That has several consequences.First, because each process owns its accelerators for the whole run and every collective blocks until all devices finish, one failed machine prevents the collective from completing and stops the entire job, forcing a restart from the last checkpoint. You cannot add devices mid-run, and you cannot give devices back.Second, because each process holds its accelerators from start to finish, capacity can't move to where it's needed. Within one job, a stage that needs fewer chips than another still keeps the extra ones. They sit idle, you keep paying for them, and no other part of the job can use them until the run ends. Across a team, the same happens at cluster scale. Every job owns its accelerators for as long as it runs, so sharing a cluster means splitting it into per-job allocations, and each new job brings up its own processes on its own hosts.Finally, the development process itself gets harder. On one host you iterate fast because you run the script, drop into a Python shell, set a breakpoint, and debug. This is not true once the job spans many hosts. You need a launcher to push your script to every host, you hit coordination bugs that never showed up on one machine, and there's no single process to break into. When something hangs, each worker is stuck at a collective waiting for the others, with no one place that shows the whole job.So the common challenge here is the coordination itself. As soon as the job stops being one program in lockstep, you have to decide what runs where, in what order, and how tensors get from one device to the next.One way to describe this is as a graph, where each block is a node, each tensor that moves between blocks is an edge, and the devices are where the nodes are placed. You can wire that graph up by hand in SPMD, one process at a time. But what if a single client declared that graph, including what each block does, what it needs, and where it runs, and a distributed runtime handled the transfers, dependencies, and ordering along its edges? Sorry, your browser doesn't support playback for this video Figure 3: The same RL loop, run one after another and overlapped (toy schedule). That is the idea behind Pathways, the distributed system Google built to train its own largest models, including Gemini. Pathways runs JAX programs on TPUs and it is available on Google Cloud.Coordinating the entire computation with PathwaysWith Pathways, you define the end-to-end computation from a single Python client, without writing custom coordination code, and a distributed runtime executes it. That client is decoupled from the hardware. It runs on an ordinary CPU machine and you write your program against virtual devices; a resource manager maps them onto real chips, and a worker on each accelerator host runs the compiled programs it receives. Sorry, your browser doesn't support playback for this video Figure 5: Virtual devices, the resource manager, and a remap after a host failure. Because your code refers to virtual devices rather than physical ones, the runtime is flexible to allow users to change the devices used for a given computation. This allows you to stay in control while the runtime handles the mapping to hardware. In an RL loop, for example, the trainer and the samplers rarely want the same number of chips, so you can give the sampler stage more chips by asking for more virtual devices.Also, the same capability helps when a host fails or the hardware isn't ready yet. If a host dies, the resource manager remaps the work onto healthy chips and the run keeps going instead of relaunching the whole job, which is the basis for elastic training. And because the program targets virtual devices, compilation can start before the physical chips are provisioned, so setup overlaps with provisioning instead of waiting on it.The resource manager owning the chips also means one Pathways cluster can serve several clients, so researchers on a team can share its capacity. With the Shared Pathways Service, the cluster stays up as a long running service, which lets you develop interactively on TPUs hosted on GKE. Each client connects on demand from a laptop or VM, gets its own slices (groups