> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cudocompute.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Parabricks

> Learn how to use Parabricks with CUDO Compute.

## Prerequisites

* Create a project and [add an SSH key](/docs/tutorials/how-to-generate-ssh-keys)
* Optionally download [CLI tool](/cli-tool)
* Choose a virtual machine with an NVIDIA GPU and Configure
* Use the **Ubuntu 22.04 + NVIDIA drivers + Docker** image (in CLI tool type `-image ubuntu-nvidia-docker`)

## Running Parabricks with Docker

```shell theme={null}
docker pull nvcr.io/nvidia/clara/clara-parabricks:4.0.0-1
```

NGC tags can be found [here](https://catalog.ngc.nvidia.com/orgs/nvidia/teams/clara/containers/clara-parabricks/tags)
More tutorials \[here] ([https://docs.nvidia.com/clara/parabricks/4.0.0/Tutorials.html](https://docs.nvidia.com/clara/parabricks/4.0.0/Tutorials.html))

## Sample walkthrough

Download the sample data

```shell theme={null}
wget -O parabricks_sample.tar.gz \
"https://s3.amazonaws.com/parabricks.sample/parabricks_sample.tar.gz"
```

Extract the data

```shell theme={null}
tar xvf parabricks_sample.tar.gz
```

```shell theme={null}
docker run \
      --gpus all \
      --rm \
      --volume $(pwd):/workdir \
      --volume $(pwd):/outputdir \
    nvcr.io/nvidia/clara/clara-parabricks:4.0.0-1 \
    pbrun fq2bam \
      --ref /workdir/parabricks_sample/Ref/Homo_sapiens_assembly38.fasta \
      --in-fq /workdir/parabricks_sample/Data/sample_1.fq.gz /workdir/parabricks_sample/Data/sample_2.fq.gz \
      --out-bam /outputdir/fq2bam_output.bam
```

```
[Parabricks Options Mesg]: Checking argument compatibility
[Parabricks Options Mesg]: Automatically generating ID prefix
[Parabricks Options Mesg]: Read group created for /workdir/parabricks_sample/Data/sample_1.fq.gz and
/workdir/parabricks_sample/Data/sample_2.fq.gz
[Parabricks Options Mesg]: @RG\tID:HK3TJBCX2.1\tLB:lib1\tPL:bar\tSM:sample\tPU:HK3TJBCX2.1
[PB Info 2022-Oct-14 09:54:15] ------------------------------------------------------------------------------
[PB Info 2022-Oct-14 09:54:15] ||                 Parabricks accelerated Genomics Pipeline                 ||
...
```

On a 4x NVIDIA A4000 virtual machine this process takes around 1m 30s

To view the results run:

```shell theme={null}
apt install samtools
samtools view fq2bam_output.bam
```

```
HWI-D00127:570:HK3TJBCX2:2:2215:1035:92366 77 * 0 0 * * 0 0 NAAAGACGGAGAGCGCCAACGGCGTCCATCTCGAAGGAGTCGCCAGCGATAACCGGAGTAGTTGAAATGGTAATAAGACGACCAATCTGACCAGCAAGGAAGCCAAGATGGGAAA #<<DDHHGHHIIIIHHIIIIIIIIEHHIHHDFHIIIIIIDDEHIIIIIIIIIIHIIIIGGHD@GHHIHHIIIIIIIIIIHHHHIIHHHGHIIIHHIIIHIIHIIIIIIGIIHIII PG:Z:MarkDuplicates RG:Z:HK3TJBCX2.1 AS:i:0 XS:i:0
HWI-D00127:570:HK3TJBCX2:2:2215:21076:38154 141 * 0 0 * * 0 0 NNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNN ################################################################################################################### PG:Z:MarkDuplicates RG:Z:HK3TJBCX2.1 AS:i:0 XS:i:0
```

For more help on Parabricks see the [NVIDIA docs](https://docs.nvidia.com/clara/parabricks/4.0.0/GettingStarted.html#from-the-command-line)
