diff --git a/cscs-checks/apps/vasp/vasp_check.py b/cscs-checks/apps/vasp/vasp_check.py index b29b0f7cd6..36047402ad 100644 --- a/cscs-checks/apps/vasp/vasp_check.py +++ b/cscs-checks/apps/vasp/vasp_check.py @@ -4,118 +4,140 @@ # SPDX-License-Identifier: BSD-3-Clause import reframe as rfm -import reframe.utility.sanity as sn +from hpctestlib.apps.vasp.base_check import VASP +dom_cpu = { + 'maint': (148.7, None, 0.05, 's'), + 'prod': (148.7, None, 0.05, 's'), +} -class VASPCheck(rfm.RunOnlyRegressionTest): - def __init__(self): +daint_cpu = { + 'maint': (105.3, None, 0.20, 's'), + 'prod': (105.3, None, 0.20, 's'), +} + +eiger_cpu = { + 'maint': (100.0, None, 0.10, 's'), + 'prod': (100.0, None, 0.10, 's'), +} + +pilatus_cpu = { + 'maint': (100.0, None, 0.10, 's'), + 'prod': (100.0, None, 0.10, 's'), +} + + +REFERENCE_CPU_PERFORMANCE = { + 'dom:gpu': dom_cpu, + 'daint:gpu': daint_cpu, + 'eiger:mc': eiger_cpu, + 'pilatus:mc': pilatus_cpu +} + + +dom_gpu = { + 'maint': (61.0, None, 0.10, 's'), + 'prod': (46.7, None, 0.20, 's'), +} + +daint_gpu = { + 'maint': (46.7, None, 0.20, 's'), + 'prod': (46.7, None, 0.20, 's'), +} + +REFERENCE_GPU_PERFORMANCE = { + 'dom:gpu': dom_gpu, + 'daint:gpu': daint_gpu, +} + +REFERENCE_PERFORMANCE = { + 'gpu': REFERENCE_GPU_PERFORMANCE, + 'cpu': REFERENCE_CPU_PERFORMANCE, +} + + +@rfm.simple_test +class VASPCheckCSCS(VASP): + mode = parameter(['prod', 'maint']) + modules = ['VASP'] + maintainers = ['LM'] + tags = {'scs'} + strict_check = False + extra_resources = { + 'switches': { + 'num_switches': 1 + } + } + + @run_after('init') + def env_define(self): if self.current_system.name in ['eiger', 'pilatus']: self.valid_prog_environs = ['cpeIntel'] else: self.valid_prog_environs = ['builtin'] - self.modules = ['VASP'] - force = sn.extractsingle(r'1 F=\s+(?P\S+)', - self.stdout, 'result', float) - self.sanity_patterns = sn.assert_reference( - force, -.85026214E+03, -1e-5, 1e-5 - ) - self.keep_files = ['OUTCAR'] - self.perf_patterns = { - 'time': sn.extractsingle(r'Total CPU time used \(sec\):' - r'\s+(?P