# Setup Horovod and OpenMPI in Q Blocks Instance

Horovod is a free and open-source software framework for distributed deep learning training using TensorFlow, Keras, PyTorch, and Apache MXNet.

Horovod is hosted under the Linux Foundation AI.

Setting up Horovod in your Q Blocks instance is as simple as running a single bash command.

We have prepared a quick and easy to use bash script that installs and configures Horovod along with openMPI in your instance.

Horovod uses openMPI for message passing during the distributed training process.

{% hint style="info" %}
Installation and setup will take anywhere between 5-10 minutes.
{% endhint %}

#### Follow the steps below for successful installation:

1. Go to your Q Blocks instance and open the bash terminal in it.
2. Run the following command:

```bash
wget https://www.qblocks.cloud/resources/setup-horovod.sh --no-check-certificate -O - | sh
```

#### The above command would perform the following tasks:

* Install any missing dependencies to build OpenMPI
* Install OpenMPI
* Install Horovod with support NCCL, Tensorflow and PyTorch

#### Installation can be verified by running the command:

```bash
horovodrun --help
```

If you face issues with the installation then reach out to us at <support@qblocks.cloud>.


---

# Agent Instructions: 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:

```
GET https://docs.qblocks.cloud/q-blocks-how-to-guide/setup-horovod-and-openmpi-in-q-blocks-instance.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
