> For the complete documentation index, see [llms.txt](https://docs.dobb-e.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.dobb-e.com/software/readme-1/fine-tuning-policies.md).

# Fine-tuning Policies

## Training Policies

The following assumes that the current working directory is this repository’s root folder.

### Training a Behavior Cloning Policy

1. Modify `include_task` and `include_env` in `finetune.yaml` depending on the task and env you intend to finetune.
2. \[Optional, non-default:] only if you're using torch encoder, set `enc_weight_pth` (path to pretrained encoder weights) in `image_bc_depth.yaml`. You can download the weights from <https://dl.dobb-e.com/models/hpr_model.pt> if you don't have them.
3. Run in terminal:

   ```bash
   python train.py --config-name=finetune
   ```
4. \[Optional, experimental] If you want to take advantage of multi-GPU training using 🤗 accelerate, you can use the following command:<br>

   ```bash
   accelerate config # Only the first time, to configure accelerate
   accelerate launch train.py --config-name=finetune
   ```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.dobb-e.com/software/readme-1/fine-tuning-policies.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
