MLS-C01 Modeling • Complete Question Bank
Complete MLS-C01 Modeling question bank — all 0 questions with answers and detailed explanations.
Refer to the exhibit. ``` Training job status: Failed Error: ClientError: Data download failed. The downloaded file size (0 bytes) does not match expected size (1024 bytes). Check that the S3 object exists and is readable. ```
Refer to the exhibit.
```
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateTrainingJob",
"sagemaker:DescribeTrainingJob",
"sagemaker:StopTrainingJob"
],
"Resource": "*"
},
{
"Effect": "Allow",
"Action": [
"s3:GetObject",
"s3:PutObject"
],
"Resource": "arn:aws:s3:::my-bucket/*"
}
]
}
```Drag steps to the numbered slots on the right, or tap a step then tap a slot.
Drag steps to the numbered slots on the right, or tap a step then tap a slot.
Drag a concept onto its matching description — or click a concept then click the description.
Exhaustive search over specified hyperparameter values
Random sampling of hyperparameter combinations
Probabilistic model to guide search
Early stopping and resource allocation
SageMaker automatic tuning
Drag a concept onto its matching description — or click a concept then click the description.
Natural language processing
Language translation
Text-to-speech
Speech-to-text
Conversational chatbots
Refer to the exhibit.
```
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateTrainingJob",
"sagemaker:CreateModel",
"sagemaker:CreateEndpointConfig",
"sagemaker:CreateEndpoint"
],
"Resource": "*"
}
]
}
```Refer to the exhibit.
```
aws sagemaker create-training-job \
--training-job-name my-training-job \
--algorithm-specification TrainingImage=382416733822.dkr.ecr.us-east-1.amazonaws.com/linear-learner:1,TrainingInputMode=File \
--role-arn arn:aws:iam::123456789012:role/SageMakerRole \
--input-data-config [{"ChannelName":"train","DataSource":{"S3DataSource":{"S3DataType":"AugmentedManifestFile","S3Uri":"s3://bucket/train.manifest","S3DataDistributionType":"FullyReplicated"}},"ContentType":"application/x-recordio"}] \
--output-data-config S3OutputPath=s3://bucket/output \
--resource-config InstanceType=ml.m5.large,InstanceCount=1,VolumeSizeInGB=10 \
--stopping-condition MaxRuntimeInSeconds=3600Refer to the exhibit.
```
{
"DataQualityCheckConfig": {
"DatasetFormat": {
"Csv": {
"Header": true
}
},
"KmsKeyId": "",
"S3OutputPath": "s3://bucket/datachecks/",
"LocalPath": "/opt/ml/processing/output"
},
"DataQualityJobInput": {
"EndpointInput": {
"EndpointName": "my-endpoint",
"LocalPath": "/opt/ml/processing/input",
"S3InputMode": "File",
"S3DataDistributionType": "FullyReplicated",
"InferenceAttribute": "predicted_label",
"ProbabilityAttribute": "probability",
"ProbabilityThresholdAttribute": "0.5",
"StartTimeOffset": "-PT1H",
"EndTimeOffset": "-PT0H"
}
}
}
```Refer to the exhibit.
```
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"s3:GetObject",
"s3:PutObject"
],
"Resource": "arn:aws:s3:::my-bucket/*"
},
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateTrainingJob",
"sagemaker:CreateModel",
"sagemaker:CreateEndpointConfig",
"sagemaker:CreateEndpoint"
],
"Resource": "*"
}
]
}
```Refer to the exhibit.
```
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"s3:GetObject",
"s3:PutObject"
],
"Resource": "arn:aws:s3:::my-bucket/training-data/*"
},
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateTrainingJob",
"sagemaker:CreateModel"
],
"Resource": "*"
}
]
}
```Refer to the exhibit.
```
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": "sagemaker:CreateTrainingJob",
"Resource": "*"
},
{
"Effect": "Allow",
"Action": "s3:GetObject",
"Resource": "arn:aws:s3:::my-bucket/training/*"
}
]
}
```Refer to the exhibit.
```
{
"name": "my-training-job",
"hyperParameters": {
"max_depth": "10",
"eta": "0.1",
"subsample": "0.8",
"colsample_bytree": "0.8",
"num_round": "100"
},
"trainingJobStatus": "Failed",
"failureReason": "AlgorithmError: /opt/program/src/sagemaker_xgboost_container/algorithm_mode/...
Message: The pipeline has been stopped. There was a numeric overflow in the tree."
}Refer to the exhibit.
```
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateTrainingJob",
"sagemaker:DescribeTrainingJob"
],
"Resource": "*"
},
{
"Effect": "Allow",
"Action": [
"s3:GetObject"
],
"Resource": "arn:aws:s3:::my-bucket/*"
},
{
"Effect": "Deny",
"Action": [
"s3:GetObject"
],
"Resource": "arn:aws:s3:::my-bucket/confidential/*"
}
]
}
```Refer to the exhibit.
```
{
"ModelName": "my-model",
"PrimaryContainer": {
"Image": "382416733822.dkr.ecr.us-east-1.amazonaws.com/linear-learner:1",
"ModelDataUrl": "s3://my-bucket/model.tar.gz",
"Environment": {
"SAGEMAKER_CONTAINER_LOG_LEVEL": "20",
"SAGEMAKER_REGION": "us-east-1"
}
},
"ExecutionRoleArn": "arn:aws:iam::123456789012:role/SageMakerRole"
}
```Refer to the exhibit.
```
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateTrainingJob",
"sagemaker:CreateModel",
"sagemaker:CreateEndpointConfig",
"sagemaker:CreateEndpoint"
],
"Resource": "*"
},
{
"Effect": "Allow",
"Action": "s3:GetObject",
"Resource": "arn:aws:s3:::my-bucket/training-data/*"
},
{
"Effect": "Allow",
"Action": "s3:PutObject",
"Resource": "arn:aws:s3:::my-bucket/output/*"
}
]
}
```Refer to the exhibit. ``` 2019-11-01 10:23:45 Starting - Preparing the instances for training 2019-11-01 10:24:01 Downloading - Downloading input data 2019-11-01 10:24:15 Training - Training image download completed. Training in progress. 2019-11-01 10:25:30 Training - Training completed. 2019-11-01 10:25:31 Uploading - Uploading generated model artifacts 2019-11-01 10:25:35 Completed - Training job completed ```
Refer to the exhibit.
```
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": "sagemaker:CreateTrainingJob",
"Resource": "*"
},
{
"Effect": "Allow",
"Action": "sagemaker:CreateModel",
"Resource": "*"
},
{
"Effect": "Allow",
"Action": "sagemaker:CreateEndpointConfig",
"Resource": "*"
},
{
"Effect": "Allow",
"Action": "sagemaker:CreateEndpoint",
"Resource": "*"
}
]
}
```Refer to the exhibit.
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateTrainingJob",
"sagemaker:DescribeTrainingJob"
],
"Resource": "*"
},
{
"Effect": "Allow",
"Action": "s3:GetObject",
"Resource": "arn:aws:s3:::my-bucket/training/*"
}
]
}Refer to the exhibit.
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateTrainingJob",
"sagemaker:CreateModel",
"sagemaker:CreateEndpointConfig",
"sagemaker:CreateEndpoint"
],
"Resource": "*"
},
{
"Effect": "Allow",
"Action": [
"s3:GetObject",
"s3:PutObject"
],
"Resource": "arn:aws:s3:::my-bucket/*"
}
]
}Refer to the exhibit.
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"s3:GetObject",
"s3:PutObject",
"s3:DeleteObject"
],
"Resource": "arn:aws:s3:::my-bucket/training-data/*"
},
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateTrainingJob",
"sagemaker:DescribeTrainingJob"
],
"Resource": "*"
}
]
}Refer to the exhibit.
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": "sagemaker:CreateTrainingJob",
"Resource": "*",
"Condition": {
"StringEquals": {
"sagemaker:TrainingJobStatus": "Failed"
}
}
}
]
}Refer to the exhibit.
$ aws sagemaker create-training-job \
--training-job-name my-job \
--algorithm-specification TrainingImage=382416733822.dkr.ecr.us-west-2.amazonaws.com/xgboost:latest,TrainingInputMode=File \
--role-arn arn:aws:iam::123456789012:role/SageMakerRole \
--input-data-config "[{\"ChannelName\": \"train\", \"DataSource\": {\"S3DataSource\": {\"S3DataType\": \"S3Prefix\", \"S3Uri\": \"s3://my-bucket/train/\", \"S3DataDistributionType\": \"FullyReplicated\"}}}]" \
--output-data-config "{\"S3OutputPath\": \"s3://my-bucket/output/\"}" \
--resource-config "{\"InstanceType\": \"ml.m5.large\", \"InstanceCount\": 1}" \
--stopping-condition "{\"MaxRuntimeInSeconds\": 86400}"Refer to the exhibit.
Confusion Matrix:
Predicted Positive Predicted Negative
Actual Positive 80 20
Actual Negative 10 90Refer to the exhibit.
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateTrainingJob",
"sagemaker:DescribeTrainingJob"
],
"Resource": "*"
},
{
"Effect": "Allow",
"Action": [
"s3:GetObject"
],
"Resource": "arn:aws:s3:::my-bucket/training-data/*"
}
]
}Refer to the exhibit.
resource "aws_sagemaker_notebook_instance" "my_notebook" {
name = "my-notebook"
role_arn = aws_iam_role.notebook_role.arn
instance_type = "ml.t2.medium"
lifecycle_config_name = aws_sagemaker_notebook_instance_lifecycle_configuration.my_config.name
}Refer to the exhibit.
```
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateTrainingJob",
"sagemaker:DescribeTrainingJob"
],
"Resource": "*"
},
{
"Effect": "Allow",
"Action": [
"s3:GetObject"
],
"Resource": "arn:aws:s3:::my-bucket/training/*"
},
{
"Effect": "Allow",
"Action": [
"s3:PutObject"
],
"Resource": "arn:aws:s3:::my-bucket/output/*"
}
]
}
```Refer to the exhibit.
```
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"s3:GetObject",
"s3:PutObject"
],
"Resource": "arn:aws:s3:::my-bucket/*",
"Condition": {
"StringEquals": {
"s3:x-amz-server-side-encryption": "AES256"
}
}
},
{
"Effect": "Deny",
"Action": "s3:PutObject",
"Resource": "arn:aws:s3:::my-bucket/*",
"Condition": {
"StringNotEquals": {
"s3:x-amz-server-side-encryption": "AES256"
}
}
}
]
}
```Refer to the exhibit.
```
{
"predicted_label": "spam",
"predicted_probability": 0.95,
"label": "ham"
}
```Refer to the exhibit.
```
aws sagemaker create-training-job \
--training-job-name my-job \
--algorithm-specification TrainingImage=123456789012.dkr.ecr.us-east-1.amazonaws.com/my-image:latest,TrainingInputMode=File \
--role-arn arn:aws:iam::123456789012:role/SageMakerRole \
--input-data-config '[{"ChannelName": "train", "DataSource": {"S3DataSource": {"S3DataType": "S3Prefix", "S3Uri": "s3://bucket/train/"}}}]' \
--output-data-config S3OutputPath=s3://bucket/output/ \
--resource-config InstanceType=ml.c5.xlarge,InstanceCount=1,VolumeSizeInGB=10 \
--stopping-condition MaxRuntimeInSeconds=3600
```Refer to the exhibit. ``` [Container] Training completed. [Container] Uploading model artifacts to S3: s3://my-bucket/model.tar.gz [Container] Training job completed ```
Refer to the exhibit.
```
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateEndpoint"
],
"Resource": "*"
},
{
"Effect": "Allow",
"Action": [
"sagemaker:InvokeEndpoint"
],
"Resource": "arn:aws:sagemaker:us-east-1:123456789012:endpoint/my-endpoint"
}
]
}
```Refer to the exhibit.
```
aws sagemaker create-training-job \
--training-job-name my-job \
--algorithm-specification TrainingImage=123456789012.dkr.ecr.us-east-1.amazonaws.com/my-custom-image:latest,TrainingInputMode=File \
--role-arn arn:aws:iam::123456789012:role/SageMakerRole \
--input-data-config ChannelName=training,DataSource={S3DataSource={S3Uri=s3://my-bucket/train/,S3DataType=S3Prefix,S3DataDistributionType=FullyReplicated}} \
--output-data-config S3OutputPath=s3://my-bucket/output/ \
--resource-config InstanceType=ml.m5.large,InstanceCount=1,VolumeSizeInGB=10 \
--stopping-condition MaxRuntimeInSeconds=3600
```Refer to the exhibit.
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateTrainingJob",
"sagemaker:DescribeTrainingJob",
"s3:GetObject",
"s3:PutObject"
],
"Resource": "*"
},
{
"Effect": "Deny",
"Action": [
"sagemaker:CreateEndpoint"
],
"Resource": "*"
}
]
}Refer to the exhibit.
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateTrainingJob",
"sagemaker:CreateModel",
"sagemaker:CreateEndpointConfig",
"sagemaker:CreateEndpoint",
"sagemaker:InvokeEndpoint"
],
"Resource": "*"
}
]
}Refer to the exhibit.
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"s3:GetObject",
"s3:PutObject"
],
"Resource": "arn:aws:s3:::my-bucket/*"
},
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateTrainingJob",
"sagemaker:CreateModel",
"sagemaker:CreateEndpointConfig",
"sagemaker:CreateEndpoint"
],
"Resource": "*"
}
]
}Refer to the exhibit.
```
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateTrainingJob",
"sagemaker:DescribeTrainingJob",
"sagemaker:StopTrainingJob"
],
"Resource": "*"
},
{
"Effect": "Allow",
"Action": [
"s3:GetObject",
"s3:PutObject"
],
"Resource": "arn:aws:s3:::my-bucket/*"
}
]
}
```Refer to the exhibit.
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"s3:GetObject",
"s3:PutObject"
],
"Resource": "arn:aws:s3:::my-bucket/train/*"
},
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateTrainingJob",
"sagemaker:DescribeTrainingJob"
],
"Resource": "*"
}
]
}Refer to the exhibit. [2019-10-15 14:33:12.123] [INFO] [stdout] [100/100] Epoch: 0, Train Loss: 0.69, Validation Loss: 0.68 [2019-10-15 14:33:12.124] [INFO] [stdout] [100/100] Epoch: 1, Train Loss: 0.68, Validation Loss: 0.68 [2019-10-15 14:33:12.125] [INFO] [stdout] [100/100] Epoch: 2, Train Loss: 0.66, Validation Loss: 0.67 [2019-10-15 14:33:12.126] [INFO] [stdout] [100/100] Epoch: 3, Train Loss: 0.65, Validation Loss: 0.68 [2019-10-15 14:33:12.127] [INFO] [stdout] [100/100] Epoch: 4, Train Loss: 0.63, Validation Loss: 0.67
Refer to the exhibit.
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"sagemaker:CreateTrainingJob",
"sagemaker:CreateModel",
"sagemaker:CreateEndpointConfig",
"sagemaker:CreateEndpoint"
],
"Resource": "*"
},
{
"Effect": "Allow",
"Action": "s3:GetObject",
"Resource": "arn:aws:s3:::my-bucket/training-data/*"
}
]
}Refer to the exhibit.
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"s3:PutObject",
"s3:GetObject"
],
"Resource": "arn:aws:s3:::my-bucket/output/*"
},
{
"Effect": "Allow",
"Action": "iam:PassRole",
"Resource": "arn:aws:iam::123456789012:role/SageMakerRole"
}
]
}