Sample questions Flashcards

1
Q

Your team works on a smart city project with wireless sensor networks and a set of gateways for transmitting sensor data. You have to cope with many design choices. You want, for each of the problems under study, to find the simplest solution.
For example, it is necessary to decide on the placement of nodes so that the result is the most economical and inclusive. An algorithm without data tagging must be used.
Which of the following choices do you think is the most suitable?

A. Create a Tensorflow model using Matrix factorization
B. Use Recommendations AI
C. Import the Product Catalog
D. Record / Import User events

A

Correct answers: B
Q-learning is an RL Reinforcement Learning algorithm. RL provides a software agent that evaluates possible solutions through a progressive reward in repeated attempts. It does not need to provide labels. But it requires a lot of data and several trials and the possibility to evaluate the validity of each attempt.
The main RL algorithms are deep Q-network (DQN) and deep deterministic policy gradient (DDPG).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Your client has an e-commerce site for commercial spare parts for cars with competitive prices. It started with the small car sector but is continually adding products. Since 80% of them operate in a B2B market, he wants to ensure that his customers are encouraged to use the new products that he gradually offers on the site quickly and profitably.
Which GCP service can be valuable in this regard and in what way?

A

Correct answers: B
Recommendations AI is a ready-to-use service for all the requirements shown in the question. You don’t need to create models, tune, train, all that is done by the service with your data. Also, the delivery is automatically done, with high-quality recommendations via web, mobile, email. So, it can be used directly on websites during user sessions.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

You are working on an NLP model. So, you are dealing with words and sentences, not numbers. Your problem is to categorize these words and make sense of them. Your manager told you that you have to use embeddings.
Which of the following techniques are not related to embeddings?

A. Count Vector
B. TF-IDF Vector
C. Co-Occurrence Matrix
D. CoVariance Matrix

A

Correct Answer: D
Covariance matrices are square matrices with the covariance between each pair of elements.
It measures how much the change of one with respect to another is related.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

You are a junior Data Scientist and are working on a deep neural network model with Tensorflow to optimize the level of customer satisfaction for after-sales services with the goal of creating greater client loyalty.
You are struggling with your model (learning rates, hidden layers and nodes selection) for optimizing processing and to let it converge in the fastest way.
Which is your problem, in ML language?

A. Cross-Validation
B. Regularization
C. Hyperparameter tuning
D. drift detection management

A

Correct Answer: C
ML training Manages three main data categories:

Training data also called examples or records. It is the main input for model configuration and, in supervised learning, presents labels, that is the correct answers based on past experience. Input data is used to build the model but will not be part of the model.
Parameters are Instead the variables to be found to solve the riddle. They are part of the final model and they make the difference among similar models of the same type.
Hyperparameters are configuration variables that influence the training process itself: Learning rate, hidden layers number, number of epochs, regularization, batch size are all examples of hyperparameters.
Hyperparameters tuning is made during the training job and used to be a manual and tedious process, made by running multiple trials with different values.
The time required to train and test a model can depend upon the choice of its hyperparameters.
With Vertex AI you just need to prepare a simple YAML configuration without coding.
A is wrong because Cross Validation is related to the input data organization for training, test, and validation
B is wrong because Regularization is related to feature management and overfitting
D is wrong because drift management is when data distribution changes and you have to adjust the

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Which of these GCP services can you use?

A. Dialogflow
B. Document AI
C. Cloud Natural Language API
D. AutoML

A

Correct answers: B
Document AI is the perfect solution because it is a complete service for the automatic understanding of documents and their management.
It integrates computer natural language processing, OCR, and vision and can create pre-trained templates aimed at intelligent document administration.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

You work for a large retail company. You are preparing a marketing model. The model will have to make predictions based on the historical and analytical data of the e-commerce site (analytics-360). In particular, customer loyalty and remarketing possibilities should be studied. You work on historical tabular data. You want to quickly create an optimal model, both from the point of view of the algorithm used and the tuning and life cycle of the model.
What are the two best services you can use?

A. AutoML Tables
B. BigQuery ML
C. Vertex AI
D. GKE

A

Correct answers: A and C
AutoML Tables can select the best model for your needs without having to experiment.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Your company operates an innovative auction site for furniture from all times. You have to create a series of ML models that allow you, starting from the photos, to establish the period, style and type of the piece of furniture depicted.
Furthermore, the model must be able to determine whether the furniture is interesting and require it to be subject to a more detailed estimate. You want Google Cloud to help you reach this ambitious goal faster.
Which of the following services do you think is the most suitable?

A. AutoML Vision Edge
B. Vision AI
C. Video AI
D. AutoML Vision

A

Correct Answer: D
Vision AI uses pre-trained models trained by Google. This is powerful, but not enough.
But AutoML Vision lets you train models to classify your images with your own characteristics and labels. So, you can tailor your work as you want.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

You are using an AI Platform, and you are working with a series of demanding training jobs. So, you want to use TPUs instead of CPUs. You are not using Docker images or custom containers.
What is the simplest configuration to indicate if you do not have particular needs to customize in the YAML configuration file?
A. Use scale-tier to BASIC_TPU
B. Set Master-machine-type
C. Set Worker-machine-type
D. Set parameterServerType

A

Correct Answer: A
AI Platform lets you perform distributed training and serving with accelerators (TPUs and GPUs).
You usually must specify the number and types of machines you need for master and worker VMs. But you can also use scale tiers that are predefined cluster specifications.
In our case,
scale-tier=BASIC_TPU
covers all the given requirements.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

You work for an industrial company that wants to improve its quality system. It has developed its own deep neural network model with Tensorflow to identify the semi-finished products to be discarded with images taken from the production lines in the various production phases.
You need to monitor the performance of your models and let them go faster.
Which is the best solution that you can adopt?
A. TFProfiler
B. TF function
C. TF Trace
D. TF Debugger
E. TF Checkpoint

A

Correct Answer: A
TensorFlow Profiler is a tool for checking the performance of your TensorFlow models and helping you to obtain an optimized version.
In TensorFlow 2, the default is eager execution. So, one-off operations are faster, but recurring ones may be slower. So, you need to optimize the model.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Your team needs to create a model for managing security in restricted areas of a campus.
Everything that happens in these areas is filmed and, instead of having a physical surveillance service, the videos must be managed by a model capable of intercepting unauthorized people and vehicles, especially at particular times.
What are the GCP services that allow you to achieve all this with minimal effort?
A. AI Infrastructure
B. Cloud Video Intelligence AI
C. AutoML Video Intelligence Classification
D. Vision AI

A

Correct Answer: C
AutoML Video Intelligence is a service that allows you to customize the pre-trained Video intelligence GCP system according to your specific needs.

In particular, AutoML Video Intelligence Object Tracking allows you to identify and locate particular entities of interest to you with your specific tags.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

With your team you have to decide the strategy for implementing an online forecasting model in production.
This template needs to work with both a web interface as well as DialogFlow and Google Assistant and a lot of requests are expected.
You are concerned that the final system is not efficient and scalable enough, and you are looking for the simplest and most managed GCP solution.
Which of these can be the solution?
A. AI Platform Prediction
B. GKE e TensorFlow
C. VMs and Autoscaling Groups with Application LB
D. Kubeflow

A

Correct Answer: A
The AI Platform Prediction service is fully managed and automatically scales machine learning models in the cloud
The service supports both online prediction and batch prediction.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

5% off on GCP courses| Full Training Package | Use Coupon: WHIZ25GCP |Enroll Now

Cloud Computing

Cyber Security

Big Data

Agile

Business Analysis

Linux

IT Ops

Others

Whizlabs Blog

BlogGoogle Cloud25 Free Questions – Google Cloud Certified Professional Machine Learning Engineer

Free Questions on GCPC Professional Machine Learning Engineer

25 Free Questions – Google Cloud Certified Professional Machine Learning Engineer

By

Jeevitha TP

GOOGLE CLOUD

Google Cloud Certified Professional Machine Learning Engineer Exam requires good knowledge of Google Cloud and a working understanding of proven ML models and techniques. If you are already an experienced Machine Learning Engineer, this exam may look easy to you.

Practicing with real exam questions will make you familiar with the Google ML engineer exam patterns. Whizlabs offers one of the bestpractice questionsfor this certification exam (You can also try Whizlabs free test). Below is the sample 25 questions to help you to understand the exam format and type of questions.

Google Cloud Certified Professional Machine Learning Engineer Questions

Here is the list of 25 questions for the Google Cloud Certified Professional Machine Learning Engineer Exam Questions.

Frame ML problems

Q 1. Your team works on a smart city project with wireless sensor networks and a set of gateways for transmitting sensor data. You have to cope with many design choices. You want, for each of the problems under study, to find the simplest solution.
For example, it is necessary to decide on the placement of nodes so that the result is the most economical and inclusive. An algorithm without data tagging must be used.
Which of the following choices do you think is the most suitable?

A. K-means
B. Q-learning
C. K-Nearest Neighbors
D. Support Vector Machine(SVM)

Correct answers: B
Q-learning is an RL Reinforcement Learning algorithm. RL provides a software agent that evaluates possible solutions through a progressive reward in repeated attempts. It does not need to provide labels. But it requires a lot of data and several trials and the possibility to evaluate the validity of each attempt.
The main RL algorithms are deep Q-network (DQN) and deep deterministic policy gradient (DDPG).

Types of Machine Learning

A is wrongbecause K-means is an unsupervised learning algorithm used for clustering problems. It is useful when you have to create similar groups of entities. So, even if there is no need to label data, it is not suitable for our scope.

C is wrongbecause K-NN is a supervised classification algorithm, therefore, labeled. New classifications are made by finding the closest known examples.

D is wrongbecause SVM is a supervised ML algorithm, too. K-NN distances are computed. These distances are not between data points, but with a hyper-plane, that better divides different classifications.

Q 2. Your client has an e-commerce site for commercial spare parts for cars with competitive prices. It started with the small car sector but is continually adding products. Since 80% of them operate in a B2B market, he wants to ensure that his customers are encouraged to use the new products that he gradually offers on the site quickly and profitably.
Which GCP service can be valuable in this regard and in what way?

A. Create a Tensorflow model using Matrix factorization
B. Use Recommendations AI
C. Import the Product Catalog
D. Record / Import User events

Correct answers: B
Recommendations AI is a ready-to-use service for all the requirements shown in the question. You don’t need to create models, tune, train, all that is done by the service with your data. Also, the delivery is automatically done, with high-quality recommendations via web, mobile, email. So, it can be used directly on websites during user sessions.

Recommendations AI

A could be OK, but it needs a lot of work.
C and Ddeal only with data management, not creating recommendations.
For any further detail:

Q 3. You are working on an NLP model. So, you are dealing with words and sentences, not numbers. Your problem is to categorize these words and make sense of them. Your manager told you that you have to use embeddings.
Which of the following techniques are not related to embeddings?

A. Count Vector
B. TF-IDF Vector
C. Co-Occurrence Matrix
D. CoVariance Matrix

Correct Answer: D
Covariance matrices are square matrices with the covariance between each pair of elements.
It measures how much the change of one with respect to another is related.

Covariance Matrices

All the others are embeddings:
A Count Vector gives a matrix with the count of every single word in every example. 0 if no occurrence. It is okay for small vocabularies.
TF-IDF vectorization counts words in the entire experiment, not a single example or sentence.
Co-Occurrence Matrix puts together words that occur together. So, it is more useful for text understanding.

Q 4. You are a junior Data Scientist and are working on a deep neural network model with Tensorflow to optimize the level of customer satisfaction for after-sales services with the goal of creating greater client loyalty.
You are struggling with your model (learning rates, hidden layers and nodes selection) for optimizing processing and to let it converge in the fastest way.
Which is your problem, in ML language?

A. Cross-Validation
B. Regularization
C. Hyperparameter tuning
D. drift detection management

Correct Answer: C
ML training Manages three main data categories:

Training dataalso called examples or records. It is the main input for model configuration and, in supervised learning, presents labels, that is the correct answers based on past experience. Input data is used to build the model but will not be part of the model.

Parametersare Instead the variables to be found to solve the riddle. They are part of the final model and they make the difference among similar models of the same type.

Hyperparametersare configuration variables that influence the training process itself: Learning rate, hidden layers number, number of epochs, regularization, batch size are all examples of hyperparameters.
Hyperparameters tuning is made during the training job and used to be a manual and tedious process, made by running multiple trials with different values.
The time required to train and test a model can depend upon the choice of its hyperparameters.
With Vertex AI you just need to prepare a simple YAML configuration without coding.
A is wrongbecause Cross Validation is related to the input data organization for training, test, and validation
B is wrongbecause Regularization is related to feature management and overfitting
D is wrongbecause drift management is when data distribution changes and you have to adjust the model

Architect ML solutions

Q 5. You work in a major banking institution. The Management has decided to rapidly launch a bank loan service, as the Government has created a series of “first home” facilities for the younger population.
The goal is to carry out the automatic management of the required documents (certificates, origin documents, legal information) so that the practice can be built and verified automatically using the data and documents provided by customers and can be managed in a short time and with the minimum contribution of the scarce specialized personnel.
Which of these GCP services can you use?

A. Dialogflow
B. Document AI
C. Cloud Natural Language API
D. AutoML

Correct answers: B
Document AIis the perfect solution because it is a complete service for the automatic understanding of documents and their management.
It integrates computer natural language processing, OCR, and vision and can create pre-trained templates aimed at intelligent document administration.

Dialogflow

A is wrongbecauseDialogflowis for speech Dialogs, not written documents.

C is wrongbecauseNLPis integrated into Document AI.

D is wrongbecause functions likeAutoMLare integrated into Document AI, too.

Q 6. You work for a large retail company. You are preparing a marketing model. The model will have to make predictions based on the historical and analytical data of the e-commerce site (analytics-360). In particular, customer loyalty and remarketing possibilities should be studied. You work on historical tabular data. You want to quickly create an optimal model, both from the point of view of the algorithm used and the tuning and life cycle of the model.
What are the two best services you can use?

A. AutoML Tables
B. BigQuery ML
C. Vertex AI
D. GKE

Correct answers: A and C
AutoML Tables can select the best model for your needs without having to experiment.
The architectures currently used (they are added at the same time) are:

Linear

Feedforward deep neural network

Gradient Boosted Decision Tree

AdaNet

Ensembles of various model architectures
In addition, AutoML Tables automatically performs feature engineering tasks, too, such as:

Normalization

Encoding and embeddings for categorical features.

Timestamp columns management (important in our case)
So, it has special features for time columns: for example, it can correctly split the input data into training, validation and testing.
Vertex AI is a new API that combines AutoML and AI Platform. You can use both AutoML training and custom training in the same environment.

Vertex AI

B is wrongbecause AutoML Tables has additional automated feature engineering and is integrated into Vertex AI.

D is wrongbecause GKE doesn’t supply all the ML features of Vertex AI. It is an advanced K8s managed environment.

Q 7. Your company operates an innovative auction site for furniture from all times. You have to create a series of ML models that allow you, starting from the photos, to establish the period, style and type of the piece of furniture depicted.
Furthermore, the model must be able to determine whether the furniture is interesting and require it to be subject to a more detailed estimate. You want Google Cloud to help you reach this ambitious goal faster.
Which of the following services do you think is the most suitable?

A. AutoML Vision Edge
B. Vision AI
C. Video AI
D. AutoML Vision

Correct Answer: D
Vision AIuses pre-trained models trained by Google. This is powerful, but not enough.
ButAutoML Visionlets you train models to classify your images with your own characteristics and labels. So, you can tailor your work as you want.
A is wrongbecauseAutoML Vision Edgeis for local devices.
C is wrongbecauseVideo AImanages videos, not pictures. It can extract metadata from any streaming video, get insights in a far shorter time, and let trigger events.

ML model Deployed

Q 8. You are using an AI Platform, and you are working with a series of demanding training jobs. So, you want to use TPUs instead of CPUs. You are not using Docker images or custom containers.
What is the simplest configuration to indicate if you do not have particular needs to customize in the YAML configuration file?

A. Use scale-tier to BASIC_TPU
B. Set Master-machine-type
C. Set Worker-machine-type
D. Set parameterServerType

Correct Answer: A
AI Platform lets you perform distributed training and serving with accelerators (TPUs and GPUs).
You usually must specify the number and types of machines you need for master and worker VMs. But you can also use scale tiers that are predefined cluster specifications.
In our case,
scale-tier=BASIC_TPU
covers all the given requirements.
B, C and D are wrongbecause it is not the easiest way. Moreover, workerType, parameterServerType, evaluatorType, workerCount, parameterServerCount, and evaluatorCount for jobs use custom containers and for TensorFlow jobs.
purpose.

TensorFlow

Q 9. You work for an industrial company that wants to improve its quality system. It has developed its own deep neural network model with Tensorflow to identify the semi-finished products to be discarded with images taken from the production lines in the various production phases.
You need to monitor the performance of your models and let them go faster.
Which is the best solution that you can adopt?

A. TFProfiler
B. TF function
C. TF Trace
D. TF Debugger
E. TF Checkpoint

Correct Answer: A
TensorFlow Profiler is a tool for checking the performance of your TensorFlow models and helping you to obtain an optimized version.
In TensorFlow 2, the default is eager execution. So, one-off operations are faster, but recurring ones may be slower. So, you need to optimize the model.

Tensorflow 2

B is wrongbecause the TF function is a transformation tool used to make graphs out of your programs. It helps to create performant and portable models but is not a tool for optimization.

C is wrongbecause TF tracing lets you record TensorFlow Python operations in a graph.

D is wrongbecause TF debugging is for Debugger V2 and creates a log of debug information.

E is wrongbecause Checkpoints catch the value of all parameters in a serialized SavedModel format.

Q 10. Your team needs to create a model for managing security in restricted areas of a campus.
Everything that happens in these areas is filmed and, instead of having a physical surveillance service, the videos must be managed by a model capable of intercepting unauthorized people and vehicles, especially at particular times.
What are the GCP services that allow you to achieve all this with minimal effort?

A. AI Infrastructure
B. Cloud Video Intelligence AI
C. AutoML Video Intelligence Classification
D. Vision AI

Correct Answer: C
AutoML Video Intelligence is a service that allows you to customize the pre-trained Video intelligence GCP system according to your specific needs.

In particular, AutoML Video Intelligence Object Tracking allows you to identify and locate particular entities of interest to you with your specific tags.

AutoML Video Intelligence Object Tracking

A is wrongbecause AI Infrastructure allows you to manage hardware configurations for ML systems and in particular the processors used to accelerate machine learning workloads.

B is wrongbecause Cloud Video Intelligence AI is a pre-configured and ready-to-use service, therefore not configurable for specific needs

D is wrongbecause Vision A is for images and not video.

Q 11. With your team you have to decide the strategy for implementing an online forecasting model in production.
This template needs to work with both a web interface as well as DialogFlow and Google Assistant and a lot of requests are expected.
You are concerned that the final system is not efficient and scalable enough, and you are looking for the simplest and most managed GCP solution.
Which of these can be the solution?

A. AI Platform Prediction
B. GKE e TensorFlow
C. VMs and Autoscaling Groups with Application LB
D. Kubeflow

Correct Answer: A
The AI Platform Prediction service is fully managed and automatically scales machine learning models in the cloud
The service supports both online prediction and batch prediction.

machine learning models

B and C are wrongbecause they are not managed services

D is wrongbecause Kubeflow is not a managed service, it is used into AI Platforma and let you to deploy ML systems to various environments

Design data preparation and processing systems

Q 12. You work for a digital publishing website with an excellent technical and cultural level, where you have both famous authors and unknown experts who express ideas and insights.
You, therefore, have an extremely demanding audience with strong interests that can be of various types.
Users have a small set of articles that they can read for free every month. Then they need to sign up for a paid subscription.
You have been asked to prepare an ML training model that processes user readings and article preferences. You need to predict trends and topics that users will prefer.
But when you train your DNN with Tensorflow, your input data does not fit into RAM memory.
What can you do in the simplest way?

A. Use tf.data.Dataset
B. Use a queue with tf.train.shuffle_batch
C. Use pandas.DataFrame
D. Use a NumPy array

A

Correct Answer: A
The tf.data.Dataset allows you to manage a set of complex elements made up of several inner components.
It is designed to create efficient input pipelines and to iterate over the data for their processing.
These iterations happen in streaming. So, they work even if the input matrix is very large and doesn’t fit in memory

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

You are working on a deep neural network model with Tensorflow. Your model is complex, and you work with very large datasets full of numbers.
You want to increase performances. But you cannot use further resources.
You are afraid that you are not going to deliver your project in time.
Your mentor said to you that normalization could be a solution.
Which of the following choices do you think is not for data normalization?

A. Scaling to a range
B. Feature Clipping
C. Z-test
D. log scaling
E. Z-score

A

Correct Answer: C
z-test is not correct because it is a statistic that is used to prove if a sample mean belongs to a specific population. For example, it is used in medical trials to prove whether a new drug is effective or not.
A is OK because Scaling to a range converts numbers into a standard range ( 0 to 1 or -1 to 1).
B is OK because Feature Clipping caps all numbers outside a certain range.
D is OK because Log Scaling uses the logarithms instead of your values to change the shape. This is possible because the log function preserves monotonicity.
E is OK because Z-score is a variation of scaling: the resulting number is divided by the standard deviations. It is aimed at obtaining distributions with mean = 0 and std = 1.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

You need to develop and train a model capable of analyzing snapshots taken from a moving vehicle and detecting if obstacles arise. Your work environment is an AI Platform (currently Vertex AI).
Which technique or algorithm do you think is best to use?
A. TabNet algorithm with TensorFlow
B. A linear learner with Tensorflow Estimator API
C. XGBoost with BigQueryML
D. TensorFlow Object Detection API

A

Correct Answer: D
TensorFlow Object Detection API is designed to identify and localize multiple objects within an image. So it is the best solution.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

You are starting to operate as a Data Scientist and are working on a deep neural network model with Tensorflow to optimize customer satisfaction for after-sales services to create greater client loyalty.
You are doing Feature Engineering, and your focus is to minimize bias and increase accuracy. Your coordinator has told you that by doing so you risk having problems. He explained to you that, in addition to the bias, you must consider another factor to be optimized. Which one?
A. Blending
B. Learning Rate
C. Feature Cross
D. Bagging
E. Variance

A

Correct Answer: E
The variance indicates how much function f (X) can change with a different training dataset. Obviously, different estimates will correspond to different training datasets, but a good model should reduce this gap to a minimum.
The bias-variance dilemma is an attempt to minimize both bias and variance.
The bias error is the non-estimable part of the learning algorithm. The higher it is, the more underfitting there is.
Variance is the sensitivity to differences in the training set. The higher it is, the more overfitting there is.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

You have a Linear Regression model for the optimal management of supplies to a sales network based on a large number of different driving factors. You want to simplify the model to make it more efficient and faster. Your first goal is to synthesize the features without losing the information content that comes from them.
Which of these is the best technique?
A. Feature Crosses
B. Principal component analysis (PCA)
C. Embeddings
D. Functional Data Analysis

A

Principal component analysis is a technique to reduce the number of features by creating new variables obtained from linear combinations or mixes of the original variables, which can then replace them but retain most of the information useful for the model. In addition, the new features are all independent of each other.

The new variables are called principal components.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

work for a digital publishing website with an excellent technical and cultural level, where you have both famous authors and unknown experts who express ideas and insights. You, therefore, have an extremely demanding audience with strong interests of various types. Users have a small set of articles that they can read for free every month; they need to sign up for a paid subscription.
You aim to provide your audience with pointers to articles that they will indeed find of interest to themselves.
Which of these models can be useful to you?
A. Hierarchical Clustering
B. Autoencoder and self-encoder
C. Convolutional Neural Network
D. Collaborative filtering using Matrix Factorization

A

Correct Answer: D
Collaborative filtering works on the idea that a user may like the same things of the people with similar profiles and preferences.
So, exploiting the choices of other users, the recommendation system makes a guess and can advise people on things not yet been rated by them.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

You work for an important Banking group.
The purpose of your current project is the automatic and smart acquisition of data from documents and modules of different types.
You work on big datasets with a lot of private information that cannot be distributed and disclosed.
You are asked to replace sensitive data with specific surrogate characters.
Which of the following techniques do you think is best to use?

A

Correct Answer: D
Masking replaces sensitive values with a given surrogate character, like hash (#) or asterisk (*).
Format-preserving encryption (FPE) encrypts in the same format as the plaintext data.
For example, a 16-digit credit card number becomes another 16-digit number.
k-anonymity is a way to anonymize data in such a way that it is impossible to identify person-specific information. Still, you maintain all the information contained in the record.
Replacement just substitutes a sensitive element with a specified value.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

Your company traditionally deals with statistical analysis on data. The services have been integrated for some years with ML models for forecasting, but analyzes and simulations of all kinds are carried out.
So you are using 2 types of tools but you have been told that it is possible to have more levels of integration between traditional statistical methodologies and those more related to AI / ML processes.
Which tool is the best one for your needs?
A. TensorFlow Hub
B. TensorFlow Probability
C. TensorFlow Enterprise
D. TensorFlow Statistics

A

Correct answers: B
TensorFlow Probability is a Python library for statistical analysis and probability, which can be processed on TPU and GPU, too.
TensorFlow Probability main features are:

Probability distributions and differentiable and injective (one to one) functions.
Tools for deep probabilistic models building
Inference and Simulation methods support Markov chain, Monte Carlo.
Optimizers such as Nelder-Mead, BFGS, and SGLD.
All the other answers are wrong because they don’t deal with traditional statistical methodologies.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

Your customer has an online dating platform that, among other things, analyzes the degree of affinity between the various people. Obviously, it already uses ML models and uses, in particular, XGBoost, the gradient boosting decision tree algorithm, and is obtaining excellent results.
All its development processes follow CI / CD specifications and use Docker containers. The requirement is to classify users in various ways and update models frequently, based on new parameters entered into the platform by the users themselves.
So, the problem you are called to solve is how to optimize frequently re-trained operations with an optimized workflow system. Which solution among these proposals can best solve your needs?
A. Deploy the model on BigQuery ML and setup a job
B. Use Kubeflow Pipelines to design and execute your workflow
C. Use AI Platform
D. Orchestrate activities with Google Cloud Workflows
E. Develop procedures with Pub/Sub and Cloud Run
F. Schedule processes with Cloud Composer

A

Correct Answer: B

Kubeflow Pipelines is the ideal solution because it is a platform designed specifically for creating and deploying ML workflows based on Docker containers. So, it is the only answer that meets all requirements.

The main functions of Kubeflow Pipelines are:

Using packaged templates in Docker images in a K8s environment
Manage your various tests/experiments
Simplifying the orchestration of ML pipelines
Reuse components and pipelines

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

You are working with Vertex AI, the managed ML Platform in GCP.
You are dealing with custom training and you are looking and studying the job progresses during the training service lifecycle.
Which of the following states are not correct?
A. JOB_STATE_ACTIVE
B. JOB_STATE_RUNNING
C. JOB_STATE_QUEUED
D. JOB_STATE_ENDED

A

Correct answer: A
This is a brief description of the lifecycle of a custom training service.
Queueing a new job
When you create a CustomJob or HyperparameterTuningJob, the job is in the JOB_STATE_QUEUED.
When a training job starts, Vertex AI schedules as many workers according to configuration, in parallel.
So Vertex AI starts running code as soon as a worker becomes available.
When all the workers are available, the job state will be: JOB_STATE_RUNNING.
A training job ends successfully when its primary replica exits with exit code 0.
Therefore all the other workers will be stopped. The state will be: JOB_STATE_ENDED.
So A is wrong simply because this state doesn’t exist. All the other answers are correct.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

Your team works for an international company with Google Cloud, and you develop, train and deploy several ML models with Tensorflow. You use many tools and techniques and you want to make your work leaner, faster, and more efficient.
You would like engineer-to-engineer assistance from both Google Cloud and Google’s TensorFlow teams.
How is it possible? Which service?
A. AI Platform
B. Kubeflow
C. Tensorflow Enterprise
D. TFX

A

Correct Answer: C
The TensorFlow Enterprise is a distribution of the open-source platform for ML, linked to specific versions of TensorFlow, tailored for enterprise customers.
It is free but only for big enterprises with a lot of services in GCP. it is prepackaged and optimized for usage with containers and VMs.
It works in Google Cloud, from VM images to managed services like GKE and Vertex AI.
The TensorFlow Enterprise library is integrated in the following products:

Deep Learning VM Images
Deep Learning Containers
Notebooks
AI Platform/Vertex AITraining
It is ready for automatic provisioning and scaling with any kind of processor.
It has a premium level of support from Google.
A is wrong because AI Platform is a managed service without the kind of support required
B and D are wrong because they are open source libraries with standard support from the community

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

You work for an important organization and your manager tasked you with a new classification model with lots of data drawn from the company Data Lake.
The big problem is that you don’t have the labels for all the data, but for only a subset of it and you have very little time to complete the task.
Which of the following services could help you?
A. Vertex Data Labeling
B. Mechanical Turk
C. GitLab ML
D. Tag Manager

A

Correct Answer: A
In supervised learning, the correctness of label data, together with the quality of all your training data is utterly important for the resulting model and the quality of the future predictions.
If you cannot have your data correctly labeled you may request to have professional people that will complete your training data.
GCP has a service for this: Vertex AI data labeling. Human labelers will prepare correct labels following your directions.
You have to set up a data labeling job with:

The dataset
A list, vocabulary of the possible labels
An instructions document for the professional people
B is wrong because Mechanical Turk is an Amazon service
C is wrong because GitLab is a DevOps lifecycle tool
D is wrong because Tag Manager is in the Google Analytics ecosystem

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
24
Q

Your team is working with a great number of ML projects, especially with Tensorflow.
You recently prepared a DNN model for image recognition that works well and is about to be rolled out in production.
Your manager asked you to demonstrate the inner workings of the model.
It is a big problem for you because you know that it is working well but you don’t have the explainability of the model.
Which of these techniques could help you?
A. Integrated Gradient
B. LIT
C. WIT
D. PCA

A

Correct Answer: A
Integrated Gradient is an explainability technique for deep neural networks which gives info about what contributes to the model’s prediction.
Integrated Gradient works highlight the feature importance. It computes the gradient of the model’s prediction output regarding its input features without modification to the original model.
In the picture, you can see that it tunes the inputs and computes attributions so that it can compute the feature importances for the input image.
You can use tf.GradientTape to compute the gradients,

tf.GradientTape
tf.GradientTape
B is wrong because LIT is only for NLP models
C is wrong because What-If Tool is only for classification and regression models with structured data.
D is wrong because Principal component analysis (PCA) transforms and reduces the number of features by creating new variables, from linear combinations of the original variables.
The new features will be all independent of each other.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
25
Q

You work as a Data Scientist in a Startup and you work with several project with Python and Tensorflow;
You need to increase the performance of the training sessions and you already use caching and prefetching.
So now you want to use GPUs, but in a single machine, for cost reduction and experimentations.
Which of the following is the correct strategy?
A. tf.distribute.MirroredStrategy
B. tf.distribute.TPUStrategy
C. tf.distribute.MultiWorkerMirroredStrategy
D. tf.distribute.OneDeviceStrategy

A

Correct Answer: A

tf.distribute.Strategy is an API explicitly for training distribution among different processors and machines.

tf.distribute.MirroredStrategy lets you use multiple GPUs in a single VM, with a replica for each CPU.

tf.distribute.MirroredStrategy
tf.distribute.MirroredStrategy
B is wrong because tf.distribute.TPUStrategy let you use TPUs, not GPUs
C is wrong because tf.distribute.MultiWorkerMirroredStrategy is for multiple machines
D is wrong because tf.distribute.OneDeviceStrategy, like the default strategy, is for a single device, so a single virtual CPU.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
26
Q

You are building an ML model to detect anomalies in real-time sensor data. You will use Pub/Sub to handle incoming requests. You want to store the results for analytics and visualization. How should you con gure the pipeline?

A. 1 = Data ow, 2 = AI Platform, 3 = BigQuery

B. 1 = DataProc, 2 = AutoML, 3 = Cloud Bigtable

C. 1 = BigQuery, 2 = AutoML, 3 = Cloud Functions

D. 1 = BigQuery, 2 = AI Platform, 3 = Cloud Storage

A

C. 1 = BigQuery, 2 = AutoML, 3 = Cloud Functions

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
27
Q

Your organization wants to make its internal shuttle service route more e cient. The shuttles currently stop at all pick-up points across the city every 30 minutes between 7 am and 10 am. The development team has already built an application on Google Kubernetes Engine that requires users to con rm their presence and shuttle station one day in advance. What approach should you take?

A. 1. Build a tree-based regression model that predicts how many passengers will be picked up at each shuttle station. 2. Dispatch an appropriately sized shuttle and provide the map with the required stops based on the prediction.

B. 1. Build a tree-based classi cation model that predicts whether the shuttle should pick up passengers at each shuttle station. 2. Dispatch an available shuttle and provide the map with the required stops based on the prediction.

C. 1. Define the optimal route as the shortest route that passes by all shuttle stations with con firmed attendance at the given time under capacity constraints. 2. Dispatch an appropriately sized shuttle and indicate the required stops on the map.

D. 1. Build a reinforcement learning model with tree-based classi cation models that predict the presence of passengers at shuttle stops as agents and a reward function around a distance-based metric. 2. Dispatch an appropriately sized shuttle and provide the map with the required stops based on the simulated outcome.

A

C. 1. Define the optimal route as the shortest route that passes by all shuttle stations with confirmed attendance at the given time under capacity constraints. 2. Dispatch an appropriately sized shuttle and indicate the required stops on the map.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
28
Q

You were asked to investigate failures of a production line component based on sensor readings. After receiving the dataset, you discover that less than 1% of the readings are positive examples representing failure incidents. You have tried to train several classi cation models, but none of them converge. How should you resolve the class imbalance problem?

A. Use the class distribution to generate 10% positive examples.

B. Use a convolutional neural network with max pooling and softmax activation.

C. Downsample the data with upweighting to create a sample with 10% positive examples.

D. Remove negative examples until the numbers of positive and negative examples are equal.

A

C. Downsample the data with upweighting to create a sample with 10% positive examples.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
29
Q

You want to rebuild your ML pipeline for structured data on Google Cloud. You are using PySpark to conduct data transformations at scale, but your pipelines are taking over 12 hours to run. To speed up development and pipeline run time, you want to use a serverless tool and SQL syntax. You have already moved your raw data into Cloud Storage. How should you build the pipeline on Google Cloud while meeting the speed and processing requirements?

A. Use Data Fusion’s GUI to build the transformation pipelines, and then write the data into BigQuery.

B. Convert your PySpark into SparkSQL queries to transform the data, and then run your pipeline on Dataproc to write the data into BigQuery.

C. Ingest your data into Cloud SQL, convert your PySpark commands into SQL queries to transform the data, and then use federated queries from BigQuery for machine learning.

D. Ingest your data into BigQuery using BigQuery Load, convert your PySpark commands into BigQuery SQL queries to transform the data, and then write the transformations to a new table.

A

D. Ingest your data into BigQuery using BigQuery Load, convert your PySpark commands into BigQuery SQL queries to transform the data, and then write the transformations to a new table.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
30
Q

You manage a team of data scientists who use a cloud-based backend system to submit training jobs. This system has become very di cult to administer, and you want to use a managed service instead. The data scientists you work with use many different frameworks, including Keras, PyTorch, theano, Scikit-learn, and custom libraries. What should you do?

A. Use the AI Platform custom containers feature to receive training jobs using any framework.

B. Con gure Kube ow to run on Google Kubernetes Engine and receive training jobs through TF Job.

C. Create a library of VM images on Compute Engine, and publish these images on a centralized repository.

D. Set up Slurm workload manager to receive jobs that can be scheduled to run on your cloud infrastructure.

A

A. Use the AI Platform custom containers feature to receive training jobs using any framework.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
31
Q

You work for an online retail company that is creating a visual search engine. You have set up an end-to-end ML pipeline on Google Cloud to classify whether an image contains your company’s product. Expecting the release of new products in the near future, you con gured a retraining functionality in the pipeline so that new data can be fed into your ML models. You also want to use AI Platform’s continuous evaluation service to ensure that the models have high accuracy on your test dataset. What should you do?

A. Keep the original test dataset unchanged even if newer products are incorporated into retraining.

B. Extend your test dataset with images of the newer products when they are introduced to retraining.

C. Replace your test dataset with images of the newer products when they are introduced to retraining.

D. Update your test dataset with images of the newer products when your evaluation metrics drop below a pre-decided threshold.

A

B. Extend your test dataset with images of the newer products when they are introduced to retraining.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
32
Q

You need to build classi cation work ows over several structured datasets currently stored in BigQuery. Because you will be performing the classi cation several times, you want to complete the following steps without writing code: exploratory data analysis, feature selection, model building, training, and hyperparameter tuning and serving. What should you do?

A. Con gure AutoML Tables to perform the classi cation task.

B. Run a BigQuery ML task to perform logistic regression for the classificiation.

C. Use AI Platform Notebooks to run the classificiation model with pandas library.

D. Use AI Platform to run the classificiation model job con gured for hyperparameter tuning.

A

A. Configure AutoML Tables to perform the classification task.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
33
Q

You work for a public transportation company and need to build a model to estimate delay times for multiple transportation routes. Predictions are served directly to users in an app in real time. Because different seasons and population increases impact the data relevance, you will retrain the model every month. You want to follow Google-recommended best practices. How should you con gure the end-to-end architecture of the predictive model?

A. Con gure Kube ow Pipelines to schedule your multi-step work ow from training to deploying your model.

B. Use a model trained and deployed on BigQuery ML, and trigger retraining with the scheduled query feature in BigQuery.

C. Write a Cloud Functions script that launches a training and deploying job on AI Platform that is triggered by Cloud Scheduler.

D. Use Cloud Composer to programmatically schedule a Data ow job that executes the work ow from training to deploying your model.

A

A. Congure Kubeow Pipelines to schedule your multi-step workow from training to deploying your model.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
34
Q

You are developing ML models with AI Platform for image segmentation on CT scans. You frequently update your model architectures based on the newest available research papers, and have to rerun training on the same dataset to benchmark their performance. You want to minimize computation costs and manual intervention while having version control for your code. What should you do?

A. Use Cloud Functions to identify changes to your code in Cloud Storage and trigger a retraining job.

B. Use the gcloud command-line tool to submit training jobs on AI Platform when you update your code.

C. Use Cloud Build linked with Cloud Source Repositories to trigger retraining when new code is pushed to the repository.

D. Create an automated work ow in Cloud Composer that runs daily and looks for changes in code in Cloud Storage using a sensor.

A

C. Use Cloud Build linked with Cloud Source Repositories to trigger retraining when new code is pushed to the repository.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
35
Q

You are designing an ML recommendation model for shoppers on your company’s ecommerce website. You will use Recommendations AI to build, test, and deploy your system. How should you develop recommendations that increase revenue while following best practices?

A. Use the €Other Products You May Like € recommendation type to increase the click-through rate.

B. Use the €Frequently Bought Together € recommendation type to increase the shopping cart size for each order.

C. Import your user events and then your product catalog to make sure you have the highest quality event stream.

D. Because it will take time to collect and record product data, use placeholder values for the product catalog to test the viability of the model.

A

B. Use the €Frequently Bought Together € recommendation type to increase the shopping cart size for each order.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
36
Q

You have trained a deep neural network model on Google Cloud. The model has low loss on the training data, but is performing worse on the validation data. You want the model to be resilient to over tting. Which strategy should you use when retraining the model?

A. Apply a dropout parameter of 0.2, and decrease the learning rate by a factor of 10.

B. Apply a L2 regularization parameter of 0.4, and decrease the learning rate by a factor of 10.

C. Run a hyperparameter tuning job on AI Platform to optimize for the L2 regularization and dropout parameters.

D. Run a hyperparameter tuning job on AI Platform to optimize for the learning rate, and increase the number of neurons by a factor of 2.

A

C. Run a hyperparameter tuning job on AI Platform to optimize for the L2 regularization and dropout parameters.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
37
Q

You built and manage a production system that is responsible for predicting sales numbers. Model accuracy is crucial, because the production model is required to keep up with market changes. Since being deployed to production, the model hasn’t changed; however the accuracy of the model has steadily deteriorated.
What issue is most likely causing the steady decline in model accuracy?

A. Poor data quality

B. Lack of model retraining

C. Too few layers in the model for capturing information

D. Incorrect data split ratio during model training, evaluation, validation, and test

A

B. Lack of model retraining

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
38
Q

You have been asked to develop an input pipeline for an ML training model that processes images from disparate sources at a low latency. You discover that your input data does not t in memory. How should you create a dataset following Google-recommended best practices?

A. Create a tf.data.Dataset.prefetch transformation.

B. Convert the images to tf.Tensor objects, and then run Dataset.from_tensor_slices().

C. Convert the images to tf.Tensor objects, and then run tf.data.Dataset.from_tensors().

D. Convert the images into TFRecords, store the images in Cloud Storage, and then use the tf.data API to read the images for training.

A

D. Convert the images into TFRecords, store the images in Cloud Storage, and then use the tf.data API to read the images for training.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
39
Q

You are an ML engineer at a large grocery retailer with stores in multiple regions. You have been asked to create an inventory prediction model. Your model’s features include region, location, historical demand, and seasonal popularity. You want the algorithm to learn from new inventory data on a daily basis. Which algorithms should you use to build the model?

A. Classi cation
B. Reinforcement Learning
C. Recurrent Neural Networks (RNN)
D. Convolutional Neural Networks (CNN)

A

C. Recurrent Neural Networks (RNN)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
40
Q

ou are building a real-time prediction engine that streams les which may contain Personally Identi able Information (PII) to Google Cloud. You want to use the
Cloud Data Loss Prevention (DLP) API to scan the les. How should you ensure that the PII is not accessible by unauthorized individuals?

A. Stream all les to Google Cloud, and then write the data to BigQuery. Periodically conduct a bulk scan of the table using the DLP API.

B. Stream all les to Google Cloud, and write batches of the data to BigQuery. While the data is being written to BigQuery, conduct a bulk scan of the data using the DLP API.

C. Create two buckets of data: Sensitive and Non-sensitive. Write all data to the Non-sensitive bucket. Periodically conduct a bulk scan of that bucket using the DLP API, and move the sensitive data to the Sensitive bucket.

D. Create three buckets of data: Quarantine, Sensitive, and Non-sensitive. Write all data to the Quarantine bucket. Periodically conduct a bulk scan of that bucket using the DLP API, and move the data to either the Sensitive or Non-Sensitive bucket.

A

D. Create three buckets of data: Quarantine, Sensitive, and Non-sensitive. Write all data to the Quarantine bucket. Periodically conduct a bulk scan of that bucket using the DLP API, and move the data to either the Sensitive or Non-Sensitive bucket.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
41
Q

You have written unit tests for a Kube ow Pipeline that require custom libraries. You want to automate the execution of unit tests with each new push to your development branch in Cloud Source Repositories. What should you do?

A. Write a script that sequentially performs the push to your development branch and executes the unit tests on Cloud Run.

B. Using Cloud Build, set an automated trigger to execute the unit tests when changes are pushed to your development branch.

C. Set up a Cloud Logging sink to a Pub/Sub topic that captures interactions with Cloud Source Repositories. Con gure a Pub/Sub trigger for Cloud Run, and execute the unit tests on Cloud Run.

D. Set up a Cloud Logging sink to a Pub/Sub topic that captures interactions with Cloud Source Repositories. Execute the unit tests using a Cloud Function that is triggered when messages are sent to the Pub/Sub topic.

A

B. Using Cloud Build, set an automated trigger to execute the unit tests when changes are pushed to your development branch.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
42
Q

You are an ML engineer at a global shoe store. You manage the ML models for the company’s website. You are asked to build a model that will recommend new products to the user based on their purchase behavior and similarity with other users. What should you do?

A. Build a classi cation model
B. Build a knowledge-based ltering model
C. Build a collaborative-based ltering model
D. Build a regression model using the features as predictors

A

C. Build a collaborative-based ltering model

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
43
Q

You work for a social media company. You need to detect whether posted images contain cars. Each training example is a member of exactly one class. You have trained an object detection neural network and deployed the model version to AI Platform Prediction for evaluation. Before deployment, you created an evaluation job and attached it to the AI Platform Prediction model version. You notice that the precision is lower than your business requirements allow. How should you adjust the model’s nal layer softmax threshold to increase precision?

A. Increase the recall.
B. Decrease the recall.
C. Increase the number of false positives. D. Decrease the number of false negatives.

A

B. Decrease the recall.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
44
Q

You are responsible for building a uni ed analytics environment across a variety of on-premises data marts. Your company is experiencing data quality and security challenges when integrating data across the servers, caused by the use of a wide range of disconnected tools and temporary solutions. You need a fully managed, cloud-native data integration service that will lower the total cost of work and reduce repetitive work. Some members on your team prefer a codeless interface for building Extract, Transform, Load (ETL) process. Which service should you use?

A. Data ow
B. Dataprep
C. Apache Flink
D. Cloud Data Fusion

A

D. Cloud Data Fusion

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
45
Q

You have trained a model on a dataset that required computationally expensive preprocessing operations. You need to execute the same preprocessing at prediction time. You deployed the model on AI Platform for high-throughput online prediction. Which architecture should you use?

A. Validate the accuracy of the model that you trained on preprocessed data. Create a new model that uses the raw data and is available in real time. Deploy the new model onto AI Platform for online prediction.

B. Send incoming prediction requests to a Pub/Sub topic. Transform the incoming data using a Data ow job. Submit a prediction request to AI Platform using the transformed data. Write the predictions to an outbound Pub/Sub queue.

C. Stream incoming prediction request data into Cloud Spanner. Create a view to abstract your preprocessing logic. Query the view every second for new records. Submit a prediction request to AI Platform using the transformed data. Write the predictions to an outbound Pub/Sub queue.

D. Send incoming prediction requests to a Pub/Sub topic. Set up a Cloud Function that is triggered when messages are published to the Pub/Sub topic. Implement your preprocessing logic in the Cloud Function. Submit a prediction request to AI Platform using the transformed data. Write the predictions to an outbound Pub/Sub queue.

A

B. Send incoming prediction requests to a Pub/Sub topic. Transform the incoming data using a Dataow job. Submit a prediction request to AI Platform using the transformed data. Write the predictions to an outbound Pub/Sub queue.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
46
Q

Your team trained and tested a DNN regression model with good results. Six months after deployment, the model is performing poorly due to a change in the distribution of the input data. How should you address the input differences in production?

A. Create alerts to monitor for skew, and retrain the model.

B. Perform feature selection on the model, and retrain the model with fewer features.

C. Retrain the model, and select an L2 regularization parameter with a hyperparameter tuning service.

D. Perform feature selection on the model, and retrain the model on a monthly basis with fewer features.

A

A. Create alerts to monitor for skew, and retrain the model.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
47
Q

You are developing a Kube ow pipeline on Google Kubernetes Engine. The first step in the pipeline is to issue a query against BigQuery. You plan to use the results of that query as the input to the next step in your pipeline. You want to achieve this in the easiest way possible. What should you do?

A. Use the BigQuery console to execute your query, and then save the query results into a new BigQuery table.

B. Write a Python script that uses the BigQuery API to execute queries against BigQuery. Execute this script as the rst step in your Kube ow pipeline.

C. Use the Kube ow Pipelines domain-speci c language to create a custom component that uses the Python BigQuery client library to execute queries.

D. Locate the Kube ow Pipelines repository on GitHub. Find the BigQuery Query Component, copy that component’s URL, and use it to load the component into your pipeline. Use the component to execute queries against BigQuery.

A

D. Locate the Kubeow Pipelines repository on GitHub. Find the BigQuery Query Component, copy that component’s URL, and use it to load the component into your pipeline. Use the component to execute queries against BigQuery.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
48
Q

You are building a model to predict daily temperatures. You split the data randomly and then transformed the training and test datasets. Temperature data for model training is uploaded hourly. During testing, your model performed with 97% accuracy; however, after deploying to production, the model’s accuracy dropped to 66%. How can you make your production model more accurate?

A. Normalize the data for the training, and test datasets as two separate steps.

B. Split the training and test data based on time rather than a random split to avoid leakage.

C. Add more data to your test set to ensure that you have a fair distribution and sample for testing.

D. Apply data transformations before splitting, and cross-validate to make sure that the transformations are applied to both the training and test sets.

A

B. Split the training and test data based on time rather than a random split to avoid leakage.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
49
Q

You are developing models to classify customer support emails. You created models with TensorFlow Estimators using small datasets on your on- premises system, but you now need to train the models using large datasets to ensure high performance. You will port your models to Google Cloud and want to minimize code refactoring and infrastructure overhead for easier migration from on-prem to cloud. What should you do?

A. Use AI Platform for distributed training.

B. Create a cluster on Dataproc for training.

C. Create a Managed Instance Group with autoscaling.
A. Use AI Platform for distributed training.
D. Use Kube ow Pipelines to train on a Google Kubernetes Engine cluster.

A

A. Use AI Platform for distributed training.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
50
Q

You have trained a text classi cation model in TensorFlow using AI Platform. You want to use the trained model for batch predictions on text data stored in
BigQuery while minimizing computational overhead. What should you do?

A. Export the model to BigQuery ML.

B. Deploy and version the model on AI Platform.

C. Use Data ow with the SavedModel to read the data from BigQuery.

D. Submit a batch prediction job on AI Platform that points to the model location in Cloud Storage.

A

A. Export the model to BigQuery ML.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
51
Q

You work with a data engineering team that has developed a pipeline to clean your dataset and save it in a Cloud Storage bucket. You have created an ML model and want to use the data to refresh your model as soon as new data is available. As part of your CI/CD work ow, you want to automatically run a Kubef ow
Pipelines training job on Google Kubernetes Engine (GKE). How should you architect this work ow?

A. Con figure your pipeline with Data ow, which saves the les in Cloud Storage. After the file is saved, start the training job on a GKE cluster.

B. Use App Engine to create a lightweight python client that continuously polls Cloud Storage for new les. As soon as a fi le arrives, initiate the training job.

C. Con figure a Cloud Storage trigger to send a figure to a Pub/Sub topic when a new fi le is available in a storage bucket. Use a Pub/Sub- triggered Cloud Function to start the training job on a GKE cluster.
D. Use Cloud Scheduler to schedule jobs at a regular interval. For the fi rst step of the job, check the timestamp of objects in your Cloud Storage bucket. If there are no new les since the last run, abort the job.

A

C. Configure a Cloud Storage trigger to send a figure to a Pub/Sub topic when a new file is available in a storage bucket. Use a Pub/Sub- triggered Cloud Function to start the training job on a GKE cluster.
D. Use Cloud Scheduler to schedule jobs at a regular interval. For the first step of the job, check the timestamp of objects in your Cloud Storage bucket. If there are no new les since the last run, abort the job.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
52
Q

You have a functioning end-to-end ML pipeline that involves tuning the hyperparameters of your ML model using AI Platform, and then using the best-tuned parameters for training. Hypertuning is taking longer than expected and is delaying the downstream processes. You want to speed up the tuning job without signi cantly compromising its effectiveness. Which actions should you take? (Choose two.)

A. Decrease the number of parallel trials.

B. Decrease the range of floating-point values.

C. Set the early stopping parameter to TRUE.

D. Change the search algorithm from Bayesian search to random search.

E. Decrease the maximum number of trials during subsequent training phases.

A

CE

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
53
Q

Your team is building an application for a global bank that will be used by millions of customers. You built a forecasting model that predicts customers’ account balances 3 days in the future. Your team will use the results in a new feature that will notify users when their account balance is likely to drop below $25. How should you serve your predictions?

A. 1. Create a Pub/Sub topic for each user. 2. Deploy a Cloud Function that sends a noti fication when your model predicts that a user’s account balance will drop below the $25 threshold.

B. 1. Create a Pub/Sub topic for each user. 2. Deploy an application on the App Engine standard environment that sends a
notifi cation when your model predicts that a user’s account balance will drop below the $25 threshold.

C. 1. Build a noti fication system on Firebase. 2. Register each user with a user ID on the Firebase Cloud Messaging server, which sends a notification when the average of all account balance predictions drops below the $25 threshold.

D. 1. Build a notification system on Firebase. 2. Register each user with a user ID on the Firebase Cloud Messaging server, which sends a notification when your model predicts that a user’s account balance will drop below the $25 threshold.

A

D. 1. Build a notification system on Firebase. 2. Register each user with a user ID on the Firebase Cloud Messaging server, which sends a notification when your model predicts that a user’s account balance will drop below the $25 threshold.

54
Q

You are an ML engineer at a global car manufacture. You need to build an ML model to predict car sales in different cities around the world. Which features or feature crosses should you use to train city-speci c relationships between car type and number of sales?

A. Thee individual features: binned latitude, binned longitude, and one-hot encoded car type.

B. One feature obtained as an element-wise product between latitude, longitude, and car type.

C. One feature obtained as an element-wise product between binned latitude, binned longitude, and one-hot encoded car type.

D. Two feature crosses as an element-wise product: the rst between binned latitude and one-hot encoded car type, and the second between binned longitude and one-hot encoded car type.

A

C. One feature obtained as an element-wise product between binned latitude, binned longitude, and one-hot encoded car type.

55
Q

You work for a large technology company that wants to modernize their contact center. You have been asked to develop a solution to classify incoming calls by product so that requests can be more quickly routed to the correct support team. You have already transcribed the calls using the Speech-to-Text API. You want to minimize data preprocessing and development time. How should you build the model?

A. Use the AI Platform Training built-in algorithms to create a custom model.

B. Use AutoMlL Natural Language to extract custom entities for classi fication.

C. Use the Cloud Natural Language API to extract custom entities for classification.

D. Build a custom model to identify the product keywords from the transcribed calls, and then run the keywords through a classification algorithm.

A

B. Use AutoMlL Natural Language to extract custom entities for classification.

56
Q

You are training a TensorFlow model on a structured dataset with 100 billion records stored in several CSV les. You need to improve the input/output execution performance. What should you do?

A. Load the data into BigQuery, and read the data from BigQuery.

B. Load the data into Cloud Bigtable, and read the data from Bigtable.

C. Convert the CSV les into shards of TFRecords, and store the data in Cloud Storage.

D. Convert the CSV les into shards of TFRecords, and store the data in the Hadoop Distributed File System (HDFS).

A

C. Convert the CSV les into shards of TFRecords, and store the data in Cloud Storage.

57
Q

As the lead ML Engineer for your company, you are responsible for building ML models to digitize scanned customer forms. You have developed a TensorFlow model that converts the scanned images into text and stores them in Cloud Storage. You need to use your ML model on the aggregated data collected at the end of each day with minimal manual intervention. What should you do?

A. Use the batch prediction functionality of AI Platform.

B. Create a serving pipeline in Compute Engine for prediction.

C. Use Cloud Functions for prediction each time a new data point is ingested.

D. Deploy the model on AI Platform and create a version of it for online inference.

A

A. Use the batch prediction functionality of AI Platform.

58
Q

You recently joined an enterprise-scale company that has thousands of datasets. You know that there are accurate descriptions for each table in BigQuery, and you are searching for the proper BigQuery table to use for a model you are building on AI Platform. How should you nd the data that you need?

A. Use Data Catalog to search the BigQuery datasets by using keywords in the table description.

B. Tag each of your model and version resources on AI Platform with the name of the BigQuery table that was used for training.

C. Maintain a lookup table in BigQuery that maps the table descriptions to the table ID. Query the lookup table to fi nd the correct table ID for the data that you need.

D. Execute a query in BigQuery to retrieve all the existing table names in your project using the INFORMATION_SCHEMA metadata tables that are native to BigQuery. Use the result to find the table that you need.

A

A. Use Data Catalog to search the BigQuery datasets by using keywords in the table description.

59
Q

You started working on a classi cation problem with time series data and achieved an area under the receiver operating characteristic curve (AUC ROC) value of
99% for training data after just a few experiments. You haven’t explored using any sophisticated algorithms or spent any time on hyperparameter tuning. What should your next step be to identify and x the problem?

A. Address the model over tting by using a less complex algorithm.

B. Address data leakage by applying nested cross-validation during model training.
C. Address data leakage by removing features highly correlated with the target value.

D. Address the model overfi tting by tuning the hyperparameters to reduce the AUC ROC value.

A

B. Address data leakage by applying nested cross-validation during model training.
C. Address data leakage by removing features highly correlated with the target value.

60
Q

You work for an online travel agency that also sells advertising placements on its website to other companies. You have been asked to predict the most relevant web banner that a user should see next. Security is important to your company. The model latency requirements are 300ms@p99, the inventory is thousands of web banners, and your exploratory analysis has shown that navigation context is a good predictor. You want to Implement the simplest solution. How should you con gure the prediction pipeline?

A. Embed the client on the website, and then deploy the model on AI Platform Prediction.

B. Embed the client on the website, deploy the gateway on App Engine, and then deploy the model on AI Platform Prediction.

C. Embed the client on the website, deploy the gateway on App Engine, deploy the database on Cloud Bigtable for writing and for reading the user’s navigation context, and then deploy the model on AI Platform Prediction.

D. Embed the client on the website, deploy the gateway on App Engine, deploy the database on Memorystore for writing and for reading the user’s navigation context, and then deploy the model on Google Kubernetes Engine.

A

C. Embed the client on the website, deploy the gateway on App Engine, deploy the database on Cloud Bigtable for writing and for reading the user’s navigation context, and then deploy the model on AI Platform Prediction.

61
Q

Your team has been tasked with creating an ML solution in Google Cloud to classify support requests for one of your platforms. You analyzed the requirements and decided to use TensorFlow to build the classi er so that you have full control of the model’s code, serving, and deployment. You will use Kube ow pipelines for the ML platform. To save time, you want to build on existing resources and use managed services instead of building a completely new model. How should you build the classifi er?

A. Use the Natural Language API to classify support requests.

B. Use AutoML Natural Language to build the support requests classi fier.

C. Use an established text classifi cation model on AI Platform to perform transfer learning.

D. Use an established text classi fication model on AI Platform as-is to classify support requests.

A

C. Use an established text classification model on AI Platform to perform transfer learning.

62
Q

Your company manages a video sharing website where users can watch and upload videos. You need to create an ML model to predict which newly uploaded videos will be the most popular so that those videos can be prioritized on your company’s website. Which result should you use to determine whether the model is successful?

A. The model predicts videos as popular if the user who uploads them has over 10,000 likes.

B. The model predicts 97.5% of the most popular clickbait videos measured by number of clicks.

C. The model predicts 95% of the most popular videos measured by watch time within 30 days of being uploaded.

D. The Pearson correlation coe cient between the log-transformed number of views after 7 days and 30 days after publication is equal to 0.

A

C. The model predicts 95% of the most popular videos measured by watch time within 30 days of being uploaded.

63
Q

You are working on a Neural Network-based project. The dataset provided to you has columns with different ranges. While preparing the data for model training, you discover that gradient optimization is having di culty moving weights to a good solution. What should you do?

A. Use feature construction to combine the strongest features.

B. Use the representation transformation (normalization) technique.

C. Improve the data cleaning step by removing features with missing values.

D. Change the partitioning step to reduce the dimension of the test set and have a larger training set.

A

B. Use the representation transformation (normalization) technique.

64
Q

You work for a bank and are building a random forest model for fraud detection. You have a dataset that includes transactions, of which 1% are identi ed as fraudulent. Which data transformation strategy would likely improve the performance of your classi er?

A. Write your data in TFRecords.

B. Z-normalize all the numeric features.

C. Oversample the fraudulent transaction 10 times.

D. Use one-hot encoding on all categorical features.

A

C. Oversample the fraudulent transaction 10 times.

65
Q

You recently designed and built a custom neural network that uses critical dependencies speci c to your organization’s framework. You need to train the model using a managed training service on Google Cloud. However, the ML framework and related dependencies are not supported by AI Platform Training. Also, both your model and your data are too large to t in memory on a single machine. Your ML framework of choice uses the scheduler, workers, and servers distribution structure. What should you do?

A. Use a built-in model available on AI Platform Training.

B. Build your custom container to run jobs on AI Platform Training.

C. Build your custom containers to run distributed training jobs on AI Platform Training.

D. Reconfigure your code to a ML framework with dependencies that are supported by AI Platform Training.

A

C. Build your custom containers to run distributed training jobs on AI Platform Training.

66
Q

While monitoring your model training’s GPU utilization, you discover that you have a native synchronous implementation. The training data is split into multiple files. You want to reduce the execution time of your input pipeline. What should you do?

A. Increase the CPU load
B. Add caching to the pipeline
C. Increase the network bandwidth
D. Add parallel interleave to the pipeline

A

D. Add parallel interleave to the pipeline

67
Q

Your data science team is training a PyTorch model for image classi cation based on a pre-trained RestNet model. You need to perform hyperparameter tuning to optimize for several parameters. What should you do?

A. Convert the model to a Keras model, and run a Keras Tuner job.

B. Run a hyperparameter tuning job on AI Platform using custom containers.

C. Create a Kubefl ow Pipelines instance, and run a hyperparameter tuning job on Katib.

D. Convert the model to a TensorFlow model, and run a hyperparameter tuning job on AI Platform.

A

B. Run a hyperparameter tuning job on AI Platform using custom containers.

68
Q

You have a large corpus of written support cases that can be classi ed into 3 separate categories: Technical Support, Billing Support, or Other Issues. You need to quickly build, test, and deploy a service that will automatically classify future written requests into one of the categories. How should you con gure the pipeline?

A. Use the Cloud Natural Language API to obtain metadata to classify the incoming cases.

B. Use AutoML Natural Language to build and test a classifier. Deploy the model as a REST API.

C. Use BigQuery ML to build and test a logistic regression model to classify incoming requests. Use BigQuery ML to perform inference.

D. Create a TensorFlow model using Google’s BERT pre-trained model. Build and test a classi er, and deploy the model using Vertex AI.

A

B. Use AutoML Natural Language to build and test a classifier. Deploy the model as a REST API.

69
Q

You need to quickly build and train a model to predict the sentiment of customer reviews with custom categories without writing code. You do not have enough data to train a model from scratch. The resulting model should have high predictive performance.
Which service should you use?

A. AutoML Natural Language
B. Cloud Natural Language API
C. AI Hub pre-made Jupyter Notebooks D. AI Platform Training built-in algorithms

A

A. AutoML Natural Language

70
Q

You need to train a regression model based on a dataset containing 50,000 records that is stored in BigQuery. The data includes a total of 20 categorical and numerical features with a target variable that can include negative values. You need to minimize effort and training time while maximizing model performance. What approach should you take to train this regression model?

A. Create a custom TensorFlow DNN model
B. Use BQML XGBoost regression to train the model.
C. Use AutoML Tables to train the model without early stopping.
D. Use AutoML Tables to train the model with RMSLE as the optimization objective.

A

B. Use BQML XGBoost regression to train the model.

71
Q

You are building a linear model with over 100 input features, all with values between –1 and 1. You suspect that many features are non- informative. You want to remove the non-informative features from your model while keeping the informative ones in their original form. Which technique should you use?

A. Use principal component analysis (PCA) to eliminate the least informative features.

B. Use L1 regularization to reduce the coe fficients of uninformative features to 0.

C. After building your model, use Shapley values to determine which features are the most informative. D. Use an iterative dropout technique to identify which features do not degrade the model when removed.

A

B. Use L1 regularization to reduce the coefficients of uninformative features to 0.

72
Q

You have deployed a model on Vertex AI for real-time inference. During an online prediction request, you get an “Out of Memory” error. What should you do?

A. Use batch prediction mode instead of online mode.

B. Send the request again with a smaller batch of instances.

C. Use base64 to encode your data before using it for prediction.

D. Apply for a quota increase for the number of prediction requests.

A

B. Send the request again with a smaller batch of instances.

73
Q

You are working on a classi cation problem with time series data. After conducting just a few experiments using random cross-validation, you achieved an Area Under the Receiver Operating Characteristic Curve (AUC ROC) value of 99% on the training data. You haven’t explored using any sophisticated algorithms or spent any time on hyperparameter tuning. What should your next step be to identify and x the problem?

A. Address the model over tting by using a less complex algorithm and use k-fold cross-validation.

B. Address data leakage by applying nested cross-validation during model training.

C. Address data leakage by removing features highly correlated with the target value.

D. Address the model over tting by tuning the hyperparameters to reduce the AUC ROC value.

A

B. Address data leakage by applying nested cross-validation during model training.

74
Q

You are pro ling the performance of your TensorFlow model training time and notice a performance issue caused by ine fficiencies in the input data pipeline for a single 5 terabyte CSV file dataset on Cloud Storage. You need to optimize the input pipeline performance. Which action should you try first to increase the e fficiency of your pipeline?

A. Preprocess the input CSV file into a TFRecord file.

B. Randomly select a 10 gigabyte subset of the data to train your model.

C. Split into multiple CSV les and use a parallel interleave transformation.

D. Set the reshuffl e_each_iteration parameter to true in the tf.data.Dataset.shu ffle method.

A

C. Split into multiple CSV les and use a parallel interleave transformation.

75
Q

You are a lead ML engineer at a retail company. You want to track and manage ML metadata in a centralized way so that your team can have reproducible experiments by generating artifacts. Which management solution should you recommend to your team?

A. Store your tf.logging data in BigQuery.

B. Manage all relational entities in the Hive Metastore.

C. Store all ML metadata in Google Cloud’s operations suite.

D. Manage your ML work flows with Vertex ML Metadata.

A

D. Manage your ML workflows with Vertex ML Metadata.

76
Q

You have been given a dataset with sales predictions based on your company’s marketing activities. The data is structured and stored in BigQuery, and has been carefully managed by a team of data analysts. You need to prepare a report providing insights into the predictive capabilities of the data. You were asked to run several ML models with different levels of sophistication, including simple models and multilayered neural networks. You only have a few hours to gather the results of your experiments. Which Google Cloud tools should you use to complete this task in the most efficient and self-serviced way?

A. Use BigQuery ML to run several regression models, and analyze their performance.

B. Read the data from BigQuery using Dataproc, and run several models using SparkML.

C. Use Vertex AI Workbench user-managed notebooks with scikit-learn code for a variety of ML algorithms and performance metrics.

D. Train a custom TensorFlow model with Vertex AI, reading the data from BigQuery featuring a variety of ML algorithms.

A

A. Use BigQuery ML to run several regression models, and analyze their performance.

77
Q

You have been asked to build a model using a dataset that is stored in a medium-sized (~10 GB) BigQuery table. You need to quickly determine whether this data is suitable for model development. You want to create a one-time report that includes both informative visualizations of data distributions and more sophisticated statistical analyses to share with other ML engineers on your team. You require maximum exibility to create your report. What should you do?

A. Use Vertex AI Workbench user-managed notebooks to generate the report.

B. Use the Google Data Studio to create the report.

C. Use the output from TensorFlow Data Validation on Data ow to generate the report.

D. Use Dataprep to create the report.

A

B. Use the Google Data Studio to create the report.

78
Q

You are developing an ML model that uses sliced frames from video feed and creates bounding boxes around speci c objects. You want to automate the following steps in your training pipeline: ingestion and preprocessing of data in Cloud Storage, followed by training and hyperparameter tuning of the object model using Vertex AI jobs, and nally deploying the model to an endpoint. You want to orchestrate the entire pipeline with minimal cluster management. What approach should you use?

A. Use Kubefl ow Pipelines on Google Kubernetes Engine.

B. Use Vertex AI Pipelines with TensorFlow Extended (TFX) SDK.

C. Use Vertex AI Pipelines with Kubefl ow Pipelines SDK.

D. Use Cloud Composer for the orchestration.

A

C. Use Vertex AI Pipelines with Kubeflow Pipelines SDK.

79
Q

You are training an object detection machine learning model on a dataset that consists of three million X-ray images, each roughly 2 GB in size. You are using Vertex AI Training to run a custom training application on a Compute Engine instance with 32-cores, 128 GB of RAM, and 1 NVIDIA P100 GPU. You notice that model training is taking a very long time. You want to decrease training time without sacri cing model performance. What should you do?

A. Increase the instance memory to 512 GB and increase the batch size.

B. Replace the NVIDIA P100 GPU with a v3-32 TPU in the training job.

C. Enable early stopping in your Vertex AI Training job.

D. Use the tf.distribute.Strategy API and run a distributed training job.

A

C. Enable early stopping in your Vertex AI Training job.

80
Q

You are an ML engineer at a travel company. You have been researching customers’ travel behavior for many years, and you have deployed models that predict customers’ vacation patterns. You have observed that customers’ vacation destinations vary based on seasonality and holidays; however, these seasonal variations are similar across years. You want to quickly and easily store and compare the model versions and performance statistics across years. What should you do?

A. Store the performance statistics in Cloud SQL. Query that database to compare the performance statistics across the model versions.

B. Create versions of your models for each season per year in Vertex AI. Compare the performance statistics across the models in the Evaluate tab of the Vertex AI UI.

C. Store the performance statistics of each pipeline run in Kube flow under an experiment for each season per year. Compare the results across the experiments in the Kube ow UI.

D. Store the performance statistics of each version of your models using seasons and years as events in Vertex ML Metadata. Compare the results across the slices.

A

D. Store the performance statistics of each version of your models using seasons and years as events in Vertex ML Metadata. Compare the results across the slices.

81
Q

You are an ML engineer at a manufacturing company. You need to build a model that identi es defects in products based on images of the product taken at the end of the assembly line. You want your model to preprocess the images with lower computation to quickly extract features of defects in products. Which approach should you use to build the model?

A. Reinforcement learning
B. Recommender system
C. Recurrent Neural Networks (RNN)
D. Convolutional Neural Networks (CNN)

A

D. Convolutional Neural Networks (CNN)

82
Q

You have successfully deployed to production a large and complex TensorFlow model trained on tabular data. You want to predict the lifetime value (LTV) eld for each subscription stored in the BigQuery table named subscription. subscriptionPurchase in the project named my- fortune500-company-project.
You have organized all your training code, from preprocessing data from the BigQuery table up to deploying the validated model to the Vertex AI endpoint, into a TensorFlow Extended (TFX) pipeline. You want to prevent prediction drift, i.e., a situation when a feature data distribution in production changes signi cantly over time. What should you do?

A. Implement continuous retraining of the model daily using Vertex AI Pipelines.

B. Add a model monitoring job where 10% of incoming predictions are sampled 24 hours.

C. Add a model monitoring job where 90% of incoming predictions are sampled 24 hours.

D. Add a model monitoring job where 10% of incoming predictions are sampled every hour.

A

B. Add a model monitoring job where 10% of incoming predictions are sampled 24 hours.

83
Q

You work for a gaming company that has millions of customers around the world. All games offer a chat feature that allows players to communicate with each other in real time. Messages can be typed in more than 20 languages and are translated in real time using the Cloud Translation API. You have been asked to build an ML system to moderate the chat in real time while assuring that the performance is uniform across the various languages and without changing the serving infrastructure.
You trained your fi rst model using an in-house word2vec model for embedding the chat messages translated by the Cloud Translation API. However, the model has signi cant differences in performance across the different languages. How should you improve it?

A. Add a regularization term such as the Min-Diff algorithm to the loss function.

B. Train a classi fier using the chat messages in their original language.

C. Replace the in-house word2vec with GPT-3 or T5.

D. Remove moderation for languages for which the false positive rate is too high.

A

C. Replace the in-house word2vec with GPT-3 or T5.

84
Q

You work for a gaming company that develops massively multiplayer online (MMO) games. You built a TensorFlow model that predicts whether players will make in-app purchases of more than $10 in the next two weeks. The model’s predictions will be used to adapt each user’s game experience. User data is stored in BigQuery. How should you serve your model while optimizing cost, user experience, and ease of management?

A. Import the model into BigQuery ML. Make predictions using batch reading data from BigQuery, and push the data to Cloud SQL

B. Deploy the model to Vertex AI Prediction. Make predictions using batch reading data from Cloud Bigtable, and push the data to Cloud SQL.

C. Embed the model in the mobile application. Make predictions after every in-app purchase event is published in Pub/Sub, and push the data to Cloud SQL.

D. Embed the model in the streaming Data ow pipeline. Make predictions after every in-app purchase event is published in Pub/Sub, and push the data to Cloud SQL.

A

A. Import the model into BigQuery ML. Make predictions using batch reading data from BigQuery, and push the data to Cloud SQL

85
Q

You are an ML engineer at a bank that has a mobile application. Management has asked you to build an ML-based biometric authentication for the app that veri es a customer’s identity based on their ngerprint. Fingerprints are considered highly sensitive personal information and cannot be downloaded and stored into the bank databases. Which learning strategy should you recommend to train and deploy this ML mode?

A. Data Loss Prevention API
B. Federated learning
C. MD5 to encrypt data
D. Differential privacy

A

B. Federated learning

86
Q

During batch training of a neural network, you notice that there is an oscillation in the loss. How should you adjust your model to ensure that it converges?

A. Decrease the size of the training batch.
B. Decrease the learning rate hyperparameter.
C. Increase the learning rate hyperparameter.
D. Increase the size of the training batch.

A

B. Decrease the learning rate hyperparameter.

87
Q

You work for a toy manufacturer that has been experiencing a large increase in demand. You need to build an ML model to reduce the amount of time spent by quality control inspectors checking for product defects. Faster defect detection is a priority. The factory does not have reliable Wi- Fi. Your company wants to implement the new ML model as soon as possible. Which model should you use?

A. AutoML Vision Edge mobile-high-accuracy-1 model
B. AutoML Vision Edge mobile-low-latency-1 model
C. AutoML Vision model
D. AutoML Vision Edge mobile-versatile-1 model

A

B. AutoML Vision Edge mobile-low-latency-1 model

88
Q

You need to build classi cation work ows over several structured datasets currently stored in BigQuery. Because you will be performing the classi cation several times, you want to complete the following steps without writing code: exploratory data analysis, feature selection, model building, training, and hyperparameter tuning and serving. What should you do?

A. Train a TensorFlow model on Vertex AI.
B. Train a classi cation Vertex AutoML model.
C. Run a logistic regression job on BigQuery ML.
D. Use scikit-learn in Notebooks with pandas library.

A

B. Train a classication Vertex AutoML model.

89
Q

You work for a biotech startup that is experimenting with deep learning ML models based on properties of biological organisms. Your team frequently works on early-stage experiments with new architectures of ML models, and writes custom TensorFlow ops in C++. You train your models on large datasets and large batch sizes. Your typical batch size has 1024 examples, and each example is about 1 MB in size. The average size of a network with all weights and embeddings is 20 GB. What hardware should you choose for your models?

A. A cluster with 2 n1-highcpu-64 machines, each with 8 NVIDIA Tesla V100 GPUs (128 GB GPU memory in total), and a n1-highcpu-64 machine with 64 vCPUs and 58 GB RAM

B. A cluster with 2 a2-megagpu-16g machines, each with 16 NVIDIA Tesla A100 GPUs (640 GB GPU memory in total), 96 vCPUs, and 1.4 TB RAM

C. A cluster with an n1-highcpu-64 machine with a v2-8 TPU and 64 GB RAM

D. A cluster with 4 n1-highcpu-96 machines, each with 96 vCPUs and 86 GB RAM

A

D. A cluster with 4 n1-highcpu-96 machines, each with 96 vCPUs and 86 GB RAM

CPUs are recommended for TensorFlow ops written in C++

90
Q

You are an ML engineer at an ecommerce company and have been tasked with building a model that predicts how much inventory the logistics team should order each month. Which approach should you take?

A. Use a clustering algorithm to group popular items together. Give the list to the logistics team so they can increase inventory of the popular items.

B. Use a regression model to predict how much additional inventory should be purchased each month. Give the results to the logistics team at the beginning of the month so they can increase inventory by the amount predicted by the model.

C. Use a time series forecasting model to predict each item’s monthly sales. Give the results to the logistics team so they can base inventory on the amount predicted by the model.

D. Use a classifi cation model to classify inventory levels as UNDER_STOCKED, OVER_STOCKED, and CORRECTLY_STOCKE. Give the report to the logistics team each month so they can fi ne-tune inventory levels.

A

C. Use a time series forecasting model to predict each item’s monthly sales. Give the results to the logistics team so they can base inventory on the amount predicted by the model.

91
Q

You are building a TensorFlow model for a financial institution that predicts the impact of consumer spending on in flation globally. Due to the size and nature of the data, your model is long-running across all types of hardware, and you have built frequent checkpointing into the training process. Your organization has asked you to minimize cost. What hardware should you choose?

A. A Vertex AI Workbench user-managed notebooks instance running on an n1-standard-16 with 4 NVIDIA P100 GPUs

B. A Vertex AI Workbench user-managed notebooks instance running on an n1-standard-16 with an NVIDIA P100 GPU

C. A Vertex AI Workbench user-managed notebooks instance running on an n1-standard-16 with a non-preemptible v3-8 TPU

D. A Vertex AI Workbench user-managed notebooks instance running on an n1-standard-16 with a preemptible v3-8 TPU

A

D. A Vertex AI Workbench user-managed notebooks instance running on an n1-standard-16 with a preemptible v3-8 TPU

preemptible is the key

92
Q

You work for a company that provides an anti-spam service that ags and hides spam posts on social media platforms. Your company currently uses a list of 200,000 keywords to identify suspected spam posts. If a post contains more than a few of these keywords, the post is identi ed as spam. You want to start using machine learning to ag spam posts for human review. What is the main advantage of implementing machine learning for this business case?

A. Posts can be compared to the keyword list much more quickly.

B. New problematic phrases can be identifi ed in spam posts.

C. A much longer keyword list can be used to flag spam posts.

D. Spam posts can be flagged using far fewer keywords.

A

B. New problematic phrases can be identified in spam posts.

93
Q

You work for a company that is developing a new video streaming platform. You have been asked to create a recommendation system that will suggest the next video for a user to watch. After a review by an AI Ethics team, you are approved to start development. Each video asset in your company’s catalog has useful metadata (e.g., content type, release date, country), but you do not have any historical user event data. How should you build the recommendation system for the first version of the product?

A. Launch the product without machine learning. Present videos to users alphabetically, and start collecting user event data so you can develop a recommender model in the future.

B. Launch the product without machine learning. Use simple heuristics based on content metadata to recommend similar videos to users, and start collecting user event data so you can develop a recommender model in the future.

C. Launch the product with machine learning. Use a publicly available dataset such as MovieLens to train a model using the Recommendations AI, and then apply this trained model to your data.

D. Launch the product with machine learning. Generate embeddings for each video by training an autoencoder on the content metadata using TensorFlow. Cluster content based on the similarity of these embeddings, and then recommend videos from the same cluster.

A

B. Launch the product without machine learning. Use simple heuristics based on content metadata to recommend similar videos to users, and start collecting user event data so you can develop a recommender model in the future.

94
Q

You recently built the first version of an image segmentation model for a self-driving car. After deploying the model, you observe a decrease in the area under the curve (AUC) metric. When analyzing the video recordings, you also discover that the model fails in highly congested tra ffic but works as expected when there is less tra ffic. What is the most likely reason for this result?

A. The model is over fitting in areas with less tra ffic and underfi tting in areas with more tra ffic.

B. AUC is not the correct metric to evaluate this classi fication model.

C. Too much data representing congested areas was used for model training.

D. Gradients become small and vanish while backpropagating from the output to input nodes.

A

A. The model is overfitting in areas with less traffic and underfitting in areas with more traffic.

95
Q

You are developing an ML model to predict house prices. While preparing the data, you discover that an important predictor variable, distance from the closest school, is often missing and does not have high variance. Every instance (row) in your data is important. How should you handle the missing data?

A. Delete the rows that have missing values.
B. Apply feature crossing with another column that does not have missing values. C. Predict the missing values using linear regression.
D. Replace the missing values with zeros.

A

C. Predict the missing values using linear regression.

96
Q

You are an ML engineer responsible for designing and implementing training pipelines for ML models. You need to create an end-to-end training pipeline for a TensorFlow model. The TensorFlow model will be trained on several terabytes of structured data. You need the pipeline to include data quality checks before training and model quality checks after training but prior to deployment. You want to minimize development time and the need for infrastructure maintenance. How should you build and orchestrate your training pipeline?

A. Create the pipeline using Kube flow Pipelines domain-speci c language (DSL) and predefi ned Google Cloud components. Orchestrate the pipeline using Vertex AI Pipelines.

B. Create the pipeline using TensorFlow Extended (TFX) and standard TFX components. Orchestrate the pipeline using Vertex AI Pipelines.

C. Create the pipeline using Kubefl ow Pipelines domain-speci c language (DSL) and prede fined Google Cloud components. Orchestrate the pipeline using Kubefl ow Pipelines deployed on Google Kubernetes Engine.

D. Create the pipeline using TensorFlow Extended (TFX) and standard TFX components. Orchestrate the pipeline using Kube flow Pipelines deployed on Google Kubernetes Engine.

A

B. Create the pipeline using TensorFlow Extended (TFX) and standard TFX components. Orchestrate the pipeline using Vertex AI Pipelines.

97
Q

You manage a team of data scientists who use a cloud-based backend system to submit training jobs. This system has become very di cult to administer, and you want to use a managed service instead. The data scientists you work with use many different frameworks, including Keras, PyTorch, theano, scikit-learn, and custom libraries. What should you do?

A. Use the Vertex AI Training to submit training jobs using any framework.

B. Con gure Kube ow to run on Google Kubernetes Engine and submit training jobs through TFJob.

C. Create a library of VM images on Compute Engine, and publish these images on a centralized repository.

D. Set up Slurm workload manager to receive jobs that can be scheduled to run on your cloud infrastructure.

A

A. Use the Vertex AI Training to submit training jobs using any framework.

98
Q

While performing exploratory data analysis on a dataset, you nd that an important categorical feature has 5% null values. You want to minimize the bias that could result from the missing values. How should you handle the missing values?

A. Remove the rows with missing values, and upsample your dataset by 5%.

B. Replace the missing values with the feature’s mean.

C. Replace the missing values with a placeholder category indicating a missing value.

D. Move the rows with missing values to your validation dataset.

A

C. Replace the missing values with a placeholder category indicating a missing value.

99
Q

You have been asked to productionize a proof-of-concept ML model built using Keras. The model was trained in a Jupyter notebook on a data scientist’s local machine. The notebook contains a cell that performs data validation and a cell that performs model analysis. You need to orchestrate the steps contained in the notebook and automate the execution of these steps for weekly retraining. You expect much more training data in the future. You want your solution to take advantage of managed services while minimizing cost. What should you do?

A. Move the Jupyter notebook to a Notebooks instance on the largest N2 machine type, and schedule the execution of the steps in the Notebooks instance using Cloud Scheduler.

B. Write the code as a TensorFlow Extended (TFX) pipeline orchestrated with Vertex AI Pipelines. Use standard TFX components for data validation and model analysis, and use Vertex AI Pipelines for model retraining.

C. Rewrite the steps in the Jupyter notebook as an Apache Spark job, and schedule the execution of the job on ephemeral Dataproc clusters using Cloud Scheduler.

D. Extract the steps contained in the Jupyter notebook as Python scripts, wrap each script in an Apache Air ow BashOperator, and run the resulting directed acyclic graph (DAG) in Cloud Composer.

A

B. Write the code as a TensorFlow Extended (TFX) pipeline orchestrated with Vertex AI Pipelines. Use standard TFX components for data validation and model analysis, and use Vertex AI Pipelines for model retraining.

100
Q

You are an ML engineer at a mobile gaming company. A data scientist on your team recently trained a TensorFlow model, and you are responsible for deploying this model into a mobile application. You discover that the inference latency of the current model doesn’t meet production requirements. You need to reduce the inference time by 50%, and you are willing to accept a small decrease in model accuracy in order to reach the latency requirement. Without training a new model, which model optimization technique for reducing latency should you try first?

A. Weight pruning
B. Dynamic range quantization
C. Model distillation
D. Dimensionality reduction

A

B. Dynamic range quantization

101
Q

You work on a data science team at a bank and are creating an ML model to predict loan default risk. You have collected and cleaned hundreds of millions of records worth of training data in a BigQuery table, and you now want to develop and compare multiple models on this data using TensorFlow and Vertex AI. You want to minimize any bottlenecks during the data ingestion state while considering scalability. What should you do?

A. Use the BigQuery client library to load data into a dataframe, and use tf.data.Dataset.from_tensor_slices() to read it.

B. Export data to CSV les in Cloud Storage, and use tf.data.TextLineDataset() to read them.

C. Convert the data into TFRecords, and use tf.data.TFRecordDataset() to read them.

D. Use TensorFlow I/O’s BigQuery Reader to directly read the data.

A

B. Export data to CSV les in Cloud Storage, and use tf.data.TextLineDataset() to read them.

102
Q

You are the Director of Data Science at a large company, and your Data Science team has recently begun using the Kube ow Pipelines SDK to orchestrate their training pipelines. Your team is struggling to integrate their custom Python code into the Kube ow Pipelines SDK. How should you instruct them to proceed in order to quickly integrate their code with the Kube ow Pipelines SDK?

A. Use the func_to_container_op function to create custom components from the Python code.

B. Use the predefi ned components available in the Kube flow Pipelines SDK to access Dataproc, and run the custom code there.

C. Package the custom Python code into Docker containers, and use the load_component_from_ file function to import the containers into the pipeline.

D. Deploy the custom Python code to Cloud Functions, and use Kubeflo w Pipelines to trigger the Cloud Function.

A

A. Use the func_to_container_op function to create custom components from the Python code.

103
Q

You have built a model that is trained on data stored in Parquet les. You access the data through a Hive table hosted on Google Cloud. You preprocessed these data with PySpark and exported it as a CSV le into Cloud Storage. After preprocessing, you execute additional steps to train and evaluate your model. You want to parametrize this model training in Kube ow Pipelines. What should you do?

A. Remove the data transformation step from your pipeline.

B. Containerize the PySpark transformation step, and add it to your pipeline.

C. Add a ContainerOp to your pipeline that spins a Dataproc cluster, runs a transformation, and then saves the transformed data in Cloud Storage.

D. Deploy Apache Spark at a separate node pool in a Google Kubernetes Engine cluster. Add a ContainerOp to your pipeline that invokes a corresponding transformation job for this Spark instance.

A

C. Add a ContainerOp to your pipeline that spins a Dataproc cluster, runs a transformation, and then saves the transformed data in Cloud Storage.

104
Q

You are developing a proof of concept for a real-time fraud detection model. After undersampling the training set to achieve a 50% fraud rate, you train and tune a tree classifier using area under the curve (AUC) as the metric, and then calibrate the model. You need to share metrics that represent your model’s effectiveness with business stakeholders in a way that is easily interpreted. Which approach should you take?

A. Calculate the AUC on the holdout dataset at a classification threshold of 0.5, and report true positive rate, false positive rate, and false negative rate.

B. Undersample the minority class to achieve a 50% fraud rate in the holdout set. Plot the confusion matrix at a classification threshold of 0.5, and report precision and recall.

C. Select all transactions in the holdout dataset. Plot the area under the receiver operating characteristic curve (AUC ROC), and report the F1 score for all available thresholds.

D. Select all transactions in the holdout dataset. Plot the precision-recall curve with associated average precision, and report the true positive rate, false positive rate, and false negative rate for all available thresholds.

A

D. Select all transactions in the holdout dataset. Plot the precision-recall curve with associated average precision, and report the true positive rate, false positive rate, and false negative rate for all available thresholds.

Feedback

A is not correct because you need business directions about the cost of misclassification to define the optimal threshold for both balanced and imbalanced classification.

B is not correct because the holdout dataset needs to represent real-world transactions to have a meaningful model evaluation, and you should never change its distribution.

C is not correct because classes in the holdout dataset are not balanced, so the ROC curve is not appropriate; also, neither F1 score nor ROC curve is recommended for communicating to business stakeholders. The F1 score aggregates precision and recall, but it is important to look at each metric separately to evaluate the model’s performance when the cost of misclassification is highly unbalanced between labels.

D is correct because the precision-recall curve is an appropriate metric for imbalanced classification when the output can be set using different thresholds. Presenting the precision-recall curve together with the mentioned rates provides business stakeholders with all the information necessary to evaluate model performance.

105
Q

Your organization’s marketing team wants to send biweekly scheduled emails to customers that are expected to spend above a variable threshold. This is the first machine learning (ML) use case for the marketing team, and you have been tasked with the implementation. After setting up a new Google Cloud project, you use Vertex AI Workbench to develop model training and batch inference with an XGBoost model on the transactional data stored in Cloud Storage. You want to automate the end-to-end pipeline that will securely provide the predictions to the marketing team, while minimizing cost and code maintenance. What should you do?

A. Create a scheduled pipeline on Vertex AI Pipelines that accesses the data from Cloud Storage, uses Vertex AI to perform training and batch prediction, and outputs a file in a Cloud Storage bucket that contains a list of all customer emails and expected spending.
B. Create a scheduled pipeline on Cloud Composer that accesses the data from Cloud Storage, copies the data to BigQuery, uses BigQuery ML to perform training and batch prediction, and outputs a table in BigQuery with customer emails and expected spending.

C. Create a scheduled notebook on Vertex AI Workbench that accesses the data from Cloud Storage, performs training and batch prediction on the managed notebook instance, and outputs a file in a Cloud Storage bucket that contains a list of all customer emails and expected spending.
D. Create a scheduled pipeline on Cloud Composer that accesses the data from Cloud Storage, uses Vertex AI to perform training and batch prediction, and sends an email to the marketing team’s Gmail group email with an attachment that contains an encrypted list of all customer emails and expected spending.

A

A. Create a scheduled pipeline on Vertex AI Pipelines that accesses the data from Cloud Storage, uses Vertex AI to perform training and batch prediction, and outputs a file in a Cloud Storage bucket that contains a list of all customer emails and expected spending.

Feedback

A is correct because Vertex AI Pipelines and Cloud Storage are cost-effective and secure solutions. The solution requires the least number of code interactions because the marketing team can update the pipeline and schedule parameters from the Google Cloud console.

B is not correct. Cloud Composer is not a cost-efficient solution for one pipeline because its environment is always active. In addition, using BigQuery is not the most cost-effective solution.

C is not correct because the marketing team would have to enter the Vertex AI Workbench instance to update a pipeline parameter, which does not minimize code interactions.

D is not correct. Cloud Composer is not a cost-efficient solution for one pipeline because its environment is always active. Also, using email to send personally identifiable information (PII) is not a recommended approach.

106
Q

You have developed a very large network in TensorFlow Keras that is expected to train for multiple days. The model uses only built-in TensorFlow operations to perform training with high-precision arithmetic. You want to update the code to run distributed training using tf.distribute.Strategy and configure a corresponding machine instance in Compute Engine to minimize training time. What should you do?

A. Select an instance with an attached GPU, and gradually scale up the machine type until the optimal execution time is reached. Add MirroredStrategy to the code, and create the model in the strategy’s scope with batch size dependent on the number of replicas.

B. Create an instance group with one instance with attached GPU, and gradually scale up the machine type until the optimal execution time is reached. Add TF_CONFIG and MultiWorkerMirroredStrategy to the code, create the model in the strategy’s scope, and set up data autosharing.

C. Create a TPU virtual machine, and gradually scale up the machine type until the optimal execution time is reached. Add TPU initialization at the start of the program, define a distributed TPUStrategy, and create the model in the strategy’s scope with batch size and training steps dependent on the number of TPUs.

D. Create a TPU node, and gradually scale up the machine type until the optimal execution time is reached. Add TPU initialization at the start of the program, define a distributed TPUStrategy, and create the model in the strategy’s scope with batch size and training steps dependent on the number of TPUs.

A

B. Create an instance group with one instance with attached GPU, and gradually scale up the machine type until the optimal execution time is reached. Add TF_CONFIG and MultiWorkerMirroredStrategy to the code, create the model in the strategy’s scope, and set up data autosharing.

Feedback

A is not correct because it is suboptimal in minimizing execution time for model training. MirroredStrategy only supports multiple GPUs on one instance, which may not be as performant as running on multiple instances.

B is correct because GPUs are the correct hardware for deep learning training with high-precision training, and distributing training with multiple instances will allow maximum flexibility in fine-tuning the accelerator selection to minimize execution time. Note that one worker could still be the best setting if the overhead of synchronizing the gradients across machines is too high, in which case this approach will be equivalent to MirroredStrategy.

C is not correct because TPUs are not recommended for workloads that require high-precision arithmetic, and are recommended for models that train for weeks or months.

D is not correct because TPUs are not recommended for workloads that require high-precision arithmetic, and are recommended for models that train for weeks or months. Also, TPU nodes are not recommended unless required by the application.

107
Q

You developed a tree model based on an extensive feature set of user behavioral data. The model has been in production for 6 months. New regulations were just introduced that require anonymizing personally identifiable information (PII), which you have identified in your feature set using the Cloud Data Loss Prevention API. You want to update your model pipeline to adhere to the new regulations while minimizing a reduction in model performance. What should you do?

A. Redact the features containing PII data, and train the model from scratch.

B. Mask the features containing PII data, and tune the model from the last checkpoint.

C. Use key-based hashes to tokenize the features containing PII data, and train the model from scratch.

D. Use deterministic encryption to tokenize the features containing PII data, and tune the model from the last checkpoint.

A

C. Use key-based hashes to tokenize the features containing PII data, and train the model from scratch.

Feedback
A is not correct because removing features from the model does not keep referential integrity by maintaining the original relationship between records, and is likely to cause a drop in performance.

B is not correct because masking does not enforce referential integrity, and a drop in model performance may happen. Also, tuning the existing model is not recommended because the model training on the original dataset may have memorized sensitive information.

C is correct because hashing is an irreversible transformation that ensures anonymization and does not lead to an expected drop in model performance because you keep the same feature set while enforcing referential integrity.

D is not correct because deterministic encryption is reversible, and anonymization requires irreversibility. Also, tuning the existing model is not recommended because the model training on the original dataset may have memorized sensitive information

108
Q

You set up a Vertex AI Workbench instance with a TensorFlow Enterprise environment to perform exploratory data analysis for a new use case. Your training and evaluation datasets are stored in multiple partitioned CSV files in Cloud Storage. You want to use TensorFlow Data Validation (TFDV) to explore problems in your data before model tuning. You want to fix these problems as quickly as possible. What should you do?

A. 1. Use TFDV to generate statistics, and use Pandas to infer the schema for the training dataset that has been loaded from Cloud Storage. 2. Visualize both statistics and schema, and manually fix anomalies in the dataset’s schema and values.

B. 1. Use TFDV to generate statistics and infer the schema for the training and evaluation datasets that have been loaded from Cloud Storage by using URI. 2. Visualize statistics for both datasets simultaneously to fix the datasets’ values, and fix the training dataset’s schema after displaying it together with anomalies in the evaluation dataset.

C. 1. Use TFDV to generate statistics, and use Pandas to infer the schema for the training dataset that has been loaded from Cloud Storage. 2. Use TFRecordWriter to convert the training dataset into a TFRecord. 3. Visualize both statistics and schema, and manually fix anomalies in the dataset’s schema and values.

D. 1. Use TFDV to generate statistics and infer the schema for the training and evaluation datasets that have been loaded with Pandas. 2. Use TFRecordWriter to convert the training and evaluation datasets into TFRecords. 3. Visualize statistics for both datasets simultaneously to fix the datasets’ values, and fix the training dataset’s schema after displaying it together with anomalies in the evaluation dataset.

A

B. 1. Use TFDV to generate statistics and infer the schema for the training and evaluation datasets that have been loaded from Cloud Storage by using URI. 2. Visualize statistics for both datasets simultaneously to fix the datasets’ values, and fix the training dataset’s schema after displaying it together with anomalies in the evaluation dataset.

Feedback
A is not correct because you also need to use the evaluation dataset for analysis. If the features do not belong to approximately the same range as the training dataset, the accuracy of the model will be affected.

B is correct because it takes the minimum number of steps to correctly fix problems in the data with TFDV before model tuning. This process involves installing tensorflow_data_validation, loading the training and evaluation datasets directly from Cloud Storage, and fixing schema and values for both. Note that the schema is only stored for the training set because it is expected to match at evaluation.

C is not correct because transforming into TFRecord is an unnecessary step. Also, you need to use the evaluation dataset for analysis. If the features do not belong to approximately the same range as the training dataset, the accuracy of the model will be affected.

D is not correct because transforming into TFRecord is an unnecessary step

109
Q

You have developed a simple feedforward network on a very wide dataset. You trained the model with mini-batch gradient descent and L1 regularization. During training, you noticed the loss steadily decreasing before moving back to the top at a very sharp angle and starting to oscillate. You want to fix this behavior with minimal changes to the model. What should you do?

A. Shuffle the data before training, and iteratively adjust the batch size until the loss improves.
B. Explore the feature set to remove NaNs and clip any noisy outliers. Shuffle the data before retraining.
C. Switch from L1 to L2 regularization, and iteratively adjust the L2 penalty until the loss improves.

D. Adjust the learning rate to exponentially decay with a larger decrease at the step where the loss jumped, and iteratively adjust the initial learning rate until the loss improves.

A

B. Explore the feature set to remove NaNs and clip any noisy outliers. Shuffle the data before retraining.

Feedback
A is not correct because divergence due to repetitive behavior in the data typically shows a loss that starts oscillating after some steps but does not jump back to the top.

B is correct because a large increase in loss is typically caused by anomalous values in the input data that cause NaN traps or exploding gradients.

C is not correct because L2 is not clearly a better solution than L1 regularization for wide models. L1 helps with sparsity, and L2 helps with collinearity.

D is not correct because a learning rate schedule that is not tuned typically shows a loss that starts oscillating after some steps but does not jump back to the top.

110
Q

You trained a neural network on a small normalized wide dataset. The model performs well without overfitting, but you want to improve how the model pipeline processes the features because they are not all expected to be relevant for the prediction. You want to implement changes that minimize model complexity while maintaining or improving the model’s offline performance. What should you do?

A. Keep the original feature set, and add L1 regularization to the loss function.
B. Use principal component analysis (PCA), and select the first n components that explain 99% of the variance.

C. Perform correlation analysis. Remove features that are highly correlated to one another and features that are not correlated to the target.

D. Ensure that categorical features are one-hot encoded and that continuous variables are binned, and create feature crosses for a subset of relevant features.

A

C. Perform correlation analysis. Remove features that are highly correlated to one another and features that are not correlated to the target.
Feedback
A is not correct because, although the approach lets you reduce RAM requirements by pushing the weights for meaningless features to 0, regularization tends to cause the training error to increase. Consequently, the model performance is expected to decrease.

B is not correct because PCA is an unsupervised approach, and it is a valid method of feature selection only if the most important variables are the ones that also have the most variation. This is usually not true, and disregarding the last few components is likely to decrease model performance.

C is correct because removing irrelevant features reduces model complexity and is expected to boost performance by removing noise.

D is not correct because this approach can make the model converge faster but it increases model RAM requirements, and it is not expected to boost model performance because neural networks inherently learn feature crosses.

111
Q

You trained a model in a Vertex AI Workbench notebook that has good validation RMSE. You defined 20 parameters with the associated search spaces that you plan to use for model tuning. You want to use a tuning approach that maximizes tuning job speed. You also want to optimize cost, reproducibility, model performance, and scalability where possible if they do not affect speed. What should you do?

A. Set up a cell to run a hyperparameter tuning job using Vertex AI Vizier with val_rmse specified as the metric in the study configuration.

B. Using a dedicated Python library such as Hyperopt or Optuna, configure a cell to run a local hyperparameter tuning job with Bayesian optimization.

C. Refactor the notebook into a parametrized and dockerized Python script, and push it to Container Registry. Use the UI to set up a hyperparameter tuning job in Vertex AI. Use the created image and include Grid Search as an algorithm.

D. Refactor the notebook into a parametrized and dockerized Python script, and push it to Container Registry. Use the command line to set up a hyperparameter tuning job in Vertex AI. Use the created image and include Random Search as an algorithm where maximum trial count is equal to parallel trial count.
Correct answer

D. Refactor the notebook into a parametrized and dockerized Python script, and push it to Container Registry. Use the command line to set up a hyperparameter tuning job in Vertex AI. Use the created image and include Random Search as an algorithm where maximum trial count is equal to parallel trial count.

A

D. Refactor the notebook into a parametrized and dockerized Python script, and push it to Container Registry. Use the command line to set up a hyperparameter tuning job in Vertex AI. Use the created image and include Random Search as an algorithm where maximum trial count is equal to parallel trial count.

Feedback
A is not correct because Vertex AI Vizier should be used for systems that do not have a known objective function or are too costly to evaluate using the objective function. Neither applies to the specified use case. Vizier requires sequential trials and does not optimize for cost or tuning time.

B is not correct because Bayesian optimization can converge in fewer iterations than the other algorithms but not necessarily in a faster time because trials are dependent and thus require sequentiality. Also, running tuning locally does not optimize for reproducibility and scalability.

C is not correct because Grid Search is a brute-force approach and it is not feasible to fully parallelize. Because you need to try all hyperparameter combinations, that is an exponential number of trials with respect to the number of hyperparameters, Grid Search is inefficient for high spaces in time, cost, and computing power.

D is correct because Random Search can limit the search iterations on time and parallelize all trials so that the execution time of the tuning job corresponds to the longest training produced by your hyperparameter combination. This approach also optimizes for the other mentioned metrics.

112
Q

You trained a deep model for a regression task. The model predicts the expected sale price for a house based on features that are not guaranteed to be independent. You want to evaluate your model by defining a baseline approach and selecting an evaluation metric for comparison that detects high variance in the model. What should you do?

A. Use a heuristic that predicts the mean value as the baseline, and compare the trained model’s mean absolute error against the baseline.

B. Use a linear model trained on the most predictive features as the baseline, and compare the trained model’s root mean squared error against the baseline.

C. Determine the maximum acceptable mean absolute percentage error (MAPE) as the baseline, and compare the model’s MAPE against the baseline.

D. Use a simple neural network with one fully connected hidden layer as the baseline, and compare the trained model’s mean squared error against the baseline.

A

D. Use a simple neural network with one fully connected hidden layer as the baseline, and compare the trained model’s mean squared error against the baseline.
Feedback
A is not correct because always predicting the mean value is not expected to be a strong baseline; house prices could assume a wide range of values. Also, mean absolute error is not the best metric to detect variance because it gives the same weight to all errors.

B is not correct because a linear model is not expected to perform well with multicollinearity. Also, root mean squared error does not penalize high variance as much as mean squared error because the root operation reduces the importance of higher values.

C is not correct because, while defining a threshold for acceptable performance is a good practice for blessing models, a baseline should aim to test statistically a model’s ability to learn by comparing it to a less complex data-driven approach. Also, this approach does not detect high variance in the model.

D is correct because a one-layer neural network can handle collinearity and is a good baseline. The mean square error is a good metric because it gives more weight to errors with larger absolute values than to errors with smaller absolute values.

113
Q

You designed a 5-billion-parameter language model in TensorFlow Keras that used autotuned tf.data to load the data in memory. You created a distributed training job in Vertex AI with tf.distribute.MirroredStrategy, and set the large_model_v100 machine for the primary instance. The training job fails with the following error:

“The replica 0 ran out of memory with a non-zero status of 9.”

You want to fix this error without vertically increasing the memory of the replicas. What should you do?

A. Keep MirroredStrategy. Increase the number of attached V100 accelerators until the memory error is resolved.
B. Switch to ParameterServerStrategy, and add a parameter server worker pool with large_model_v100 instance type.

C. Switch to tf.distribute.MultiWorkerMirroredStrategy with Reduction Server. Increase the number of workers until the memory error is resolved.

D. Switch to a custom distribution strategy that uses TF_CONFIG to equally split model layers between workers. Increase the number of workers until the memory error is resolved.

A

D. Switch to a custom distribution strategy that uses TF_CONFIG to equally split model layers between workers. Increase the number of workers until the memory error is resolved.
Feedback
A is not correct because MirroredStrategy is a data-parallel approach. This approach is not expected to fix the error because the memory issues in the primary replica are caused by the size of the model itself.

B is not correct because the parameter server alleviates some workload from the primary replica by coordinating the shared model state between the workers, but it still requires the whole model to be shared with workers. This approach is not expected to fix the error because the memory issues in the primary replica are caused by the size of the model itself.

C is not correct because MultiWorkerMirroredStrategy is a data-parallel approach. This approach is not expected to fix the error because the memory issues in the primary replica are caused by the size of the model itself. Reduction Server increases throughput and reduces latency of communication, but it does not help with memory issues.

D is correct because this is an example of a model-parallel approach that splits the model between workers. You can use TensorFlow Mesh to implement this. This approach is expected to fix the error because the memory issues in the primary replica are caused by the size of the model itself.

114
Q

You need to develop an online model prediction service that accesses pre-computed near-real-time features and returns a customer churn probability value. The features are saved in BigQuery and updated hourly using a scheduled query. You want this service to be low latency and scalable and require minimal maintenance. What should you do?

A. 1. Configure a Cloud Function that exports features from BigQuery to Memorystore. 2. Use Memorystore to perform feature lookup. Deploy the model as a custom prediction endpoint in Vertex AI, and enable automatic scaling.

B. 1. Configure a Cloud Function that exports features from BigQuery to Memorystore. 2. Use a custom container on Google Kubernetes Engine to deploy a service that performs feature lookup from Memorystore and performs inference with an in-memory model.

C. 1. Configure a Cloud Function that exports features from BigQuery to Vertex AI Feature Store. 2. Use the online service API from Vertex AI Feature Store to perform feature lookup. Deploy the model as a custom prediction endpoint in Vertex AI, and enable automatic scaling.

D. 1. Configure a Cloud Function that exports features from BigQuery to Vertex AI Feature Store. 2. Use a custom container on Google Kubernetes Engine to deploy a service that performs feature lookup from Vertex AI Feature Store’s online serving API and performs inference with an in-memory model.

A

A. 1. Configure a Cloud Function that exports features from BigQuery to Memorystore. 2. Use Memorystore to perform feature lookup. Deploy the model as a custom prediction endpoint in Vertex AI, and enable automatic scaling.

Feedback
A is correct because this approach creates a fully managed autoscalable service that minimizes maintenance while providing low latency with the use of Memorystore.

B is not correct because feature lookup and model inference can be performed in Cloud Function, and using Google Kubernetes Engine increases maintenance.

C is not correct because Vertex AI Feature Store is not as low-latency as Memorystore.

D is not correct because feature lookup and model inference can be performed in Cloud Function, and using Google Kubernetes Engine increases maintenance. Also, Vertex AI Feature Store is not as low-latency as Memorystore.

115
Q

You are logged into the Vertex AI Pipeline UI and noticed that an automated production TensorFlow training pipeline finished three hours earlier than a typical run. You do not have access to production data for security reasons, but you have verified that no alert was logged in any of the ML system’s monitoring systems and that the pipeline code has not been updated recently. You want to debug the pipeline as quickly as possible so you can determine whether to deploy the trained model. What should you do?

A. Navigate to Vertex AI Pipelines, and open Vertex AI TensorBoard. Check whether the training regime and metrics converge.
B. Access the Pipeline run analysis pane from Vertex AI Pipelines, and check whether the input configuration and pipeline steps have the expected values.

C. Determine the trained model’s location from the pipeline’s metadata in Vertex ML Metadata, and compare the trained model’s size to the previous model.
D. Request access to production systems. Get the training data’s location from the pipeline’s metadata in Vertex ML Metadata, and compare data volumes of the current run to the previous run.

A

A. Navigate to Vertex AI Pipelines, and open Vertex AI TensorBoard. Check whether the training regime and metrics converge.

Feedback
A is correct because TensorBoard provides a compact and complete overview of training metrics such as loss and accuracy over time. If the training converges with the model’s expected accuracy, the model can be deployed.

B is not correct because checking input configuration is a good test, but it is not sufficient to ensure that model performance is acceptable. You can access logs and outputs for each pipeline step to review model performance, but it would involve more steps than using TensorBoard.

C is not correct because model size is a good indicator of health but does not provide a complete overview to make sure that the model can be safely deployed. Note that the pipeline’s metadata can also be accessed directly from Vertex AI Pipelines.

D is not correct because data is the most probable cause of this behavior, but it is not the only possible cause. Also, access requests could take a long time and are not the most secure option. Note that the pipeline’s metadata can also be accessed directly from Vertex AI Pipelines.

116
Q

You recently developed a custom ML model that was trained in Vertex AI on a post-processed training dataset stored in BigQuery. You used a Cloud Run container to deploy the prediction service. The service performs feature lookup and pre-processing and sends a prediction request to a model endpoint in Vertex AI. You want to configure a comprehensive monitoring solution for training-serving skew that requires minimal maintenance. What should you do?

A. Create a Model Monitoring job for the Vertex AI endpoint that uses the training data in BigQuery to perform training-serving skew detection and uses email to send alerts. When an alert is received, use the console to diagnose the issue.

B. Update the model hosted in Vertex AI to enable request-response logging. Create a Data Studio dashboard that compares training data and logged data for potential training-serving skew and uses email to send a daily scheduled report.

C. Create a Model Monitoring job for the Vertex AI endpoint that uses the training data in BigQuery to perform training-serving skew detection and uses Cloud Logging to send alerts. Set up a Cloud Function to initiate model retraining that is triggered when an alert is logged.

D. Update the model hosted in Vertex AI to enable request-response logging. Schedule a daily DataFlow Flex job that uses Tensorflow Data Validation to detect training-serving skew and uses Cloud Logging to send alerts. Set up a Cloud Function to initiate model retraining that is triggered when an alert is logged.

A

A. Create a Model Monitoring job for the Vertex AI endpoint that uses the training data in BigQuery to perform training-serving skew detection and uses email to send alerts. When an alert is received, use the console to diagnose the issue.
Feedback
A is correct because Vertex AI Model Monitoring is a fully managed solution for monitoring training-serving skew that, by definition, requires minimal maintenance. Using the console for diagnostics is recommended for a comprehensive monitoring solution because there could be multiple causes for the skew that require manual review.

B is not correct because this solution does not minimize maintenance. It involves multiple custom components that require additional updates for any schema change.

C is not correct because a model retrain does not necessarily fix skew. For example, differences in pre-processing logic between training and prediction can also cause skew.

D is not correct because this solution does not minimize maintenance. It involves multiple components that require additional updates for any schema change. Also, a model retrain does not necessarily fix skew. For example, differences in pre-processing logic between training and prediction can also cause skew.

117
Q

You have a historical data set of the sale price of 10,000 houses and the 10 most important features resulting from principal component analysis (PCA). You need to develop a model that predicts whether a house will sell at one of the following equally distributed price ranges: 200-300k, 300-400k, 400-500k, 500-600k, or 600-700k. You want to use the simplest algorithmic and evaluative approach. What should you do?

A. Define a one-vs-one classification task where each price range is a categorical label. Use F1 score as the metric.
B. Define a multi-class classification task where each price range is a categorical label. Use accuracy as the metric.

C. Define a regression task where the label is the sale price represented as an integer. Use mean absolute error as the metric.
D. Define a regression task where the label is the average of the price range that corresponds to the house sale price represented as an integer. Use root mean squared error as the metric.

A

B. Define a multi-class classification task where each price range is a categorical label. Use accuracy as the metric.

Feedback
A is not correct because this approach is more complex than the classification approach suggested in response B. F1 score is not useful with equally distributed labels, and one-vs-one classification is used for multi-label classification, but the use case would require only one label to be correct.

B is correct because the use case is an ordinal classification task which is most simply solved using multi-class classification. Accuracy as a metric is the best match for a use case with discrete and balanced labels.

C is not correct because regression is not the recommended approach when solving an ordinal classification task with a small number of discrete values. This specific regression approach adds complexity in comparison to the regression approach suggested in response D because it uses the exact sale price to predict a range. Finally, the mean absolute error would not be the recommended metric because it gives the same penalty for errors of any magnitude.

D is not correct because regression is not the recommended approach when solving an ordinal classification task with a small number of discrete values. This specific regression approach would be recommended in comparison to the regression approach suggested in response C because it uses a less complex label and a recommended metric to minimize variance and bias.

118
Q

You downloaded a TensorFlow language model pre-trained on a proprietary dataset by another company, and you tuned the model with Vertex AI Training by replacing the last layer with a custom dense layer. The model achieves the expected offline accuracy; however, it exceeds the required online prediction latency by 20ms. You want to optimize the model to reduce latency while minimizing the offline performance drop before deploying the model to production. What should you do?

A. Apply post-training quantization on the tuned model, and serve the quantized model.

B. Use quantization-aware training to tune the pre-trained model on your dataset, and serve the quantized model.

C. Use pruning to tune the pre-trained model on your dataset, and serve the pruned model after stripping it of training variables.

D. Use clustering to tune the pre-trained model on your dataset, and serve the clustered model after stripping it of training variables.

A

A. Apply post-training quantization on the tuned model, and serve the quantized model.

Feedback
A is correct because post-training quantization is the recommended option for reducing model latency when re-training is not possible. Post-training quantization can minimally decrease model performance.

B is not correct because tuning the whole model on the custom dataset only will cause a drop in offline performance.

C is not correct because tuning the whole model on the custom dataset only will cause a drop in offline performance. Also, pruning helps in compressing model size, but it is expected to provide less latency improvements than quantization.

D is not correct because tuning the whole model on the custom dataset only will cause a drop in offline performance. Also, clustering helps in compressing model size, but it does not reduce latency.

119
Q

You developed a model for a classification task where the minority class appears in 10% of the data set. You ran the training on the original imbalanced data set and have checked the resulting model performance. The confusion matrix indicates that the model did not learn the minority class. You want to improve the model performance while minimizing run time and keeping the predictions calibrated. What should you do?

A. Update the weights of the classification function to penalize misclassifications of the minority class.

B. Tune the classification threshold, and calibrate the model with isotonic regression on the validation set.

C. Upsample the minority class in the training set, and update the weight of the upsampled class by the same sampling factor.

D. Downsample the majority class in the training set, and update the weight of the downsampled class by the same sampling factor.

A

D. Downsample the majority class in the training set, and update the weight of the downsampled class by the same sampling factor.

Feedback
A is not correct because this approach does not guarantee calibrated predictions and does not improve training run time.

B is not correct because this approach increases run time by adding threshold tuning and calibration on top of model training.

C is not correct because upsampling increases training run time by providing more data samples during training.

D is correct because downsampling with upweighting improves performance on the minority class while speeding up convergence and keeping the predictions calibrated.

120
Q

You have a dataset that is split into training, validation, and test sets. All the sets have similar distributions. You have sub-selected the most relevant features and trained a neural network in TensorFlow. TensorBoard plots show the training loss oscillating around 0.9, with the validation loss higher than the training loss by 0.3. You want to update the training regime to maximize the convergence of both losses and reduce overfitting. What should you do?

A. Decrease the learning rate to fix the validation loss, and increase the number of training epochs to improve the convergence of both losses.

B. Decrease the learning rate to fix the validation loss, and increase the number and dimension of the layers in the network to improve the convergence of both losses.

C. Introduce L1 regularization to fix the validation loss, and increase the learning rate and the number of training epochs to improve the convergence of both losses.

D. Introduce L2 regularization to fix the validation loss, and increase the number and dimension of the layers in the network to improve the convergence of both losses.

A

D. Introduce L2 regularization to fix the validation loss, and increase the number and dimension of the layers in the network to improve the convergence of both losses.

Feedback
A is not correct because changing the learning rate does not reduce overfitting. Increasing the number of training epochs is not expected to improve the losses significantly.

B is not correct because changing the learning rate does not reduce overfitting.

C is not correct because increasing the number of training epochs is not expected to improve the losses significantly, and increasing the learning rate could also make the model training unstable. L1 regularization could be used to stabilize the learning, but it is not expected to be particularly helpful because only the most relevant features have been used for training.

D is correct because L2 regularization prevents overfitting. Increasing the model’s complexity boosts the predictive ability of the model, which is expected to optimize loss convergence when underfitting.

121
Q

You recently used Vertex AI Prediction to deploy a custom-trained model in production. The automated re-training pipeline made available a new model version that passed all unit and infrastructure tests. You want to define a rollout strategy for the new model version that guarantees an optimal user experience with zero downtime. What should you do?

A. Release the new model version in the same Vertex AI endpoint. Use traffic splitting in Vertex AI Prediction to route a small random subset of requests to the new version and, if the new version is successful, gradually route the remaining traffic to it.

B. Release the new model version in a new Vertex AI endpoint. Update the application to send all requests to both Vertex AI endpoints, and log the predictions from the new endpoint. If the new version is successful, route all traffic to the new application.

C. Deploy the current model version with an Istio resource in Google Kubernetes Engine, and route production traffic to it. Deploy the new model version, and use Istio to route a small random subset of traffic to it. If the new version is successful, gradually route the remaining traffic to it.

D. Install Seldon Core and deploy an Istio resource in Google Kubernetes Engine. Deploy the current model version and the new model version using the multi-armed bandit algorithm in Seldon to dynamically route requests between the two versions before eventually routing all traffic over to the best-performing version.

A

B. Release the new model version in a new Vertex AI endpoint. Update the application to send all requests to both Vertex AI endpoints, and log the predictions from the new endpoint. If the new version is successful, route all traffic to the new application.

Feedback
A is not correct because canary deployments may affect user experience, even if on a small subset of users.

B is correct because shadow deployments minimize the risk of affecting user experience while ensuring zero downtime.

C is not correct because canary deployments may affect user experience, even if on a small subset of users. This approach is a less managed alternative to response A and could cause downtime when moving between services.

D is not correct because the multi-armed bandit approach may affect user experience, even if on a small subset of users. This approach could cause downtime when moving between services.

122
Q

You trained a model for sentiment analysis in TensorFlow Keras, saved it in SavedModel format, and deployed it with Vertex AI Predictions as a custom container. You selected a random sentence from the test set, and used a REST API call to send a prediction request. The service returned the error:

“Could not find matching concrete function to call loaded from the SavedModel. Got: Tensor(“inputs:0”, shape=(None,), dtype=string). Expected: TensorSpec(shape=(None, None), dtype=tf.int64, name=’inputs’)”.

You want to update the model’s code and fix the error while following Google-recommended best practices. What should you do?

A. Combine all preprocessing steps in a function, and call the function on the string input before requesting the model’s prediction on the processed input.

B. Combine all preprocessing steps in a function, and update the default serving signature to accept a string input wrapped into the preprocessing function call.

C. Create a custom layer that performs all preprocessing steps, and update the Keras model to accept a string input followed by the custom preprocessing layer.

D. Combine all preprocessing steps in a function, and update the Keras model to accept a string input followed by a Lambda layer wrapping the preprocessing function.

A

B. Combine all preprocessing steps in a function, and update the default serving signature to accept a string input wrapped into the preprocessing function call.

Feedback
A is not correct because duplicating the preprocessing adds unnecessary dependencies between the training and serving code and could cause training-serving skew.

B is correct because this approach efficiently updates the model while ensuring no training-serving skew.

C is not correct because this approach adds unnecessary complexity. Because you update the model directly, you will need to re-train the model.

D is not correct because this approach adds unnecessary complexity. Because you update the model directly, you will need to re-train the model. Note that using Lambda layers over custom layers is recommended for simple operations or quick experimentation only.

123
Q

You used Vertex AI Workbench user-managed notebooks to develop a TensorFlow model. The model pipeline accesses data from Cloud Storage, performs feature engineering and training locally, and outputs the trained model in Vertex AI Model Registry. The end-to-end pipeline takes 10 hours on the attached optimized instance type. You want to introduce model and data lineage for automated re-training runs for this pipeline only while minimizing the cost to run the pipeline. What should you do?

A. 1. Use the Vertex AI SDK to create an experiment for the pipeline runs, and save metadata throughout the pipeline. 2. Configure a scheduled recurring execution for the notebook. 3. Access data and model metadata in Vertex ML Metadata.

B. 1. Use the Vertex AI SDK to create an experiment, launch a custom training job in Vertex training service with the same instance type configuration as the notebook, and save metadata throughout the pipeline.
2. Configure a scheduled recurring execution for the notebook. 3. Access data and model metadata in Vertex ML Metadata.

C. 1. Create a Cloud Storage bucket to store metadata. 2. Write a function that saves data and model metadata by using TensorFlow ML Metadata in one time-stamped subfolder per pipeline run. 3. Configure a scheduled recurring execution for the notebook. 4. Access data and model metadata in Cloud Storage.

D. 1. Refactor the pipeline code into a TensorFlow Extended (TFX) pipeline. 2. Load the TFX pipeline in Vertex AI Pipelines, and configure the pipeline to use the same instance type configuration as the notebook. 3. Use Cloud Scheduler to configure a recurring execution for the pipeline. 4. Access data and model metadata in Vertex AI Pipelines.

A

C. 1. Create a Cloud Storage bucket to store metadata. 2. Write a function that saves data and model metadata by using TensorFlow ML Metadata in one time-stamped subfolder per pipeline run. 3. Configure a scheduled recurring execution for the notebook. 4. Access data and model metadata in Cloud Storage.

Feedback
A is not correct because a managed solution does not minimize running costs, and Vertex AI ML Metadata is more managed than Cloud Storage.

B is not correct because a managed solution does not minimize running costs, and this approach introduces Vertex training service with Vertex ML Metadata, which are both managed services.

C is correct because this approach minimizes running costs by being self-managed. This approach is recommended to minimize running costs only for simple use cases such as deploying one pipeline only. When optimizing for maintenance and development costs or scaling to more than one pipeline or performing experimentation, using Vertex ML Metadata and Vertex AI Pipelines are recommended.

D is not correct because a managed solution does not minimize running costs, and this approach introduces Vertex AI Pipelines, which is a fully managed service.

124
Q

Your data science team needs to rapidly experiment with various features, model architectures, and hyperparameters. They need to track the accuracy metrics for various experiments and use an API to query the metrics over time. What should they use to track and report their experiments while minimizing manual effort?

A. Use Kubeflow Pipelines to execute the experiments. Export the metrics file, and query the results using the Kubeflow Pipelines API.

B. Use AI Platform Training to execute the experiments. Write the accuracy metrics to BigQuery, and query the results using the BigQuery API.

C. Use AI Platform Training to execute the experiments. Write the accuracy metrics to Cloud Monitoring, and query the results using the Monitoring API.

D. Use AI Platform Notebooks to execute the experiments. Collect the results in a shared Google Sheets file, and query the results using the Google Sheets API.

A

B. Use AI Platform Training to execute the experiments. Write the accuracy metrics to BigQuery, and query the results using the BigQuery API.

125
Q

Your team is working on an NLP research project to predict political affiliation of authors based on articles they have written. You have a large training dataset that is structured like this:

You followed the standard 80%-10%-10% data distribution across the training, testing, and evaluation subsets. How should you distribute the training examples across the train-test-eval subsets while maintaining the 80-10-10 proportion?
A. Distribute texts randomly across the train-test-eval subsets: Train set: [TextA1, TextB2, …] Test set: [TextA2, TextC1, TextD2, …] Eval set: [TextB1, TextC2, TextD1, …]

B. Distribute authors randomly across the train-test-eval subsets: (*) Train set: [TextA1, TextA2, TextD1, TextD2, …] Test set: [TextB1, TextB2, …] Eval set: [TexC1,TextC2 …]

C. Distribute sentences randomly across the train-test-eval subsets: Train set: [SentenceA11, SentenceA21, SentenceB11, SentenceB21, SentenceC11, SentenceD21 …] Test set: [SentenceA12, SentenceA22, SentenceB12, SentenceC22, SentenceC12, SentenceD22 …] Eval set: [SentenceA13, SentenceA23, SentenceB13, SentenceC23, SentenceC13, SentenceD31 …]

D. Distribute paragraphs of texts (i.e., chunks of consecutive sentences) across the train-test-eval subsets: Train set: [SentenceA11, SentenceA12, SentenceD11, SentenceD12 …] Test set: [SentenceA13, SentenceB13, SentenceB21, SentenceD23, SentenceC12, SentenceD13 …] Eval set: [SentenceA11, SentenceA22, SentenceB13, SentenceD22, SentenceC23, SentenceD11 …]

A

C. Distribute sentences randomly across the train-test-eval subsets: Train set: [SentenceA11, SentenceA21, SentenceB11, SentenceB21, SentenceC11, SentenceD21 …] Test set: [SentenceA12, SentenceA22, SentenceB12, SentenceC22, SentenceC12, SentenceD22 …] Eval set: [SentenceA13, SentenceA23, SentenceB13, SentenceC23, SentenceC13, SentenceD31 …]

126
Q

You recently joined a machine learning team that will soon release a new project. As a lead on the project, you are asked to determine the production readiness of the ML components. The team has already tested features and data, model development, and infrastructure. Which additional readiness check should you recommend to the team?

A. Ensure that training is reproducible.
B. Ensure that all hyperparameters are tuned.
C. Ensure that model performance is monitored.
D. Ensure that feature expectations are captured in the schema.

A

A. Ensure that training is reproducible.

127
Q

You work for a credit card company and have been asked to create a custom fraud detection model based on historical data using AutoML Tables. You need to prioritize detection of fraudulent transactions while minimizing false positives. Which optimization objective should you use when training the model?

A. An optimization objective that minimizes Log loss

B. An optimization objective that maximizes the Precision at a Recall value of 0.50

C. An optimization objective that maximizes the area under the precision-recall curve (AUC PR) value

D. An optimization objective that maximizes the area under the receiver operating characteristic curve (AUC ROC) value

A

C. An optimization objective that maximizes the area under the precision-recall curve (AUC PR) value

128
Q

Your team is building a convolutional neural network (CNN)-based architecture from scratch. The preliminary experiments running on your on-premises CPU-only infrastructure were encouraging, but have slow convergence. You have been asked to speed up model training to reduce time-to-market. You want to experiment with virtual machines (VMs) on Google Cloud to leverage more powerful hardware. Your code does not include any manual device placement and has not been wrapped in Estimator model-level abstraction. Which environment should you train your model on?

A. AVM on Compute Engine and 1 TPU with all dependencies installed manually.

B. AVM on Compute Engine and 8 GPUs with all dependencies installed manually.

C. A Deep Learning VM with an n1-standard-2 machine and 1 GPU with all libraries pre-installed.

D. A Deep Learning VM with more powerful CPU e2-highcpu-16 machines with all libraries pre-installed.

A

A. AVM on Compute Engine and 1 TPU with all dependencies installed manually.

129
Q

You are training a deep learning model for semantic image segmentation with reduced training time. While using a Deep Learning VM Image, you receive the following error: The resource ‘projects/deeplearning-platforn/zones/europe-west4-c/acceleratorTypes/nvidia-tesla-k80’ was not found. What should you do?

A. Ensure that you have GPU quota in the selected region.
B. Ensure that the required GPU is available in the selected region.
C. Ensure that you have preemptible GPU quota in the selected region.
D. Ensure that the selected GPU has enough GPU memory for the workload.

A

A. Ensure that you have GPU quota in the selected region.

130
Q

You have built a model that is trained on data stored in Parquet files. You access the data through a Hive table hosted on Google Cloud. You preprocessed these data with PySpark and exported it as a CSV file into Cloud Storage. After preprocessing, you execute additional steps to train and evaluate your model. You want to parametrize this model training in Kubeflow Pipelines. What should you do?

A Remove the data transformation step from your pipeline.

B. Containerize the PySpark transformation step, and add it to your pipeline.

C. Add a ContainerOp to your pipeline that spins a Dataproc cluster, runs a transformation, and then saves the transformed data in Cloud Storage.

D. Deploy Apache Spark at a separate node pool in a Google Kubernetes Engine cluster. Add a ContainerOp to your pipeline that invokes a corresponding transformation job for this Spark instance.

A

D. Deploy Apache Spark at a separate node pool in a Google Kubernetes Engine cluster. Add a ContainerOp to your pipeline that invokes a corresponding transformation job for this Spark instance

131
Q

You work for a magazine publisher and have been tasked with predicting whether customers will cancel their annual subscription. In your exploratory data analysis, you find that 90% of individuals renew their subscription every year, and only 10% of individuals cancel their subscription. After training a NN Classifier, your model predicts those who cancel their subscription with 99% accuracy and predicts those who renew their subscription with 82% accuracy. How should you interpret these results?

A. This is not a good result because the model should have a higher accuracy for those who renew their subscription than for those who cancel their subscription.
B. This is not a good result because the model is performing worse than predicting that people will always renew their subscription.
C. This is a good result because predicting those who cancel their subscription is more difficult, since there is less data for this group.
D. This is a good result because the accuracy across both groups is greater than 80%.

A

C. This is a good result because predicting those who cancel their subscription is more difficult, since there is less data for this group.