Small edits ()

This commit is contained in:
pollfly 2024-04-03 12:06:28 +03:00 committed by GitHub
parent 3ad296ab0b
commit 6e20f6ab0e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 15 additions and 11 deletions

View File

@ -14,7 +14,7 @@ This reference page is organized by configuration file section:
* [files](#files-section) - Define auto-generated files to apply into local file system * [files](#files-section) - Define auto-generated files to apply into local file system
An example configuration file is located [here](https://github.com/allegroai/clearml-agent/blob/master/docs/clearml.conf), See an [example configuration file](https://github.com/allegroai/clearml-agent/blob/master/docs/clearml.conf),
in the ClearML Agent GitHub repository. in the ClearML Agent GitHub repository.
:::info :::info

View File

@ -13,13 +13,13 @@ This example accomplishes a task pipe by doing the following:
1. Creating the template Task which is named `Toy Base Task`. It must be stored in ClearML Server before instances of 1. Creating the template Task which is named `Toy Base Task`. It must be stored in ClearML Server before instances of
it can be created. To create it, run another ClearML example script, [toy_base_task.py](https://github.com/allegroai/clearml/blob/master/examples/automation/toy_base_task.py). it can be created. To create it, run another ClearML example script, [toy_base_task.py](https://github.com/allegroai/clearml/blob/master/examples/automation/toy_base_task.py).
The template Task has a parameter dictionary, which is connected to the Task: `{'Example_Param': 1}`. The template Task has a parameter dictionary, which is connected to the Task: `{'Example_Param': 1}`.
1. Back in `programmatic_orchestration.py`, creating a parameter dictionary, which is connected to the Task by calling [Task.connect](../../references/sdk/task.md#connect) 1. Back in `programmatic_orchestration.py`, creating a parameter dictionary, which is connected to the Task by calling [`Task.connect`](../../references/sdk/task.md#connect)
so that the parameters are logged by ClearML. The dictionary contains the name of the parameter from the template so that the parameters are logged by ClearML. The dictionary contains the name of the parameter from the template
Task that is going to be customized (`Example_Param`), as well as its new value. Task that is going to be customized (`Example_Param`), as well as its new value.
1. Creating a Task object referencing the template Task. See [Task.get_task](../../references/sdk/task.md#taskget_task). 1. Creating a Task object referencing the template Task. See [`Task.get_task`](../../references/sdk/task.md#taskget_task).
1. Creating an instance of the template Task by cloning it. 1. Creating an instance of the template Task by cloning it.
1. Getting the newly cloned Task's parameters. See [Task.get_parameters](../../references/sdk/task.md#get_parameters). 1. Getting the newly cloned Task's parameters. See [`Task.get_parameters`](../../references/sdk/task.md#get_parameters).
1. Setting the newly cloned Task's parameters to the search values in the parameter dictionary (Step 2). See [Task.set_parameters](../../references/sdk/task.md#set_parameters). 1. Setting the newly cloned Task's parameters to the search values in the parameter dictionary (Step 2). See [`Task.set_parameters`](../../references/sdk/task.md#set_parameters).
1. Enqueuing the newly cloned Task to execute. See [Task.enqueue](../../references/sdk/task.md#taskenqueue). 1. Enqueuing the newly cloned Task to execute. See [`Task.enqueue`](../../references/sdk/task.md#taskenqueue).
When the example script runs, it creates an instance of the template experiment, named `Auto generated cloned task` in the `examples` project. In the instance, the value of the customized parameter, `Example_Param` changed to `3`. You can see it in **CONFIGURATION** **>** **HYPERPARAMETERS**. When the example script runs, it creates an instance of the template experiment, named `Auto generated cloned task` in the `examples` project. In the instance, the value of the customized parameter, `Example_Param` changed to `3`. You can see it in **CONFIGURATION** **>** **HYPERPARAMETERS**.

View File

@ -27,7 +27,7 @@ of the subprocess, making each unique.
```python ```python
Task.current_task().upload_artifact( Task.current_task().upload_artifact(
'temp {:02d}'.format(dist.get_rank()), name='temp {:02d}'.format(dist.get_rank()),
artifact_object={'worker_rank': dist.get_rank()} artifact_object={'worker_rank': dist.get_rank()}
) )
``` ```

View File

@ -28,7 +28,8 @@ on `Task.current_task` (the main Task). The dictionary contains the `dist.rank`
```python ```python
Task.current_task().upload_artifact( Task.current_task().upload_artifact(
'temp {:02d}'.format(dist.get_rank()), artifact_object={'worker_rank': dist.get_rank()} name='temp {:02d}'.format(dist.get_rank()),
artifact_object={'worker_rank': dist.get_rank()}
) )
``` ```
@ -44,7 +45,10 @@ same title (`loss`), but a different series name (containing the subprocess' `ra
```python ```python
Task.current_task().get_logger().report_scalar( Task.current_task().get_logger().report_scalar(
'loss', 'worker {:02d}'.format(dist.get_rank()), value=loss.item(), iteration=i title='loss',
series='worker {:02d}'.format(dist.get_rank()),
value=loss.item(),
iteration=i
) )
``` ```

View File

@ -141,8 +141,8 @@ module.exports = {
'webapp/applications/apps_trigger_manager', 'webapp/applications/apps_trigger_manager',
'webapp/applications/apps_jupyter_lab', 'webapp/applications/apps_jupyter_lab',
'webapp/applications/apps_vscode', 'webapp/applications/apps_vscode',
'webapp/applications/gradio', 'webapp/applications/apps_gradio',
'webapp/applications/streamlit' 'webapp/applications/apps_streamlit'
] ]
}, },