Early Stopping a Trial of an Auto Search Job
Function
This API is used to manually stop a trial of an ongoing automated search job.
This API is used when you need to stop an experiment because its performance is poor or resource usage needs to be optimized. Before using this API, ensure that the auto search job exists and is in progress, and you have the permission to manage the job. After the operation is complete, the specified experiment is stopped, and related resources are released. If the auto search job does not exist, the specified experiment does not exist, or you do not have the required permission, the API will return an error message.
Debugging
You can debug this API through automatic authentication in API Explorer or use the SDK sample code generated by API Explorer.
Authorization Information
Each account has all the permissions required to call all APIs, but IAM users must be assigned the required permissions.
- If you are using role/policy-based authorization, see Permissions Policies and Supported Actions for details on the required permissions.
- If you are using identity policy-based authorization, the following identity policy-based permissions are required.
URI
POST /v2/{project_id}/training-jobs/{training_job_id}/autosearch-trial-earlystop/{trial_id}
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| project_id | Yes | String | Definition: Project ID. For details, see Obtaining a Project ID and Name. Constraints: N/A Range: The value can contain 1 to 64 characters. Only letters, digits, and hyphens (-) are allowed. Default Value: N/A |
| training_job_id | Yes | String | Definition: Training job ID. For details, see Obtaining Training Jobs. Constraints: N/A Range: N/A Default Value: N/A |
| trial_id | Yes | String | Definition: Trial ID of the hyperparameter search. Constraints: N/A Range: N/A Default Value: N/A |
Request Parameters
None
Response Parameters
Status code: 200
| Parameter | Type | Description |
|---|---|---|
| earlystop_trial | String | Definition: ID of the trial that is terminated in advance. Range: N/A |
Example Requests
The following shows how to early stop the trial whose trial_id is 50093e6c using the job whose training_job_id is e346206c-6fde-4c33-9dcd-55be17858ceb as an example.
POST https://{endpoint}/v2/{project_id}/training-jobs/e346206c-6fde-4c33-9dcd-55be17858ceb/autosearch-trial-earlystop/50093e6c Example Responses
Status code: 200
ok
{
"earlystop_trial" : "50093e6c"
} Status Codes
| Status Code | Description |
|---|---|
| 200 | ok |
Error Codes
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot