Skip to content

Commit

Permalink
SOF-7298: add pw_nscf_soc template
Browse files Browse the repository at this point in the history
  • Loading branch information
pranabdas committed Apr 23, 2024
1 parent 533b626 commit e312e14
Show file tree
Hide file tree
Showing 5 changed files with 96 additions and 2 deletions.
73 changes: 73 additions & 0 deletions assets/espresso/pw_nscf_soc.j2.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
&CONTROL
calculation = 'nscf'
title = ''
verbosity = 'low'
restart_mode = '{{input.RESTART_MODE}}'
wf_collect = .true.
tstress = .true.
tprnfor = .true.
outdir = {% raw %}'{{ JOB_WORK_DIR }}/outdir'{% endraw %}
wfcdir = {% raw %}'{{ JOB_WORK_DIR }}/outdir'{% endraw %}
prefix = '__prefix__'
pseudo_dir = {% raw %}'{{ JOB_WORK_DIR }}/pseudo'{% endraw %}
/
&SYSTEM
ibrav = {{ input.IBRAV }}
nat = {{ input.NAT }}
ntyp = {{ input.NTYP_WITH_LABELS }}
ecutwfc = {{ cutoffs.wavefunction }}
ecutrho = {{ cutoffs.density }}
occupations = 'smearing'
degauss = 0.005
noncolin = .true.
lspinorb = .true.
{%- if nonCollinearMagnetization.isStartingMagnetization %}
{%- for item in nonCollinearMagnetization.startingMagnetization %}
starting_magnetization({{ item.index }}) = {{ item.value }} {% endfor -%}
{%- endif %}
{%- if nonCollinearMagnetization.isConstrainedMagnetization %}
constrained_magnetization = '{{ nonCollinearMagnetization.constrainedMagnetization.constrainType }}'
lambda = {{ nonCollinearMagnetization.constrainedMagnetization.lambda }}
{%- endif %}
{%- if nonCollinearMagnetization.isConstrainedMagnetization and nonCollinearMagnetization.isFixedMagnetization %}
fixed_magnetization(1) = {{ nonCollinearMagnetization.fixedMagnetization.x }}
fixed_magnetization(2) = {{ nonCollinearMagnetization.fixedMagnetization.y }}
fixed_magnetization(3) = {{ nonCollinearMagnetization.fixedMagnetization.z }}
{%- endif %}
{%- if nonCollinearMagnetization.isExistingChargeDensity and nonCollinearMagnetization.lforcet %}
lforcet = .true.
{%- endif %}
{%- if nonCollinearMagnetization.isExistingChargeDensity and !nonCollinearMagnetization.lforcet %}
lforcet = .false.
{%- endif %}
{%- if nonCollinearMagnetization.isArbitrarySpinDirection %}
{%- for item in nonCollinearMagnetization.spinAngles %}
angle1({{ item.index }}) = {{ item.angle1 }}
angle2({{ item.index }}) = {{ item.angle2 }} {% endfor %}
{%- endif %}
{%- if subworkflowContext.NO_SYMMETRY_NO_INVERSION %}
nosym = .true.
noinv = .true.
{%- endif %}
/
&ELECTRONS
diagonalization = 'david'
diago_david_ndim = 4
diago_full_acc = .true.
mixing_beta = 0.3
{%- if nonCollinearMagnetization.isExistingChargeDensity %}
startingpot = 'file'
{%- endif %}
/
&IONS
/
&CELL
/
ATOMIC_SPECIES
{{ input.ATOMIC_SPECIES_WITH_LABELS }}
ATOMIC_POSITIONS crystal
{{ input.ATOMIC_POSITIONS }}
CELL_PARAMETERS angstrom
{{ input.CELL_PARAMETERS }}
K_POINTS automatic
{% for d in kgrid.dimensions %}{{d}} {% endfor %}{% for s in kgrid.shifts %}{{s}} {% endfor %}
11 changes: 11 additions & 0 deletions executables/espresso/pw.x.yml
Original file line number Diff line number Diff line change
Expand Up @@ -370,6 +370,17 @@ flavors:
applicationName: espresso
executableName: pw.x

pw_nscf_soc:
input:
- name: pw_nscf_soc.in
results:
- fermi_energy
- band_gaps
monitors:
- standard_output
applicationName: espresso
executableName: pw.x

pw_nscf_dft_u_magn:
input:
- name: pw_nscf_dft_u_magn.in
Expand Down
2 changes: 1 addition & 1 deletion src/js/data/templates.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/js/data/tree.js

Large diffs are not rendered by default.

10 changes: 10 additions & 0 deletions templates/espresso/pw.x.yml
Original file line number Diff line number Diff line change
Expand Up @@ -306,6 +306,16 @@
applicationName: espresso
executableName: pw.x

- content: !readFile 'assets/espresso/pw_nscf_soc.j2.in'
name: pw_nscf_soc.in
contextProviders:
- name: KGridFormDataManager
- name: QEPWXInputDataManager
- name: PlanewaveCutoffDataManager
- name: NonCollinearMagnetizationDataManager
applicationName: espresso
executableName: pw.x

- content: !readFile 'assets/espresso/pw_bands_magn.j2.in'
name: pw_bands_magn.in
contextProviders:
Expand Down

0 comments on commit e312e14

Please sign in to comment.