Skip to content

Commit 49755c7

Browse files
authored
fix: fix regions for updated RL images (#1805)
1 parent 5f8a5d0 commit 49755c7

File tree

6 files changed

+26
-16
lines changed

6 files changed

+26
-16
lines changed

src/sagemaker/image_uri_config/coach-tensorflow.json

-3
Original file line numberDiff line numberDiff line change
@@ -157,11 +157,8 @@
157157
"ap-southeast-2": "462105765813",
158158
"ca-central-1": "462105765813",
159159
"eu-central-1": "462105765813",
160-
"eu-north-1": "462105765813",
161160
"eu-west-1": "462105765813",
162161
"eu-west-2": "462105765813",
163-
"eu-west-3": "462105765813",
164-
"sa-east-1": "462105765813",
165162
"us-east-1": "462105765813",
166163
"us-east-2": "462105765813",
167164
"us-west-1": "462105765813",

src/sagemaker/image_uri_config/ray-pytorch.json

-3
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,8 @@
1212
"ap-southeast-2": "462105765813",
1313
"ca-central-1": "462105765813",
1414
"eu-central-1": "462105765813",
15-
"eu-north-1": "462105765813",
1615
"eu-west-1": "462105765813",
1716
"eu-west-2": "462105765813",
18-
"eu-west-3": "462105765813",
19-
"sa-east-1": "462105765813",
2017
"us-east-1": "462105765813",
2118
"us-east-2": "462105765813",
2219
"us-west-1": "462105765813",

src/sagemaker/image_uri_config/ray-tensorflow.json

-6
Original file line numberDiff line numberDiff line change
@@ -128,11 +128,8 @@
128128
"ap-southeast-2": "462105765813",
129129
"ca-central-1": "462105765813",
130130
"eu-central-1": "462105765813",
131-
"eu-north-1": "462105765813",
132131
"eu-west-1": "462105765813",
133132
"eu-west-2": "462105765813",
134-
"eu-west-3": "462105765813",
135-
"sa-east-1": "462105765813",
136133
"us-east-1": "462105765813",
137134
"us-east-2": "462105765813",
138135
"us-west-1": "462105765813",
@@ -151,11 +148,8 @@
151148
"ap-southeast-2": "462105765813",
152149
"ca-central-1": "462105765813",
153150
"eu-central-1": "462105765813",
154-
"eu-north-1": "462105765813",
155151
"eu-west-1": "462105765813",
156152
"eu-west-2": "462105765813",
157-
"eu-west-3": "462105765813",
158-
"sa-east-1": "462105765813",
159153
"us-east-1": "462105765813",
160154
"us-east-2": "462105765813",
161155
"us-west-1": "462105765813",

src/sagemaker/image_uri_config/vw.json

-3
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,8 @@
1111
"ap-southeast-2": "462105765813",
1212
"ca-central-1": "462105765813",
1313
"eu-central-1": "462105765813",
14-
"eu-north-1": "462105765813",
1514
"eu-west-1": "462105765813",
1615
"eu-west-2": "462105765813",
17-
"eu-west-3": "462105765813",
18-
"sa-east-1": "462105765813",
1916
"us-east-1": "462105765813",
2017
"us-east-2": "462105765813",
2118
"us-west-1": "462105765813",

tests/integ/__init__.py

+17
Original file line numberDiff line numberDiff line change
@@ -72,11 +72,28 @@
7272
"us-west-2",
7373
]
7474

75+
RL_SUPPORTED_REGIONS = (
76+
"ap-northeast-1",
77+
"ap-northeast-2",
78+
"ap-south-1",
79+
"ap-southeast-1",
80+
"ap-southeast-2",
81+
"ca-central-1",
82+
"eu-central-1",
83+
"eu-west-1",
84+
"eu-west-2",
85+
"us-east-1",
86+
"us-east-2",
87+
"us-west-1",
88+
"us-west-2",
89+
)
90+
7591
NO_LDA_REGIONS = ["eu-west-3", "eu-north-1", "sa-east-1", "ap-east-1", "me-south-1"]
7692
NO_MARKET_PLACE_REGIONS = ["eu-west-3", "eu-north-1", "sa-east-1", "ap-east-1", "me-south-1"]
7793
NO_AUTO_ML_REGIONS = ["sa-east-1", "me-south-1", "ap-east-1", "eu-west-3"]
7894
NO_MODEL_MONITORING_REGIONS = ["me-south-1"]
7995

96+
8097
EFS_TEST_ENABLED_REGION = []
8198

8299
logging.getLogger("boto3").setLevel(logging.INFO)

tests/integ/test_rl.py

+9-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
from sagemaker.rl import RLEstimator, RLFramework, RLToolkit
2121
from sagemaker.utils import sagemaker_timestamp, unique_name_from_base
22-
from tests.integ import DATA_DIR
22+
from tests.integ import DATA_DIR, RL_SUPPORTED_REGIONS, test_region
2323
from tests.integ.timeout import timeout, timeout_and_delete_endpoint_by_name
2424

2525

@@ -51,6 +51,10 @@ def test_coach_mxnet(sagemaker_session, coach_mxnet_latest_version, cpu_instance
5151
assert 0 < action[0][1] < 1
5252

5353

54+
@pytest.mark.skipif(
55+
test_region() not in RL_SUPPORTED_REGIONS,
56+
reason="Updated RL images aren't in {}".format(test_region()),
57+
)
5458
def test_coach_tf(sagemaker_session, coach_tensorflow_latest_version, cpu_instance_type):
5559
estimator = _test_coach(
5660
sagemaker_session,
@@ -98,6 +102,10 @@ def _test_coach(sagemaker_session, rl_framework, rl_coach_version, cpu_instance_
98102
)
99103

100104

105+
@pytest.mark.skipif(
106+
test_region() not in RL_SUPPORTED_REGIONS,
107+
reason="Updated RL images aren't in {}".format(test_region()),
108+
)
101109
@pytest.mark.canary_quick
102110
def test_ray_tf(sagemaker_session, ray_tensorflow_latest_version, cpu_instance_type):
103111
source_dir = os.path.join(DATA_DIR, "ray_cartpole")

0 commit comments

Comments
 (0)