Google Professional Machine Learning Engineer Question 406
Select 3Google Cloud PlatformYou are designing a machine learning pipeline for a large-scale image classification problem using TensorFlow Extended (TFX) on Google Cloud. The pipeline must preprocess a large dataset, train a TensorFlow model, and deploy the model for serving. The preprocessing step involves complex transformations and must scale to handle terabytes of data. Which combination of TFX components and Google Cloud services would be most appropriate for this pipeline?
- A
Use the ExampleGen component to ingest data and configure it to read from a Google Cloud Storage bucket.
- B
Use the Transform component to preprocess data and run the transformations on Dataflow.
- C
Use the Trainer component to train the TensorFlow model on a Google Kubernetes Engine (GKE) cluster.
- D
Use the Evaluator component to deploy the model directly to Vertex AI for serving.
- E
Use the Pusher component to deploy the model to TensorFlow Serving running on Google Kubernetes Engine (GKE).
Show answer and explanation
Correct answers: A, B, E
Explanation
The correct approach to designing a scalable TFX pipeline on Google Cloud involves leveraging well-suited components and services. ExampleGen is used for ingesting large datasets, Transform enables distributed data preprocessing using Dataflow, and the Pusher component facilitates deploying the trained model to TensorFlow Serving on GKE. These selections align with the scalability and modularity goals of TFX pipelines, while other options involve either incorrect usage of components or suboptimal practices.
- A. Correct.
Correct: ExampleGen is used to ingest data into the TFX pipeline, and configuring it to read from a Google Cloud Storage bucket allows it to handle large-scale datasets stored in GCS.
- B. Correct.
Correct: The Transform component is designed for data preprocessing, and using Dataflow enables distributed execution of complex transformations on large datasets.
- C. Incorrect.
Incorrect: While GKE can be used for training, it is not the standard practice in TFX pipelines. The Trainer component typically runs on AI Platform (now Vertex AI), which is optimized for TensorFlow training jobs.
- D. Incorrect.
Incorrect: The Evaluator component is used to validate and analyze model performance, not for deploying models. Deployment is handled by the Pusher component or other deployment tools.
- E. Correct.
Correct: The Pusher component is specifically designed to deploy models, and TensorFlow Serving on GKE is a valid target for serving the trained model.