nerdexam
Google

PROFESSIONAL-MACHINE-LEARNING-ENGINEER · Question #55

You need to train a computer vision model that predicts the type of government ID present in a given image using a GPU-powered virtual machine on Compute Engine. You use the following parameters…

The correct answer is B. Reduce the batch size. To fix memory overflow you need to reduce batch size also reduce input resolution is valid but reducing image size can harm model performance.

Submitted by jordan8· Apr 18, 2026ML model development

Question

You need to train a computer vision model that predicts the type of government ID present in a given image using a GPU-powered virtual machine on Compute Engine. You use the following parameters: - Optimizer: SGD - Image shape = 224 ֳ --224 - Batch size = 64 - Epochs = 10 - Verbose =2 During training you encounter the following error: ResourceExhaustedError: Out Of tensor. What should you do? Memory (OOM) when allocating

Options

  • AChange the optimizer.
  • BReduce the batch size.
  • CChange the learning rate.
  • DReduce the image shape.

How the community answered

(42 responses)
  • A
    2% (1)
  • B
    88% (37)
  • C
    7% (3)
  • D
    2% (1)

Explanation

To fix memory overflow you need to reduce batch size also reduce input resolution is valid but reducing image size can harm model performance.

Topics

#GPU memory#Out of memory (OOM)#Batch size#Deep learning training

Community Discussion

No community discussion yet for this question.

Full PROFESSIONAL-MACHINE-LEARNING-ENGINEER Practice