AWS Certified Machine Learning - Specialty | SageMaker Image Classification Hyperparameter for Quick Adaptation

SageMaker Image Classification Hyperparameter for Quick Adaptation

Question

You work as a machine learning specialist on a team tasked with designing an image recognition system that can quickly adapt to new observations.

Your team is designing automated driving software for cars in a ride-share fleet.

Your company wants to implement a service where when users hail a ride through your app on their mobile device.

A nearby self-driving car arrives at the user's location.

It has the desired route preloaded and is ready to take the user to their destination.

Your team has decided to use the SageMaker Image Classification algorithm in your image recognition model. The machine learning models powering this self-driving car fleet need to react very quickly to new observations, such as previously not encountered obstacles like different types and sized animals, etc.

Which hyperparameter would you set, and to what value, to obtain the desired outcome?

Answers

Explanations

Click on the arrows to vote for the correct answer

A. B. C. D. E. F.

Answer: D.

Option A is incorrect.

The early_stopping hyperparameter is used to decide whether to use early stopping during training.

This hyperparameter allows you to terminate a training job early if it is observed that further training will not be necessary.

Tuning this hyperparameter would not help your model react very quickly to new observations.

Option B is incorrect.

The early_stopping hyperparameter is used to decide whether to use early stopping during training.

This hyperparameter allows you to terminate a training job early if it is observed that further training will not be necessary.

Tuning this hyperparameter would not help your model react very quickly to new observations.

Option C is incorrect.

The learning_rate hyperparameter governs how quickly the model adapts to new or changing data.

Valid values range from 0.0 to 1.0

Setting this hyperparameter to a low value, such as 0.1, will make the model learn more slowly.

This is not what you want.

You want your model to learn very rapidly.

Option D is correct.

The learning_rate hyperparameter governs how quickly the model adapts to new or changing data.

Valid values range from 0.0 to 1.0

Setting this hyperparameter to a high value, such as 0.8, will make the model learn quickly.

This is what you want.

You want your model to learn very rapidly.

Option E is incorrect.

The use_pretrained_model hyperparameter defines whether you want a pre-trained model to be loaded before training.

This will not help you adapt quickly to new or changing observations.

Option F is incorrect.

The use_pretrained_model hyperparameter defines whether you want a pre-trained model to be loaded before training.

This will not help you adapt quickly to new or changing observations.

Reference:

Please see the Amazon SageMaker developer guide titled Image Classification Hyperparameters, and the Amazon Machine Learning blog titled Amazon SageMaker Automatic Model Tuning now supports early stopping of training jobs.

The hyperparameter that would need to be set to obtain the desired outcome for this scenario is the "use_pretrained_model" parameter. The optimal value for this parameter is 1.

Explanation:

SageMaker Image Classification is a supervised learning algorithm that can be used for image classification tasks. This algorithm uses a convolutional neural network (CNN) architecture that is pre-trained on a large image dataset to extract features from the input images. These features are then used to train a linear classifier on the output labels. The pre-trained model weights can be used as a starting point for the model training to improve the training speed and accuracy.

The "use_pretrained_model" hyperparameter determines whether to use a pre-trained model for the initial training or not. Setting this hyperparameter to 1 means that the pre-trained model weights will be used as the starting point for the model training. This will enable the model to adapt quickly to new observations as the pre-trained model already has learned a general understanding of the features that are important for image recognition.

On the other hand, setting "use_pretrained_model" to 0 would mean that the model is not pre-trained, and the weights would be initialized randomly before the model training begins. This would require more time and data to train the model to achieve good accuracy.

Therefore, to obtain the desired outcome of quickly adapting to new observations, the optimal value for "use_pretrained_model" hyperparameter is 1.