Your Vertex AI custom training job is failing with an out-of-memory error on a single GPU. You need to reduce memory usage without changing the model architecture. Which approach should you try first?
Decreasing batch size directly reduces the memory footprint of activations and gradients, easily lowering GPU memory usage.
Why this answer
Decreasing the batch size is the simplest and most direct approach to reduce GPU memory usage for a custom training job. It linearly reduces the memory needed for activations and gradients. While mixed precision can also reduce memory, it may introduce numerical precision issues and only works on compatible hardware, so decreasing batch size should be attempted first.