MLA-C01 Question 197
Select 3You are an AWS Machine Learning Engineer tasked with deploying a machine learning model that was trained using TensorFlow on an on-premises environment. You need to integrate this model into SageMaker for inference. Which methods can you use to achieve this?
- A
Save the model in a format supported by SageMaker (e.g., SavedModel for TensorFlow) and upload it to an Amazon S3 bucket, then create a SageMaker Model pointing to the S3 location.
- B
Convert the model into an ONNX format and use SageMaker's built-in ONNX serving container for deployment.
- C
Use the SageMaker Neo runtime to compile the model and directly deploy it without uploading to S3.
- D
Build a custom container with the model and necessary inference code, then use SageMaker to deploy the custom container.
- E
Use SageMaker Ground Truth to directly transform the model into a SageMaker-compatible format.
Show answer and explanation
Correct answers: A, B, D
Explanation
SageMaker allows you to integrate models trained outside of it by leveraging multiple methods such as uploading the model to S3 in a supported format, using built-in containers (e.g., ONNX), or creating custom Docker containers for deployment. SageMaker Neo is used for model optimization post-deployment, and SageMaker Ground Truth is unrelated to model integration.
- A. Correct.
Correct: SageMaker supports deploying models stored in Amazon S3. TensorFlow models saved in the SavedModel format can be directly used to create SageMaker Models by specifying the S3 path during deployment.
- B. Correct.
Correct: SageMaker provides a built-in ONNX serving container, which allows you to deploy models converted into the ONNX format.
- C. Incorrect.
Incorrect: SageMaker Neo is used to optimize and compile models for specific hardware, but it still requires the model to be uploaded to S3 for deployment.
- D. Correct.
Correct: You can package the model and its dependencies into a custom container and use SageMaker to deploy it. This is a common method for models built outside of SageMaker.
- E. Incorrect.
Incorrect: SageMaker Ground Truth is a data labeling service and cannot be used to transform or deploy models.