> For the complete documentation index, see [llms.txt](https://materialsproject.gitbook.io/persson-group-handbook/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://materialsproject.gitbook.io/persson-group-handbook/computing/atomate-setup.md).

# Fireworks & Atomate

Please see the following subsections on fireworks/atomate setup and usage:

{% tabs %}
{% tab title="NERSC-cori" %}

```yaml
name: NERSC_fworker
category: ''
query: '{}'
env:
    db_file: /global/homes/FIRST_LETTER/YOUR_USERNAME/fw_config/db.json
    vasp_cmd: 'srun -n 64 -c 4 --cpu_bind=cores vasp_std'
    gamma_vasp_cmd: 'srun -n 64 -c 4 --cpu_bind=cores vasp_gam'
    scratch_dir: /global/cscratch1/sd/YOUR_USERNAME
    incar_update:
```

{% endtab %}

{% tab title="Savio" %}

```yaml
name: savio_fworker
category: ''
query: '{}'
env:
    db_file: /global/home/users/YOUR_USERNAME/fw_config/db.json
    vasp_cmd: 'mpirun --bind-to core vasp_std'
    gamma_vasp_cmd: 'mpirun --bind-to core vasp_gam'
    scratch_dir: /global/scratch/YOUR_USERNAME/
    incar_update:
```

{% endtab %}

{% tab title="Lawrencium" %}

```yaml
name: lrc_fworker
category: ''
query: '{}'
env:
    db_file: /global/home/users/YOUR_USERNAME/fw_config/db.json
    vasp_cmd: 'mpirun --bind-to core vasp_std'
    gamma_vasp_cmd: 'mpirun --bind-to core vasp_gam'
    scratch_dir: /global/scratch/users/YOUR_USERNAME/
    incar_update:
```

{% endtab %}

{% tab title="NERSC-perlmutter-gpu" %}

```yaml
name: gpu_fworker
category: ''
query: '{}'
env:
    db_file: /global/homes/FIRST_LETTER/YOUR_USERNAME/fw_config/db.json
    vasp_cmd: 'srun -n 4 -c 16 --gpu-bind=single:1 vasp_std'
    gamma_vasp_cmd: 'srun -n 4 -c 16 --gpu-bind=single:1 vasp_gam'
    scratch_dir: /pscratch/sd/FIRST_LETTER/YOUR_USERNAME
    incar_update:
```

{% endtab %}
{% endtabs %}

{% tabs %}
{% tab title="NERSC-cori" %}

```yaml
_fw_name: CommonAdapter
_fw_q_type: SLURM
rocket_launch: rlaunch -w /global/homes/FIRST_LETTER/YOUR_USERNAME/fw_config/my_fworker.yaml singleshot
nodes: 1
walltime: '24:00:00'
account: matgen
job_name: knl_launcher
signal: SIGINT@60
qos: regular
constraint: 'knl'
pre_rocket: |
            source activate cms
            module load vasp-tpc/5.4.4-knl
            export OMP_PROC_BIND=true
            export OMP_PLACES=threads
            export OMP_NUM_THREADS=1
```

{% endtab %}

{% tab title="Savio" %}

```yaml
_fw_name: CommonAdapter
_fw_q_type: SLURM
rocket_launch: rlaunch -w /global/home/users/YOUR_USERNAME/fw_config/my_fworker.yaml singleshot
nodes: 1
walltime: '24:00:00'
account: co_lsdi
job_name: knl_launcher
queue: savio2_knl
qos: lsdi_knl2_normal
ntasks: 64
pre_rocket: |
            source activate cms
            module load vasp
            export OMP_PROC_BIND=true
            export OMP_PLACES=threads
            export OMP_NUM_THREADS=1
            post_rocket: null
```

{% endtab %}

{% tab title="Lawrencium" %}

<pre class="language-yaml"><code class="lang-yaml"><strong>_fw_name: CommonAdapter
</strong>_fw_q_type: SLURM
rocket_launch: rlaunch -w /global/home/users/YOUR_USERNAME/fw_config/my_fworker.yaml singleshot
nodes: 1
ntasks: 64
queue: cf1
walltime: '06:00:00'
account: lr_mp
job_name: lrc_cpu_launcher
signal: SIGINT@60
qos: condo_mp_cf1
pre_rocket: |
            source activate cms
            module load vasp/6.prerelease
            export OMP_PROC_BIND=true
            export OMP_PLACES=threads
            export OMP_NUM_THREADS=1
</code></pre>

{% endtab %}

{% tab title="NERSC-perlmutter-gpu" %}

```yaml
_fw_name: CommonAdapter
_fw_q_type: SLURM
rocket_launch: rlaunch -w /global/homes/FIRST_LETTER/YOUR_USERNAME/fw_config/perlmutter/my_fworker.yaml singleshot
nodes: 1
walltime: '06:00:00'
account: matgen_g
job_name: gpu_launcher
signal: SIGINT@60
qos: regular
constraint: 'gpu'
pre_rocket: |
            source activate cms
            module load vasp/6.2.1-gpu
            export SLURM_CPU_BIND="cores"
            unset MPICH_GPU_SUPPORT_ENABLED
```

{% endtab %}
{% endtabs %}

{% tabs %}
{% tab title="NERSC" %}

```bash
case $NERSC_HOST in
    "cori")
        : # settings for Cori
        module load python/3.9-anaconda-2021.11
	export PMG_VASP_PSP_DIR='/project/projectdirs/matgen/POTCARs'
	export FW_CONFIG_FILE='/global/homes/FIRST_LETTER/YOUR_USERNAME/fw_config/FW_config.yaml'
	alias cdconfig='cd ~/fw_config'
        ;;
    "perlmutter")
        : # settings for Perlmutter
        module load python
	export PMG_VASP_PSP_DIR='/global/cfs/cdirs/matgen/POTCARs'
	export FW_CONFIG_FILE='/global/homes/FIRST_LETTER/YOUR_USERNAME/fw_config/perlmutter/FW_config.yaml'
        alias cdconfig='cd ~/fw_config'
        ;;
  esac
```

{% endtab %}

{% tab title="Savio" %}

```bash
module load python/3.8
export PMG_VASP_PSP_DIR=/clusterfs/mp/software/POTCARs
export FW_CONFIG_FILE='/global/home/users/YOUR_USERNAME/fw_config/FW_config.yaml'
alias cdconfig='cd ~/fw_config'
```

{% endtab %}

{% tab title="Lawrenicum" %}

```bash
module load python/3.9.12
export PMG_VASP_PSP_DIR=/clusterfs/mp/software/POTCARs
export FW_CONFIG_FILE='/global/home/users/YOUR_USERNAME/fw_config/FW_config.yaml'
alias cdconfig='cd ~/fw_config'
```

{% endtab %}

{% tab title="Local" %}

```
export FW_CONFIG_FILE='/HOME_DIRECTORY_PATH/fw_config/FW_config.yaml'
alias cdconfig='cd ~/fw_config'
```

{% endtab %}
{% endtabs %}

{% content-ref url="/pages/dL84MlD7hrVQDOnaCeHg" %}
[Setup](/persson-group-handbook/computing/atomate-setup/setup.md)
{% endcontent-ref %}

{% content-ref url="/pages/8W193jvufzkjEXRBUCSG" %}
[Fireworks: Advanced Usage](/persson-group-handbook/computing/atomate-setup/atomate-setup.md)
{% endcontent-ref %}
