> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.nvidia.com/clara/parabricks/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.nvidia.com/clara/parabricks/_mcp/server.

# applybqsr

Updates the Base Quality Scores using the BQSR report.

This tool recalibrates quality scores in a BAM file using the report generated
by the bqsr \[link] tool. This should be applied after alignment but before
variant calling to maximize final accuracy in variant calling, as recommended
by GATK best practices.

Note that the **applybqsr** tool will use at most two GPUs.

Refer to the [applybqsr Reference](#options) section for a detailed listing of all available options.

## Quick Start

```sh
# This command assumes all the inputs are in the current working directory and all the outputs go to the same place.
docker run --rm --gpus all --volume $(pwd):/workdir --volume $(pwd):/outputdir \
    --workdir /workdir \
    nvcr.io/nvidia/clara/clara-parabricks:4.7.1-1 \
    pbrun applybqsr \
    --ref /workdir/${REFERENCE_FILE} \
    --in-bam /workdir/${INPUT_BAM} \
    --in-recal-file /workdir/${INPUT_RECAL_FILE}  \
    --out-bam /outputdir/${OUTPUT_BAM}
```

## Compatible GATK4 Command

The command below is the GATK4 counterpart of the Parabricks command above. The output
from these commands will be identical to the output from the above command.

```sh
$ gatk ApplyBQSR \
    --java-options -Xmx30g \
    -R <INPUT_DIR>/${REFERENCE_FILE} \
    -I <INPUT_DIR>/${INPUT_BAM} \
    --bqsr-recal-file <INPUT_DIR>/${INPUT_RECAL_FILE} \
    -O <OUTPUT_DIR>/${OUTPUT_BAM}
```

## Options