Skip to content

Commit be120f1

Browse files
authored
refactor: output the latest structure to STRU_NOW.cif in relax/cell-relax (#6587)
Co-authored-by: root <pxlxingliang>
1 parent 4ad2b02 commit be120f1

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

source/module_relax/relax_driver.cpp

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,11 @@ void Relax_Driver::relax_driver(ModuleESolver::ESolver* p_esolver, UnitCell& uce
108108
need_orb,
109109
PARAM.globalv.deepks_setorb,
110110
GlobalV::MY_RANK);
111+
112+
ModuleIO::CifParser::write(PARAM.globalv.global_out_dir + "STRU_NOW.cif",
113+
ucell,
114+
"# Generated by ABACUS ModuleIO::CifParser",
115+
"data_?");
111116

112117
if (Ions_Move_Basic::out_stru)
113118
{
@@ -121,10 +126,6 @@ void Relax_Driver::relax_driver(ModuleESolver::ESolver* p_esolver, UnitCell& uce
121126
need_orb,
122127
PARAM.globalv.deepks_setorb,
123128
GlobalV::MY_RANK);
124-
ModuleIO::CifParser::write(PARAM.globalv.global_out_dir + "STRU_NOW.cif",
125-
ucell,
126-
"# Generated by ABACUS ModuleIO::CifParser",
127-
"data_?");
128129
}
129130

130131
ModuleIO::output_after_relax(stop, p_esolver->conv_esolver, GlobalV::ofs_running);

0 commit comments

Comments
 (0)