|
42 | 42 | secondary_training_status_changed,
|
43 | 43 | secondary_training_status_message,
|
44 | 44 | sts_regional_endpoint,
|
45 |
| - retries, |
46 | 45 | )
|
47 | 46 | from sagemaker import exceptions
|
48 | 47 | from sagemaker.session_settings import SessionSettings
|
@@ -5459,30 +5458,21 @@ def _train_done(sagemaker_client, job_name, last_desc):
|
5459 | 5458 | """Placeholder docstring"""
|
5460 | 5459 | in_progress_statuses = ["InProgress", "Created"]
|
5461 | 5460 |
|
5462 |
| - for _ in retries( |
5463 |
| - max_retry_count=10, # 10*30 = 5min |
5464 |
| - exception_message_prefix="Waiting for schedule to leave 'Pending' status", |
5465 |
| - seconds_to_sleep=30, |
5466 |
| - ): |
5467 |
| - try: |
5468 |
| - desc = sagemaker_client.describe_training_job(TrainingJobName=job_name) |
5469 |
| - status = desc["TrainingJobStatus"] |
| 5461 | + desc = sagemaker_client.describe_training_job(TrainingJobName=job_name) |
| 5462 | + status = desc["TrainingJobStatus"] |
5470 | 5463 |
|
5471 |
| - if secondary_training_status_changed(desc, last_desc): |
5472 |
| - print() |
5473 |
| - print(secondary_training_status_message(desc, last_desc), end="") |
5474 |
| - else: |
5475 |
| - print(".", end="") |
5476 |
| - sys.stdout.flush() |
| 5464 | + if secondary_training_status_changed(desc, last_desc): |
| 5465 | + print() |
| 5466 | + print(secondary_training_status_message(desc, last_desc), end="") |
| 5467 | + else: |
| 5468 | + print(".", end="") |
| 5469 | + sys.stdout.flush() |
5477 | 5470 |
|
5478 |
| - if status in in_progress_statuses: |
5479 |
| - return desc, False |
| 5471 | + if status in in_progress_statuses: |
| 5472 | + return desc, False |
5480 | 5473 |
|
5481 |
| - print() |
5482 |
| - return desc, True |
5483 |
| - except botocore.exceptions.ClientError as err: |
5484 |
| - if err.response["Error"]["Code"] == "AccessDeniedException": |
5485 |
| - pass |
| 5474 | + print() |
| 5475 | + return desc, True |
5486 | 5476 |
|
5487 | 5477 |
|
5488 | 5478 | def _processing_job_status(sagemaker_client, job_name):
|
|
0 commit comments