Skip to content

Commit c9474fc

Browse files
committed
upgrade to latest sagemaker-experiments
1 parent 5ab086d commit c9474fc

File tree

5 files changed

+47
-3
lines changed

5 files changed

+47
-3
lines changed

docker/1.15.0/py3/Dockerfile.cpu

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ RUN pip install --no-cache-dir -U \
100100
keras==2.3.1 \
101101
requests==2.22.0 \
102102
smdebug==0.5.0.post0 \
103-
sagemaker-experiments==0.1.3 \
103+
sagemaker-experiments==0.1.7 \
104104
mpi4py==3.0.2 \
105105
"cryptography>=2.3" \
106106
"sagemaker-tensorflow>=1.15,<1.16" \

docker/1.15.0/py3/Dockerfile.gpu

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ RUN pip install --no-cache-dir -U \
137137
requests==2.22.0 \
138138
keras==2.3.1 \
139139
smdebug==0.5.0.post0 \
140-
sagemaker-experiments==0.1.3 \
140+
sagemaker-experiments==0.1.7 \
141141
mpi4py==3.0.2 \
142142
"cryptography>=2.3" \
143143
"sagemaker-tensorflow>=1.15,<1.16" \

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ def read_version():
5959
'test': ['tox', 'flake8', 'pytest', 'pytest-cov', 'pytest-xdist', 'mock',
6060
'sagemaker==1.50.1', 'tensorflow<2.0', 'docker-compose', 'boto3==1.10.50',
6161
'six==1.13.0', 'python-dateutil>=2.1,<2.8.1', 'botocore==1.13.50',
62-
'requests-mock', 'awscli==1.16.314'],
62+
'requests-mock', 'awscli==1.16.314', 'sagemaker-experiments==0.1.7'],
6363
'benchmark': ['click']
6464
},
6565
)

test/integration/conftest.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,3 +116,10 @@ def docker_image(docker_base_name, tag):
116116
def ecr_image(account_id, docker_base_name, tag, region):
117117
return '{}.dkr.ecr.{}.amazonaws.com/{}:{}'.format(
118118
account_id, region, docker_base_name, tag)
119+
120+
121+
@pytest.fixture(autouse=True)
122+
def skip_py2_containers(request, tag):
123+
if request.node.get_closest_marker('skip_py2_containers'):
124+
if 'py2' in tag:
125+
pytest.skip('Skipping python2 container with tag {}'.format(tag))
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
# Copyright 2018-2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License").
4+
# You may not use this file except in compliance with the License.
5+
# A copy of the License is located at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# or in the "license" file accompanying this file. This file is distributed
10+
# on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
11+
# express or implied. See the License for the specific language governing
12+
# permissions and limitations under the License.
13+
from __future__ import absolute_import
14+
15+
import time
16+
17+
import pytest
18+
from smexperiments.experiment import Experiment
19+
20+
21+
@pytest.mark.skip_py2_containers
22+
@pytest.mark.skip_test_in_region
23+
def test_experiments(sagemaker_session, ecr_image, instance_type, instance_count):
24+
sm = sagemaker_session.sagemaker_client
25+
26+
experiment_name = f"tensorflow-container-integ-test-{int(time.time())}"
27+
28+
created_experiment = Experiment.create(
29+
experiment_name=experiment_name,
30+
description="Integration test experiment from DLC",
31+
sagemaker_boto_client=sm
32+
)
33+
print(created_experiment)
34+
35+
experiment = Experiment.load(experiment_name=experiment_name, sagemaker_boto_client=sm)
36+
37+
experiment.delete()

0 commit comments

Comments
 (0)