Remove unused stuff and clean up

parent 2f5245c2
Pipeline #20994828 passed with stage
in 4 minutes and 3 seconds
import os
def agts(queue):
if 0: # disabled - this test use a mixture of shell and python
# performs the "best performance" test from
# https://wiki.fysik.dtu.dk/gpaw/devel/benchmarks.html#memory-benchmark
#
# Set the environment variables for your system before running this script!
# Setting any variable in this script is ignored!
machine = os.environ.get('MACHINE', 'TEST')
ncores = int(os.environ.get('NCORES', 8))
#
prepare = queue.add('prepare.py',
queueopts='-l nodes=1:ppn=1',
ncpus=1, walltime=5, deps=[])
run_numactl = queue.add('run_numactl.py',
queueopts='-l nodes=1:ppn=8:xeon8',
ncpus=1, walltime=1*60, deps=[prepare])
analyse = queue.add('analyse.py',
queueopts='-l nodes=1:ppn=1',
ncpus=1, walltime=5, deps=[run_numactl],
creates=['memory_bandwidth_'+machine+'_py.png'],
show=['memory_bandwidth_'+machine+'_py.png'])
from myqueue.job import Job
from gpaw.utilities import compiled_with_libvdwxc
from gpaw.xc.libvdwxc import libvdwxc_has_pfft
def agts(queue):
# Is walltime minutes or seconds? If it crashes, we will know.
def workflow():
jobs = []
if compiled_with_libvdwxc():
queue.add('libvdwxc-example.py', ncpus=1, walltime=1)
jobs.apend(Job('libvdwxc-example.py'))
if libvdwxc_has_pfft():
queue.add('libvdwxc-pfft-example.py', ncpus=8, walltime=1)
jobs.append(Job('libvdwxc-pfft-example.py', cores=8))
return jobs
def agts(queue):
return
a = queue.add('dcdft_gpaw.py', ncpus=4, walltime=40)
queue.add('testdb.py', deps=a)
queue.add('extract.py dcdft.db', deps=a, creates='dcdft.db_raw.txt')
......@@ -3,37 +3,36 @@ from myqueue.job import Job
def workflow():
return [
Job('water/h2o.py'),
Job('wavefunctions/CO.py@8x15s'),
Job('aluminium/Al_fcc.py@2x15s'),
Job('aluminium/Al_bcc.py@2x15s'),
Job('aluminium/Al_fcc_vs_bcc.py@2x15s'),
Job('aluminium/Al_fcc_modified.py@2x15s'),
Job('diffusion/initial.py@2x15s'),
Job('diffusion/solution.py@2x15s'),
Job('diffusion/densitydiff.py', deps=['diffusion/solution.py']),
Job('wannier/si.py@8x15s'),
Job('wannier/wannier-si.py', deps=['wannier/si.py']),
Job('wannier/benzene.py@8x15s'),
Job('wannier/wannier-benzene.py', deps=['wannier/benzene.py']),
Job('band_structure/ag.py'),
Job('vibrations/h2o.py@8x15s'),
Job('vibrations/H2O_vib.py@8x15s', deps=['vibrations/h2o.py']),
Job('vibrations/H2O_vib_2.py@4x15s', deps=['vibrations/H2O_vib.py']),
Job('iron/ferro.py@4x15s'),
Job('iron/anti.py@4x15s'),
Job('iron/non.py@2x15s'),
Job('iron/PBE.py',
deps=['iron/ferro.py', 'iron/anti.py', 'iron/non.py']),
Job('eels/test.py', deps=['band_structure/ag.py']),
Job('gw/test.py'),
Job('rpa/si.pbe.py'),
Job('rpa/si.pbe+exx.py@4x15s', deps=['rpa/si.pbe.py']),
Job('rpa/si.rpa_init_pbe.py'),
Job('rpa/si.rpa.py@4x15s', deps=['rpa/si.rpa_init_pbe.py']),
Job('stress/con_pw.py'),
Job('stress/stress.py'),
Job('transport/pt_h2_tb_transport.py'),
Job('transport/pt_h2_lcao_manual.py'),
Job('transport/pt_h2_lcao_transport.py',
deps=['transport/pt_h2_lcao_manual.py'])]
Job('h2o.py', folder='water'),
Job('CO.py@8x15s', folder='wavefunctions'),
Job('Al_fcc.py@2x15s', folder='aluminium'),
Job('Al_bcc.py@2x15s', folder='aluminium'),
Job('Al_fcc_vs_bcc.py@2x15s', folder='aluminium'),
Job('Al_fcc_modified.py@2x15s', folder='aluminium'),
Job('initial.py@2x15s', folder='diffusion'),
Job('solution.py@2x15s', folder='diffusion'),
Job('densitydiff.py', folder='diffusion', deps=['solution.py']),
Job('si.py@8x15s', folder='wannier'),
Job('wannier-si.py', folder='wannier', deps=['si.py']),
Job('benzene.py@8x15s', folder='wannier'),
Job('wannier-benzene.py', folder='wannier', deps=['benzene.py']),
Job('ag.py', folder='band_structure'),
Job('h2o.py@8x15s', folder='vibrations'),
Job('H2O_vib.py@8x15s', folder='vibrations', deps=['h2o.py']),
Job('H2O_vib_2.py@4x15s', folder='vibrations', deps=['H2O_vib.py']),
Job('ferro.py@4x15s', folder='iron'),
Job('anti.py@4x15s', folder='iron'),
Job('non.py@2x15s', folder='iron'),
Job('PBE.py', folder='iron', deps=['ferro.py', 'anti.py', 'non.py']),
Job('test.py', folder='eels', deps=['../band_structure/ag.py']),
Job('test.py', folder='gw'),
Job('si.pbe.py', folder='rpa'),
Job('si_pbe_exx.py@4x15s', folder='rpa', deps=['si.pbe.py']),
Job('si.rpa_init_pbe.py', folder='rpa'),
Job('si.rpa.py@4x15s', folder='rpa', deps=['si.rpa_init_pbe.py']),
Job('con_pw.py', folder='stress'),
Job('stress.py', folder='stress'),
Job('/pt_h2_tb_transport.py', folder='transport'),
Job('pt_h2_lcao_manual.py', folder='transport'),
Job('pt_h2_lcao_transport.py', folder='transport',
deps=['pt_h2_lcao_manual.py'])]
def agts(queue):
def workflow():
# Most of these time out at the moment ...
return
return []
gs_H_lda = queue.add('H.ralda_01_lda.py', ncpus=2, walltime=5)
queue.add('H.ralda_02_rpa_at_lda.py', deps=gs_H_lda, ncpus=16, walltime=20)
......
def agts(queue):
return
def workflow():
return []
si_gs = queue.add('si.groundstate.py', ncpus=1, walltime=2)
si_rRPA = queue.add('si.range_rpa.py', deps=si_gs, ncpus=8, walltime=30)
......
......@@ -4,10 +4,10 @@ from myqueue.job import Job
def workflow():
return [
Job('ruslab.py@8x10m'),
Job('ruslab.py H@8x10m'),
Job('ruslab.py N@8x10m'),
Job('ruslab.py O@16x15m'),
Job('ruslab.py+H@8x10m'),
Job('ruslab.py+N@8x10m'),
Job('ruslab.py+O@16x15m'),
Job('molecules.py@8x20s'),
Job('results.py',
deps=['ruslab.py', 'ruslab.py H', 'ruslab.py N', 'ruslab.py O',
deps=['ruslab.py', 'ruslab.py+H', 'ruslab.py+N', 'ruslab.py+O',
'molecules.py'])]
This diff is collapsed.
# Note: due to how agts works external executables (abinit, aims, etc.)
# must be run on the submission platform (bmaster1), currently opteron4
def agts(queue):
return
queue.add('pbe_abinit_hgh.py Al', ncpus=1,
queueopts='-l nodes=1:ppn=4:opteron4', walltime=10*60)
# Note: due to how agts works external executables (abinit, aims, etc.)
# must be run on the submission platform (bmaster1), currently opteron4
def agts(queue):
return
queue.add('pbe_abinit_paw.py Au', ncpus=1,
queueopts='-l nodes=1:ppn=4:opteron4', walltime=10*60)
# Note: due to how agts works external executables (abinit, aims, etc.)
# must be run on the submission platform (bmaster1), currently opteron4
def agts(queue):
return
queue.add('pbe_aims.py Al', ncpus=1,
queueopts='-l nodes=1:ppn=4:opteron4', walltime=3*40)
def agts(queue):
return
run = queue.add('pbe_gpaw_pw.py Al', ncpus=4,
queueopts='-l nodes=1:ppn=4:opteron4', walltime=60)
if 0: # run when new setups ready
analyse = queue.add('analyse.py dcdft_pbe_gpaw_pw',
ncpus=1, walltime=10, deps=run,
creates=['dcdft_pbe_gpaw_pw.csv',
'dcdft_pbe_gpaw_pw.txt',
'dcdft_pbe_gpaw_pw_Delta.txt',
'dcdft_pbe_gpaw_pw_raw.csv'])
verify = queue.add('pbe_gpaw_pw_verify.py',
ncpus=1, walltime=10, deps=[analyse])
def agts(queue):
return
run = [queue.add('pbe_jacapo.py %s' % r,
queueopts='-l nodes=1:ppn=4:opteron4',
ncpus=1,
walltime=10*60)
for r in range(0)]
if 0: # do not perform analysis
# we keep once generated files static
analyse = queue.add('analyse.py dcdft_pbe_jacapo',
ncpus=1, walltime=10, deps=run,
creates=['dcdft_pbe_jacapo.csv',
'dcdft_pbe_jacapo.txt',
'dcdft_pbe_jacapo_Delta.txt',
'dcdft_pbe_jacapo_raw.csv'])
import os
import subprocess
from gpaw.test.big.agts import Cluster
class GbarCluster(Cluster):
def submit(self, job):
dir = os.getcwd()
os.chdir(job.dir)
jobdir = os.getcwd()
self.write_pylab_wrapper(job)
# gpaw_platform = os.environ['FYS_PLATFORM'].replace('-el6', '-2.6')
ppn = '%d' % job.ncpus
nodes = 1
queueopts = '-l nodes=%d:ppn=%s' % (nodes, ppn)
p = subprocess.Popen(
['qsub',
queueopts,
'-l',
'walltime=%d:%02d:00' %
(job.walltime // 3600, job.walltime % 3600 // 60),
'-N',
job.name,
'-q',
'hpc'],
stdin=subprocess.PIPE, stdout=subprocess.PIPE)
out, err = p.communicate(
'cd %s\n' % jobdir +
'touch %s.start\n' % job.name +
'mpirun gpaw-python %s.py %s > %s.output\n' %
(job.script, job.args, job.name) +
'echo $? > %s.done\n' % job.name)
assert p.returncode == 0
id = out.split('.')[0]
job.pbsid = id
os.chdir(dir)
import os
import subprocess
from gpaw.test.big.agts import Cluster
class NiflheimCluster(Cluster):
def __init__(self, asepath='', setuppath='$GPAW_SETUP_PATH'):
self.asepath = asepath
self.setuppath = setuppath
def submit(self, job):
dir = os.getcwd()
os.chdir(job.dir)
self.write_pylab_wrapper(job)
if job.ncpus % 24 == 0:
partition = 'xeon24'
size = 24
else:
partition = 'xeon8'
size = 8
cmd = ['sbatch',
'--partition={}'.format(partition),
'--job-name={}'.format(job.name),
'--time={}'.format(job.walltime // 60),
'--ntasks={}'.format(job.ncpus)]
if job.ncpus % size == 0:
cmd.append('--nodes={}'.format(job.ncpus // size))
mpi_cmd = 'mpirun '
if partition == 'xeon24':
mpi_cmd += '-mca pml cm -mca mtl psm2 -x OMP_NUM_THREADS=1 '
script = [
'#!/bin/bash -l',
'touch {}.start'.format(job.name),
mpi_cmd + 'gpaw-python {}.py {} > {}.output'
.format(job.script, job.args, job.name),
'echo $? > {}.done'.format(job.name)]
if 1:
p = subprocess.Popen(cmd, stdin=subprocess.PIPE)
p.communicate(('\n'.join(script) + '\n').encode())
assert p.returncode == 0
os.chdir(dir)
def agts(queue):
pass
#queue.add('n2.py', ncpus=4)
......@@ -2,6 +2,4 @@ from myqueue.job import Job
def workflow():
return [
Job('b256H2O.py A@4x5m'),
Job('b256H2O.py B@4x5m')]
return [Job('b256H2O.py@8x5m')]
# the problem described below was fixed in 9758!
# keep_htpsit=False fails since 9473,
# on some installations (?) with:
# case A (see below in the code):
# RuntimeError: Could not locate the Fermi level!
# or the energies from the 2nd one behave strange, no convergence:
# iter: 1 18:21:49 +1.7 -3608.512512 0 19
# iter: 2 18:22:31 +1.9 -3148.936317 0
# iter: 3 18:23:13 +2.1 -2375.137532 0
# iter: 4 18:23:58 +2.4 -0.9 -1040.851545 216 11
# iter: 5 18:24:43 +2.6 -1.0 822.569589 597 14
# case B (see below in the code):
# No convergence when starting from a converged (keep_htpsit=True) run!
# WFS error grows to positive values!
# Is it an extreme case of https://trac.fysik.dtu.dk/projects/gpaw/ticket/51 ?
import sys
from ase import Atoms
from gpaw import GPAW, RMMDIIS, setup_paths
if len(sys.argv) == 1:
run = 'A'
else:
run = sys.argv[1]
assert run in ['A', 'B']
# Use setups from the $PWD and $PWD/.. first
setup_paths.insert(0, '.')
setup_paths.insert(0, '../')
from gpaw import GPAW, RMMDIIS
positions = [
(-0.069, 0.824, -1.295), (0.786, 0.943, -0.752), (-0.414, -0.001, -0.865),
......@@ -71,7 +36,6 @@ positions = [
(5.281, 6.089, 6.035), (5.131, 7.033, 6.378), (4.428, 5.704, 5.720),
(5.067, 7.323, 0.662), (5.785, 6.667, 0.703), (4.718, 7.252, 1.585)]
prefix = 'b256H2O'
L = 9.8553729
atoms = Atoms('32(OH2)',
positions=positions)
......@@ -94,19 +58,6 @@ calc = GPAW(nbands=nbands,
# maxiter=5,
width=0.01,
eigensolver=es,
txt=prefix + '.txt')
if run == 'A':
atoms.set_calculator(calc)
pot = atoms.get_potential_energy()
elif run == 'B':
# converge first with keep_htpsit=True
calc.set(eigensolver='rmm-diis')
calc.set(txt=prefix + '_True.txt')
atoms.set_calculator(calc)
pot = atoms.get_potential_energy()
# fails to converge with keep_htpsit=False
calc.set(eigensolver=es)
calc.set(maxiter=200)
calc.set(txt=prefix + '_False.txt')
atoms.set_calculator(calc)
pot = atoms.get_potential_energy()
txt='water.txt')
atoms.set_calculator(calc)
pot = atoms.get_potential_energy()
runs = [
# 'bands00m', # the default number of bands is bad
# #'m051', # slower mixing does not help
# #'m103poisson', # no influence
# 'm103', 'm105', 'm107', # for Mixer nmaxold matters: large is bad
# 'b103', 'd103', 's103',
# #'d105', 'd107', 'd203', # for MixerDif nmaxold does not matter
# 'inititer10m', # cg steps and switching to rmm-diis does not help
# 'cgm103', 'cgm203', # cg helps
# #'cgs103', # cg + MixerSum
# 'cgd103', 'cgd203', 'cgd253', # cg + MixerDif: the winner
# 'dzpm103', # lcao guess does not help
# #'cgdzpm103', # lcao + cg
# #'cgdzps103', # lcao + cg + MixerSum
# #'cgdzpd103', # lcao + cg + MixerDif
# 'fm103', # FFT
'davd203', # PW mode winner
'davfd203'] # FFT
runsstr = ','.join(runs)
runsstr += ',jacapo'
def agts(queue):
return
run = [queue.add('dcdft_pbe_pw.py %s' % r,
ncpus=1,
walltime=30 * 60)
for r in runs * 8]
jacapo = queue.add('dcdft_pbe_pw_jacapo.py',
ncpus=1,
walltime=10 * 60)
if 0: # we don't run all the runs for the moment
queue.add('analyse.py bulk scf_dcdft_pbe_pw ' + runsstr,
ncpus=1, walltime=10, deps=run + [jacapo],
creates=['scf_dcdft_pbe_pw_energy.csv',
'scf_dcdft_pbe_pw_calculator_steps.png'])
runs = [
#'bands05m', 'bands10m', # 'bands20m', # large number of bands bad
#'m101',
#'m102',
#'m103', 'm105', # 'm107', # for Mixer nmaxold matters
#'m051', # many steps, and no advantage for this set of systems
#'m203', # larger mixing better
's103',
'd103', 'd203', 'd253', # MixerDiff best
'dzpm103', 'dzpm203'] # 'dzpm253', # dzp guess does not help
runsstr = ','.join(runs)
def agts(queue):
return
run = [queue.add('g2_1_pbe0_fd.py %s' % r,
ncpus=4,
walltime=40 * 60)
for r in runs * 2]
queue.add('analyse.py molecule scf_g2_1_pbe0_fd ' + runsstr,
ncpus=1, walltime=10, deps=run,
creates=['scf_g2_1_pbe0_fd_energy.csv',
'scf_g2_1_pbe0_fd_calculator_steps.png'])
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment