Skip to content

Commit 3db0ab2

Browse files
committed
change: updates based on PR feedback
1 parent 575292a commit 3db0ab2

File tree

3 files changed

+9
-25
lines changed

3 files changed

+9
-25
lines changed

src/sagemaker/amazon/amazon_estimator.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -611,8 +611,6 @@ def get_image_uri(region_name, repo_name, repo_version=1):
611611
"""Return algorithm image URI for the given AWS region, repository name, and
612612
repository version
613613
614-
TODO: consider refactoring version/repo validation into a module for all frameworks
615-
616614
Args:
617615
region_name:
618616
repo_name:

src/sagemaker/xgboost/defaults.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
XGBOOST_NAME = "xgboost"
1717
XGBOOST_1P_VERSIONS = ["1", "latest"]
1818

19-
# TODO: evaluate usefulness of these constants. they are defined here and only used here
2019
XGBOOST_VERSION_0_90_1 = "0.90-1"
2120
XGBOOST_VERSION_0_90_2 = "0.90-2"
2221

tests/conftest.py

Lines changed: 9 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,6 @@
3838

3939
NO_T2_REGIONS = ["eu-north-1", "ap-east-1", "me-south-1"]
4040

41-
# TODO: refactor handling of versions, repo, image uris, validations for all frameworks
42-
TENSORFLOW_LATEST_VERSION = "2.2.0"
43-
TENSORFLOW_LATEST_1X_VERSION = "1.15.2"
44-
4541

4642
def pytest_addoption(parser):
4743
parser.addoption("--sagemaker-client-config", action="store", default=None)
@@ -63,7 +59,7 @@ def pytest_addoption(parser):
6359
"--rl-ray-full-version", action="store", default=RLEstimator.RAY_LATEST_VERSION
6460
)
6561
parser.addoption("--sklearn-full-version", action="store", default="0.20.0")
66-
parser.addoption("--tf-full-version", action="store")
62+
parser.addoption("--tf-full-version", action="store", default="2.2.0")
6763
parser.addoption("--ei-tf-full-version", action="store")
6864
parser.addoption("--xgboost-full-version", action="store", default="1.0-1")
6965

@@ -289,8 +285,8 @@ def sklearn_full_version(request):
289285
return request.config.getoption("--sklearn-full-version")
290286

291287

292-
@pytest.fixture(scope="module", params=[TENSORFLOW_LATEST_VERSION])
293-
def tf_latest_version(request):
288+
@pytest.fixture(scope="module")
289+
def tf_latest_version(request, tf_full_version):
294290
return request.param
295291

296292

@@ -299,27 +295,18 @@ def tf_latest_py_version():
299295
return "py37"
300296

301297

302-
@pytest.fixture(scope="module", params=[TENSORFLOW_LATEST_1X_VERSION])
303-
def tf_latest_1x_version(request):
304-
return request.param
305-
306-
307298
@pytest.fixture(scope="module")
308299
def tf_latest_serving_version():
309300
return "2.1.0"
310301

311302

312-
@pytest.fixture(scope="module", params=[TENSORFLOW_LATEST_VERSION, TENSORFLOW_LATEST_1X_VERSION])
303+
@pytest.fixture(scope="module")
313304
def tf_full_version(request):
314-
tf_version = request.config.getoption("--tf-full-version")
315-
if tf_version is None:
316-
return request.param
317-
else:
318-
return tf_version
305+
return request.config.getoption("--tf-full-version")
319306

320307

321308
@pytest.fixture(scope="module")
322-
def tf_full_py_version(tf_full_version, tf_latest_version, tf_latest_1x_version):
309+
def tf_full_py_version(tf_full_version):
323310
"""fixture to match tf_full_version
324311
325312
Fixture exists as such, since tf_full_version may be overridden --tf-full-version.
@@ -330,9 +317,9 @@ def tf_full_py_version(tf_full_version, tf_latest_version, tf_latest_1x_version)
330317
version = [int(val) for val in tf_full_version.split(".")]
331318
if version < [1, 11]:
332319
return "py2"
333-
if tf_full_version in [tf_latest_version, tf_latest_1x_version]:
334-
return "py37"
335-
return "py3"
320+
if version < [2, 2]:
321+
return "py3"
322+
return "py37"
336323

337324

338325
@pytest.fixture(scope="module")

0 commit comments

Comments
 (0)