In the ModelArts notebook instance, you do not need to enter authentication parameters for session authentication. For details about session authentication of other development environments, see Session Authentication.
1 2 3 4 | from modelarts.session import Session from modelarts.estimator import VisualizationJob session = Session() job_visualization_instance_list = VisualizationJob.get_visualization_job_object_list(modelarts_session=session, is_show=True, status=8, per_page=10, page=1, sort_by="create_time", order="asc", search_content="job") |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
modelarts_session |
Yes |
Object |
Session object. For details about the initialization method, see Session Authentication. |
status |
No |
String |
Status of a visualization job. For details about the job statuses, see Job Statuses. |
per_page |
No |
Integer |
Number of jobs displayed on each page. The value range is [1, 100]. Default value: 10 |
page |
No |
Integer |
Index of the page to be queried. Default value: 1 |
sortBy/sort_by |
No |
String |
When AK/SK-based authentication is used, the parameter name is sortBy. When the username and password are used for authentication, the parameter name is sort_by. The parameter specifies the sorting mode of the query. The value can be job_name, job_desc, status, duration, create_time, or log_dir. Default value: job_name |
order |
No |
String |
Sorting order. The options are as follows:
|
search_content |
No |
String |
Search content, for example, a visualization job name. The value is a string of 0 to 100 characters. By default, this parameter is left blank. |
is_show |
No |
Boolean |
Whether to print the visualization job list. Default value: True |
Parameter |
Type |
Description |
---|---|---|
VisualizationJob |
Object |
Visualization job object. This object contains attributes such as visualization_id, create_time, job_name, and status, and operations on a visualization job, such as querying, modifying, stopping, restarting, or deleting the visualization job. |
Parameter |
Type |
Description |
---|---|---|
create_time |
Long |
Time when a visualization job is created |
job_name |
String |
Name of a visualization job |
status |
Byte |
Status of a visualization job. For details about the job statuses, see Job Statuses. |
job_id |
String |
ID of a visualization job |
is_success |
Boolean |
Whether the API call succeeds |