Skip to content

Commit 3ab6411

Browse files
authored
fix: use unique job name in hyperparameter tuning test (#829)
1 parent 11b5442 commit 3ab6411

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

tests/integ/test_tuner.py

+4-3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright 2017 Amazon.com, Inc. or its affiliates. All Rights Reserved.
1+
# Copyright 2017-2019 Amazon.com, Inc. or its affiliates. All Rights Reserved.
22
#
33
# Licensed under the Apache License, Version 2.0 (the "License"). You
44
# may not use this file except in compliance with the License. A copy of
@@ -60,7 +60,7 @@ def kmeans_train_set(sagemaker_session):
6060
def kmeans_estimator(sagemaker_session):
6161
kmeans = KMeans(role='SageMakerRole', train_instance_count=1,
6262
train_instance_type='ml.c4.xlarge',
63-
k=10, sagemaker_session=sagemaker_session, base_job_name='tk',
63+
k=10, sagemaker_session=sagemaker_session,
6464
output_path='s3://{}/'.format(sagemaker_session.default_bucket()))
6565
# set kmeans specific hp
6666
kmeans.init_method = 'random'
@@ -137,8 +137,9 @@ def test_tuning_kmeans(sagemaker_session,
137137
kmeans_train_set,
138138
kmeans_estimator,
139139
hyperparameter_ranges):
140+
job_name = unique_name_from_base('test-tune-kmeans')
140141
_tune_and_deploy(kmeans_estimator, kmeans_train_set, sagemaker_session,
141-
hyperparameter_ranges=hyperparameter_ranges)
142+
hyperparameter_ranges=hyperparameter_ranges, job_name=job_name)
142143

143144

144145
def test_tuning_kmeans_identical_dataset_algorithm_tuner_raw(sagemaker_session,

0 commit comments

Comments
 (0)