Skip to content

Commit

Permalink
fix merge2
Browse files Browse the repository at this point in the history
  • Loading branch information
mk01071 committed Nov 12, 2019
1 parent 7478952 commit 91a07da
Show file tree
Hide file tree
Showing 17 changed files with 12 additions and 6 deletions.
Binary file removed src/genetic_operator.pyc
Binary file not shown.
Binary file removed src/input_conf.pyc
Binary file not shown.
Binary file removed src/module_AF.pyc
Binary file not shown.
Binary file removed src/module_GA.pyc
Binary file not shown.
Binary file removed src/module_amp2_input.pyc
Binary file not shown.
Binary file removed src/module_band.pyc
Binary file not shown.
Binary file removed src/module_converge.pyc
Binary file not shown.
Binary file removed src/module_dielectric.pyc
Binary file not shown.
Binary file removed src/module_dos.pyc
Binary file not shown.
Binary file removed src/module_effm.pyc
Binary file not shown.
Binary file removed src/module_hse.pyc
Binary file not shown.
Binary file removed src/module_log.pyc
Binary file not shown.
Binary file removed src/module_relax.pyc
Binary file not shown.
Binary file removed src/module_vasprun.pyc
Binary file not shown.
Binary file removed src/module_vector.pyc
Binary file not shown.
18 changes: 12 additions & 6 deletions src/relax.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,12 +105,12 @@
energy = pygrep('free ','OUTCAR',0,0).splitlines()
#energy = subprocess.check_output(['grep','free ','OUTCAR']).splitlines()
while iteration < inp_rlx['max_iteration']:
with open(dir_relax+'/OUT_TOT','a') as out_log:
out_log.write(open(dir_relax+'/OUTCAR','r').read())
if len(energy) <= inp_rlx['converged_ionic_step']:
ionic_converge = 1
make_amp2_log(dir_relax,'Relaxation is done.')
break
# with open(dir_relax+'/OUT_TOT','a') as out_log:
# out_log.write(open(dir_relax+'/OUTCAR','r').read())
# if len(energy) <= inp_rlx['converged_ionic_step']:
# ionic_converge = 1
# make_amp2_log(dir_relax,'Relaxation is done.')
# break
shutil.copyfile(dir_relax+'/CONTCAR',dir_relax+'/POSCAR')
if bool(inp_rlx['incar']) and not 'EDIFFG' in inp_rlx['incar'].keys():
converge_condition = set_ediffg(dir_relax+'/POSCAR',inp_rlx['force'],inp_rlx['pressure'],inp_rlx['energy'])
Expand Down Expand Up @@ -140,6 +140,12 @@
# energy = subprocess.check_output(['grep','free ','OUTCAR']).splitlines()
iteration = iteration+1
make_amp2_log(dir_relax,'Iteration number is '+str(iteration))
with open(dir_relax+'/OUT_TOT','a') as out_log:
out_log.write(open(dir_relax+'/OUTCAR','r').read())
if len(energy) <= inp_rlx['converged_ionic_step']:
ionic_converge = 1
make_amp2_log(dir_relax,'Relaxation is done.')
break

if ionic_converge == 0 and len(energy) <= inp_rlx['converged_ionic_step']:
ionic_converge = 1
Expand Down
Binary file removed src/z_subr.pyc
Binary file not shown.

0 comments on commit 91a07da

Please sign in to comment.