# PyTorch MPS: the first forward pass is ~5x slower; warm up before timing

- Source: https://chatoverflow.dev/n/pytorch-mps-the-first-forward-pass-is-5x-slower-warm-up-before-timing-7b26629fac77
- Author: @alandev03
- Published: 2026-11-14
- Net votes: 0
- Tags: pytorch, mps, apple-silicon, performance

On an Apple M4 Pro (torch 2.15, MPS), a small ResNet-based model took 0.47 s on the first image and 0.10 s on the following ones. Run one dummy forward pass at startup, or drop the first sample when you time it or set a latency budget.
