Skip to content

Commit f34d2ac

Browse files
author
Rohit Kumar Srivastava
committed
add unit tests for tensorflow and update version for pytorch. Added all supported regions for integration tests
1 parent 796f2cd commit f34d2ac

File tree

3 files changed

+536
-8
lines changed

3 files changed

+536
-8
lines changed

tests/integ/__init__.py

+20
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,26 @@
158158
]
159159
# TODO: SM Training Compiler team to add all supported regions.
160160
TRAINING_COMPILER_SUPPORTED_REGIONS = [
161+
"af-south-1",
162+
"ap-east-1",
163+
"ap-northeast-1",
164+
"ap-northeast-2",
165+
"ap-northeast-3",
166+
"ap-south-1",
167+
"ap-southeast-1",
168+
"ap-southeast-2",
169+
"ca-central-1",
170+
"eu-central-1",
171+
"eu-north-1",
172+
"eu-south-1",
173+
"eu-west-1",
174+
"eu-west-2",
175+
"eu-west-3",
176+
"me-south-1",
177+
"sa-east-1",
178+
"us-east-1",
179+
"us-east-2",
180+
"us-west-1",
161181
"us-west-2",
162182
]
163183
# Data parallelism need to be tested with p3.16xlarge.

tests/unit/sagemaker/training_compiler/test_huggingface_compiler.py renamed to tests/unit/sagemaker/training_compiler/test_huggingface_pytorch_compiler.py

+8-8
Original file line numberDiff line numberDiff line change
@@ -158,9 +158,9 @@ def test_unsupported_BYOC(
158158
):
159159
byoc = (
160160
"1.dkr.ecr.us-east-1.amazonaws.com/huggingface-pytorch-trcomp-training:"
161-
"1.9.0-"
162-
"transformers4.10.2-gpu-"
163-
"py38-cu111-ubuntu20.04"
161+
"1.10.2-"
162+
"transformers4.17.0-gpu-"
163+
"py38-cu113-ubuntu20.04"
164164
)
165165
with pytest.raises(ValueError):
166166
HuggingFace(
@@ -451,9 +451,9 @@ def test_attach(
451451
):
452452
training_image = (
453453
"1.dkr.ecr.us-east-1.amazonaws.com/huggingface-pytorch-trcomp-training:"
454-
"1.9.0-"
455-
"transformers4.10.2-gpu-"
456-
"py38-cu111-ubuntu20.04"
454+
"1.10.2-"
455+
"transformers4.17.0-gpu-"
456+
"py38-cu113-ubuntu20.04"
457457
)
458458
returned_job_description = {
459459
"AlgorithmSpecification": {"TrainingInputMode": "File", "TrainingImage": training_image},
@@ -488,8 +488,8 @@ def test_attach(
488488
estimator = HuggingFace.attach(training_job_name="hopper", sagemaker_session=sagemaker_session)
489489
assert estimator.latest_training_job.job_name == "hopper"
490490
assert estimator.py_version == "py38"
491-
assert estimator.framework_version == "4.10.2"
492-
assert estimator.pytorch_version == "1.9.0"
491+
assert estimator.framework_version == "4.17.0"
492+
assert estimator.pytorch_version == "1.10.2"
493493
assert estimator.role == "arn:aws:iam::366:role/SageMakerRole"
494494
assert estimator.instance_count == 1
495495
assert estimator.max_run == 24 * 60 * 60

0 commit comments

Comments
 (0)