nerdexam
Google

PROFESSIONAL-MACHINE-LEARNING-ENGINEER · Question #243

You need to use TensorFlow to train an image classification model. Your dataset is located in a Cloud Storage directory and contains millions of labeled images. Before training the model, you need…

The correct answer is A. 1. Create a Dataflow job that creates sharded TFRecord files in a Cloud Storage directory. For efficient, scalable, and low-maintenance preprocessing of millions of images for TensorFlow training, converting them into sharded TFRecord files using Dataflow is the recommended approach.

Submitted by yousef_jo· Apr 18, 2026Data processing and feature engineering

Question

You need to use TensorFlow to train an image classification model. Your dataset is located in a Cloud Storage directory and contains millions of labeled images. Before training the model, you need to prepare the data. You want the data preprocessing and model training workflow to be as efficient, scalable, and low maintenance as possible. What should you do?

Options

  • A
    1. Create a Dataflow job that creates sharded TFRecord files in a Cloud Storage directory.
  • B
    1. Create a Dataflow job that moves the images into multiple Cloud Storage directories, where
  • C
    1. Create a Jupyter notebook that uses an nt-standard-64 V100 GPU Vertex AI Workbench
  • D
    1. Create a Jupyter notebook that uses an n1-standard-64, V100 GPU Vertex AI Workbench

How the community answered

(55 responses)
  • A
    82% (45)
  • B
    2% (1)
  • C
    5% (3)
  • D
    11% (6)

Why each option

For efficient, scalable, and low-maintenance preprocessing of millions of images for TensorFlow training, converting them into sharded TFRecord files using Dataflow is the recommended approach.

A1. Create a Dataflow job that creates sharded TFRecord files in a Cloud Storage directory.Correct

Using a Dataflow job to create sharded TFRecord files is highly scalable and efficient for processing millions of images, as TFRecords are optimized for TensorFlow data input pipelines and Dataflow handles distributed processing with low maintenance. This significantly improves training efficiency and throughput.

B1. Create a Dataflow job that moves the images into multiple Cloud Storage directories, where

While distributing images across directories might help, it doesn't provide the I/O and processing efficiency benefits of TFRecord files for TensorFlow training, nor does it inherently create a low-maintenance, scalable preprocessing solution.

C1. Create a Jupyter notebook that uses an nt-standard-64 V100 GPU Vertex AI Workbench

A Jupyter notebook on a single Vertex AI Workbench instance, even with a powerful GPU, is not a scalable solution for preprocessing millions of images in a low-maintenance, distributed fashion and is primarily for interactive development.

D1. Create a Jupyter notebook that uses an n1-standard-64, V100 GPU Vertex AI Workbench

Similar to C, a Jupyter notebook on a single Vertex AI Workbench instance is not designed for scalable, distributed preprocessing of millions of images, regardless of the instance type.

Concept tested: Scalable image data preprocessing, TFRecord files, and Dataflow

Source: https://www.tensorflow.org/tutorials/load_data/tfrecord

Topics

#Data Preprocessing#Cloud Dataflow#TFRecord#Scalable Data

Community Discussion

No community discussion yet for this question.

Full PROFESSIONAL-MACHINE-LEARNING-ENGINEER Practice