Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Hugging Face DLC images to sagemaker pre-built ecr image #21983

Merged
merged 2 commits into from
Dec 10, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .changelog/21983.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:enhancement
data/aws_sagemaker_prebuilt_ecr_image: Add Hugging Face DLCs
```
18 changes: 17 additions & 1 deletion internal/service/sagemaker/prebuilt_ecr_image_data_source.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,14 @@ const (
sageMakerRepositoryTensorFlowInferenceEIA = "tensorflow-inference-eia"
// SageMaker Repo TensorFlow Training
sageMakerRepositoryTensorFlowTraining = "tensorflow-training"
// SageMaker Repo HuggingFace TensorFlow Training
sageMakerRepositoryHuggingFaceTensorFlowTraining = "huggingface-tensorflow-training"
// SageMaker Repo HuggingFace TensorFlow Inference
sageMakerRepositoryHuggingFaceTensorFlowInference = "huggingface-tensorflow-inference"
// SageMaker Repo HuggingFace PyTorch Training
sageMakerRepositoryHuggingFacePyTorchTraining = "huggingface-pytorch-training"
// SageMaker Repo HuggingFace PyTorch Inference
sageMakerRepositoryHuggingFacePyTorchInference = "huggingface-pytorch-inference"
)

// https://docs.aws.amazon.com/sagemaker/latest/dg/sagemaker-algo-docker-registry-paths.html
Expand Down Expand Up @@ -295,6 +303,10 @@ func DataSourcePrebuiltECRImage() *schema.Resource {
sageMakerRepositoryTensorFlowServing,
sageMakerRepositoryTensorFlowServingEIA,
sageMakerRepositoryTensorFlowTraining,
sageMakerRepositoryHuggingFaceTensorFlowTraining,
sageMakerRepositoryHuggingFaceTensorFlowInference,
sageMakerRepositoryHuggingFacePyTorchTraining,
sageMakerRepositoryHuggingFacePyTorchInference,
sageMakerRepositoryXGBoost,
}, false),
},
Expand Down Expand Up @@ -367,7 +379,11 @@ func dataSourcePrebuiltECRImageRead(d *schema.ResourceData, meta interface{}) er
sageMakerRepositoryPyTorchTraining,
sageMakerRepositoryTensorFlowInference,
sageMakerRepositoryTensorFlowInferenceEIA,
sageMakerRepositoryTensorFlowTraining:
sageMakerRepositoryTensorFlowTraining,
sageMakerRepositoryHuggingFaceTensorFlowTraining,
sageMakerRepositoryHuggingFaceTensorFlowInference,
sageMakerRepositoryHuggingFacePyTorchTraining,
sageMakerRepositoryHuggingFacePyTorchInference:
id = sageMakerPrebuiltECRImageIDByRegion_DeepLearning[region]
default:
id = PrebuiltECRImageIDByRegion_FactorMachines[region]
Expand Down