"git@developer.sourcefind.cn:chenpangpang/transformers.git" did not exist on "be4a6c64dcd67e64cedb5b5eb220bc7a8b128121"
Unverified Commit 173193cc authored by Sabine's avatar Sabine Committed by GitHub
Browse files

Update Neptune docs (#22452)

parent 5e89a435
...@@ -262,13 +262,13 @@ First, install the Neptune client library. You can do it with either `pip` or `c ...@@ -262,13 +262,13 @@ First, install the Neptune client library. You can do it with either `pip` or `c
`pip`: `pip`:
```bash ```bash
pip install neptune-client pip install neptune
``` ```
`conda`: `conda`:
```bash ```bash
conda install -c conda-forge neptune-client conda install -c conda-forge neptune
``` ```
Next, in your model training script, import `NeptuneCallback`: Next, in your model training script, import `NeptuneCallback`:
...@@ -283,8 +283,8 @@ To enable Neptune logging, in your `TrainingArguments`, set the `report_to` argu ...@@ -283,8 +283,8 @@ To enable Neptune logging, in your `TrainingArguments`, set the `report_to` argu
training_args = TrainingArguments( training_args = TrainingArguments(
"quick-training-distilbert-mrpc", "quick-training-distilbert-mrpc",
evaluation_strategy="steps", evaluation_strategy="steps",
eval_steps = 20, eval_steps=20,
report_to = "neptune", report_to="neptune",
) )
trainer = Trainer( trainer = Trainer(
...@@ -294,6 +294,8 @@ trainer = Trainer( ...@@ -294,6 +294,8 @@ trainer = Trainer(
) )
``` ```
**Note:** This method requires saving your Neptune credentials as environment variables (see the bottom of the section).
Alternatively, for more logging options, create a Neptune callback: Alternatively, for more logging options, create a Neptune callback:
```python ```python
...@@ -318,7 +320,7 @@ neptune_callback = NeptuneCallback( ...@@ -318,7 +320,7 @@ neptune_callback = NeptuneCallback(
Pass the callback to the Trainer: Pass the callback to the Trainer:
```python ```python
training_args = TrainingArguments(..., report_to = None) training_args = TrainingArguments(..., report_to=None)
trainer = Trainer( trainer = Trainer(
model, model,
training_args, training_args,
...@@ -336,7 +338,7 @@ Now, when you start the training with `trainer.train()`, your metadata will be l ...@@ -336,7 +338,7 @@ Now, when you start the training with `trainer.train()`, your metadata will be l
| `NEPTUNE_API_TOKEN` | Your Neptune API token. To find and copy it, click your Neptune avatar and select **Get your API token**. | | `NEPTUNE_API_TOKEN` | Your Neptune API token. To find and copy it, click your Neptune avatar and select **Get your API token**. |
| `NEPTUNE_PROJECT` | The full name of your Neptune project (`workspace-name/project-name`). To find and copy it, head to **project settings** → **Properties**. | | `NEPTUNE_PROJECT` | The full name of your Neptune project (`workspace-name/project-name`). To find and copy it, head to **project settings** → **Properties**. |
For detailed instructions and examples, see the [Neptune docs](https://docs.neptune.ai/integrations-and-supported-tools/model-training/hugging-face). For detailed instructions and examples, see the [Neptune docs](https://docs.neptune.ai/integrations/transformers/).
### ClearML ### ClearML
...@@ -373,4 +375,4 @@ Advanced configuration is possible by setting environment variables: ...@@ -373,4 +375,4 @@ Advanced configuration is possible by setting environment variables:
| CLEARML_PROJECT | Name of the project in ClearML. (default: `"HuggingFace Transformers"`) | | CLEARML_PROJECT | Name of the project in ClearML. (default: `"HuggingFace Transformers"`) |
| CLEARML_TASK | Name of the task in ClearML. (default: `"Trainer"`) | | CLEARML_TASK | Name of the task in ClearML. (default: `"Trainer"`) |
Additional configuration options are available through generic [clearml environment variables](https://clear.ml/docs/latest/docs/configs/env_vars). Additional configuration options are available through generic [clearml environment variables](https://clear.ml/docs/latest/docs/configs/env_vars).
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment