AWS Certified Machine Learning Specialty · Free Practice Question Hard
Question 20
A social media company is experiencing poor accuracy while training on SageMaker's default built-in image classification algorithm. The Deep Learning team at the company wants to use an Inception neural network architecture rather than a ResNet one.
Which of the following options represent the most effective way to do this? (Select two)
-
A
Open a ticket with AWS Support to change the default image classification algorithm to Inception
-
B
Import the inception network into a SageMaker notebook instance
-
C
Bundle your own Docker container with TensorFlow Estimator loaded with an Inception network, import it into Amazon Elastic Container Registry (Amazon ECR) and use this for model training
-
D
Discard the built-in SageMaker image classification algorithm and use the open source Inception Convolution Neural Network Model on an EC2 instance
-
E
Customize the container provided by Amazon SageMaker with your own transfer learning code in TensorFlow framework so that the TensorFlow Estimator is loaded with an Inception network, import it into Amazon Elastic Container Registry (Amazon ECR) and use this for model training
Reveal correct answers
Correct answers: C, E
Explanation
The Amazon SageMaker image classification algorithm is a supervised learning algorithm that supports multi-label classification. It takes an image as input and outputs one or more labels assigned to that image. It uses a convolutional neural network (ResNet) that can be trained from scratch or trained using transfer learning when a large number of training images are not available.
If you need a different combination of the pre-trained network and the image data on which it has been trained, Amazon SageMaker also supports transfer learning for image classification through the built-in image classification algorithm.
In Transfer Learning, when you build a new model to classify your original dataset, you reuse the feature extraction part and re-train the classification part with your dataset. Since you don’t have to train the feature extraction part (which is the most complex part of the model), you can train the model with less computational resources and training time.
For the given use case, you can take an inception v3 network pre-trained on an ImageNet dataset and bundle your own container and import it into Amazon Elastic Container Registry (Amazon ECR). You can also customize the container provided by Amazon SageMaker with our own transfer learning code in the TensorFlow framework. Then you can import this container into Amazon ECR, and use it for model training and inferencing.
Exam Alert:
If you plan to use GPU devices, make sure that your containers are nvidia-docker compatible. Only the CUDA toolkit should be included on containers. Don't bundle NVIDIA drivers with the docker image.
Incorrect options:
Discard the built-in SageMaker image classification algorithm and use the open source Inception Convolution Neural Network Model on an EC2 instance - This option has been added as a distractor. There is no need to discard the SageMaker image classification algorithm for the given use case.
Open a ticket with AWS Support to configure the SageMaker image classification algorithm to use Inception - This option has been added as a distractor. There is no need to open a ticket with AWS Support to configure the image classification algorithm to use Inception.
Import the inception network into a SageMaker notebook instance - Amazon SageMaker notebook instance is a machine learning (ML) compute instance running the Jupyter Notebook App. SageMaker manages creating the instance and related resources. Use Jupyter notebooks in your notebook instance to prepare and process data, write code to train models, deploy models to SageMaker hosting, and test or validate your models.
Importing the inception network into a SageMaker notebook instance will not help, as the requirement is to support the Inception neural network architecture for the SageMaker image classification algorithm which can be done via containers.
References:
https://docs.aws.amazon.com/sagemaker/latest/dg/image-classification.html
Discussion
Think the marked answer is wrong, or have a better explanation? Share it below — comments appear after review.
