The speed-up that was not in the software

Correction, 2026-10-22. The speed-up was in software after all: ours, not the libraries’. Our training loop empties the CUDA cache on every step, and May’s Colab loop did not. Keeping the cache brings KG4FM to 2.96 s a step on Vertex, within 4% of Colab, and cuts Run 3 B’s step by 21% (#1113, fix #1171, and the 2026-10-22 entry “The cache we emptied every step”). Both guesses at the end of this entry were wrong. What this entry measured stands: torch 2.10 on its own is worth only 1–4%.

Yesterday’s entry split our Vertex slowdown into two factors. Against the May Colab run on the same graph, batch and card, about 1.56× looked like the software stack, May’s torch 2.10 against our image’s torch 2.1, and the rest was Run 3’s graph. The readout said, in one line near the end, that the platform could be part of the 1.56× and only a Vertex run of a new image could tell. Today was that run.

The answer

I built the May stack into the training image (torch 2.10, CUDA 12.8, PyG 2.7), and Richard approved about $6 to time it. To run it without moving :latest, which every worker submits, the queue got a small option that pins one task to one image by digest. The same two jobs as yesterday, on the new image:

  • KG4FM: 4.27 s a step, against 4.45 on the old image and 2.85 on Colab in May.
  • Run 3 B’s graph: 6.67, against 6.76.

That is 4% and 1%. The new image is still one and a half times slower than Colab on the same graph, batch and GPU model. Whatever makes Colab faster is not torch, CUDA or PyG. Scoring Run 3 B’s checkpoint on 300 test triples gave byte-identical files on both images, so at least nothing broke either. All four jobs cost about $2.35.

Yesterday’s phrasing gave the software the whole 1.56× because the software was the difference I could see. The test was cheap, and it said no.

What the free half found

Before spending anything I built the image on the workstation and ran every PDR2 test script in it on CPU. Four of fourteen failed, and every failure was real:

  • pip refused to install anything: the new base is Ubuntu 24.04, whose Python is marked as managed by apt.
  • Every fine-tune would have crashed at its first step: torch 2.7 removed an argument the learning-rate scheduler was given.
  • One was silent. PyG 2.5 and later write their own propagate() onto any message-passing class that does not define one itself. Our signed-message layer, mechanism (b), the next pilot, inherited the fast path from its parent. Under PyG 2.7 it quietly ran PyG’s generic path with the edges reversed, and raised no error. Every image so far used PyG 2.4, so no past result is touched.
  • The fourth was a float near-tie one ulp apart, which a test had required to match exactly.

Two more turned up along the way. Checkpoints saved under numpy 2 cannot be loaded by our current images, so a rollback would have stranded them; the new image pins numpy 1.26. And every image we have built ignored its own version ranges, because the shell read each unquoted >= in the Dockerfile as a redirect.

Where it leaves us

I recommended against moving :latest for 1%. The image change is parked, and its fixes are a no-op on today’s stack, so they can merge on their own whenever Richard likes. The 1.5× is still on the table. My two guesses are the GPU’s clocks or power on Vertex’s machines, or the way our loader numbers KG4FM’s entities, which changes how the kernel touches memory. One is a free log line and the other a one-dollar job. Both are guesses, and I have said so.