From 36a7ed84194cdcec75393895b2901b40e3acfdc4 Mon Sep 17 00:00:00 2001 From: Theofilos Manitaras Date: Fri, 17 May 2019 15:02:55 +0200 Subject: [PATCH 1/4] Print required number of nodes in detailed listing --- reframe/frontend/cli.py | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/reframe/frontend/cli.py b/reframe/frontend/cli.py index 087883a0c0..3589f88088 100644 --- a/reframe/frontend/cli.py +++ b/reframe/frontend/cli.py @@ -32,7 +32,18 @@ def format_check(check, detailed): ' - description: %s' % check.descr, ' - systems: %s' % ', '.join(check.valid_systems), ' - environments: %s' % ', '.join(check.valid_prog_environs), - ' - modules: %s' % ', '.join(check.modules), + ' - modules: %s' % ', '.join(check.modules) + ] + + if check.num_tasks <= 0: + num_tasks_per_node = check.num_tasks_per_node or 1 + min_num_tasks = (-check.num_tasks if check.num_tasks else + num_tasks_per_node) + num_nodes_required = min_num_tasks // num_tasks_per_node + lines.append( + ' - required nodes: %s' % num_nodes_required) + + lines += [ ' - tags: %s' % ', '.join(check.tags), ' - maintainers: %s' % ', '.join(check.maintainers) ] From 725a7abb9664670920778ddf0fe648300dbc5194 Mon Sep 17 00:00:00 2001 From: Theofilos Manitaras Date: Mon, 20 May 2019 09:16:53 +0200 Subject: [PATCH 2/4] Address PR comments --- reframe/frontend/cli.py | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) diff --git a/reframe/frontend/cli.py b/reframe/frontend/cli.py index 3589f88088..4ccbcda51d 100644 --- a/reframe/frontend/cli.py +++ b/reframe/frontend/cli.py @@ -27,23 +27,15 @@ def format_check(check, detailed): lines = [' * %s (found in %s)' % (check.name, inspect.getfile(type(check)))] + flex = 'flexible' if check.num_tasks <= 0 else 'inflexible' + if detailed: lines += [ ' - description: %s' % check.descr, ' - systems: %s' % ', '.join(check.valid_systems), ' - environments: %s' % ', '.join(check.valid_prog_environs), - ' - modules: %s' % ', '.join(check.modules) - ] - - if check.num_tasks <= 0: - num_tasks_per_node = check.num_tasks_per_node or 1 - min_num_tasks = (-check.num_tasks if check.num_tasks else - num_tasks_per_node) - num_nodes_required = min_num_tasks // num_tasks_per_node - lines.append( - ' - required nodes: %s' % num_nodes_required) - - lines += [ + ' - modules: %s' % ', '.join(check.modules), + ' - task allocation: %s' % flex, ' - tags: %s' % ', '.join(check.tags), ' - maintainers: %s' % ', '.join(check.maintainers) ] From 0e2c25f9aa734b0fb510735038d272ad0a1e9c46 Mon Sep 17 00:00:00 2001 From: Theofilos Manitaras Date: Mon, 20 May 2019 09:25:57 +0200 Subject: [PATCH 3/4] Update documentation --- docs/running.rst | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/docs/running.rst b/docs/running.rst index 6eb94863d9..1de39664a5 100644 --- a/docs/running.rst +++ b/docs/running.rst @@ -77,7 +77,7 @@ The following example lists detailed information about the tutorial check: .. code-block:: none Command line: ./bin/reframe -c tutorial/ -L - Reframe version: 2.15-dev1 + Reframe version: 2.18-dev2 Launched by user: USER Launched on host: daint103 Reframe paths @@ -94,6 +94,7 @@ The following example lists detailed information about the tutorial check: - systems: daint:gpu - environments: PrgEnv-cray, PrgEnv-gnu, PrgEnv-pgi - modules: cudatoolkit + - task allocation: inflexible - tags: tutorial - maintainers: you-can-type-your-email-here * Example1Test (found in /path/to/reframe/tutorial/example1.py) @@ -101,6 +102,7 @@ The following example lists detailed information about the tutorial check: - systems: * - environments: * - modules: + - task allocation: inflexible - tags: tutorial - maintainers: you-can-type-your-email-here * Example4Test (found in /path/to/reframe/tutorial/example4.py) @@ -108,6 +110,7 @@ The following example lists detailed information about the tutorial check: - systems: daint:gpu - environments: PrgEnv-cray, PrgEnv-pgi - modules: craype-accel-nvidia60 + - task allocation: inflexible - tags: tutorial - maintainers: you-can-type-your-email-here * SerialTest (found in /path/to/reframe/tutorial/example8.py) @@ -115,6 +118,7 @@ The following example lists detailed information about the tutorial check: - systems: * - environments: * - modules: + - task allocation: inflexible - tags: tutorial - maintainers: you-can-type-your-email-here * OpenMPTest (found in /path/to/reframe/tutorial/example8.py) @@ -122,6 +126,7 @@ The following example lists detailed information about the tutorial check: - systems: * - environments: PrgEnv-cray, PrgEnv-gnu, PrgEnv-intel, PrgEnv-pgi - modules: + - task allocation: inflexible - tags: tutorial - maintainers: you-can-type-your-email-here * MPITest (found in /path/to/reframe/tutorial/example8.py) @@ -129,6 +134,7 @@ The following example lists detailed information about the tutorial check: - systems: daint:gpu, daint:mc - environments: PrgEnv-cray, PrgEnv-gnu, PrgEnv-intel, PrgEnv-pgi - modules: + - task allocation: inflexible - tags: tutorial - maintainers: you-can-type-your-email-here * OpenACCTest (found in /path/to/reframe/tutorial/example8.py) @@ -136,6 +142,7 @@ The following example lists detailed information about the tutorial check: - systems: daint:gpu - environments: PrgEnv-cray, PrgEnv-pgi - modules: craype-accel-nvidia60 + - task allocation: inflexible - tags: tutorial - maintainers: you-can-type-your-email-here * CudaTest (found in /path/to/reframe/tutorial/example8.py) @@ -143,6 +150,7 @@ The following example lists detailed information about the tutorial check: - systems: daint:gpu - environments: PrgEnv-gnu, PrgEnv-cray, PrgEnv-pgi - modules: cudatoolkit + - task allocation: inflexible - tags: tutorial - maintainers: you-can-type-your-email-here * Example3Test (found in /path/to/reframe/tutorial/example3.py) @@ -150,6 +158,7 @@ The following example lists detailed information about the tutorial check: - systems: daint:gpu, daint:mc - environments: PrgEnv-cray, PrgEnv-gnu, PrgEnv-intel, PrgEnv-pgi - modules: + - task allocation: inflexible - tags: tutorial - maintainers: you-can-type-your-email-here * Example7Test (found in /path/to/reframe/tutorial/example7.py) @@ -157,6 +166,7 @@ The following example lists detailed information about the tutorial check: - systems: daint:gpu - environments: PrgEnv-gnu, PrgEnv-cray, PrgEnv-pgi - modules: cudatoolkit + - task allocation: inflexible - tags: tutorial - maintainers: you-can-type-your-email-here * Example6Test (found in /path/to/reframe/tutorial/example6.py) @@ -164,6 +174,7 @@ The following example lists detailed information about the tutorial check: - systems: * - environments: * - modules: + - task allocation: inflexible - tags: tutorial - maintainers: you-can-type-your-email-here * Example2aTest (found in /path/to/reframe/tutorial/example2.py) @@ -171,6 +182,7 @@ The following example lists detailed information about the tutorial check: - systems: * - environments: PrgEnv-cray, PrgEnv-gnu, PrgEnv-intel, PrgEnv-pgi - modules: + - task allocation: inflexible - tags: tutorial - maintainers: you-can-type-your-email-here * Example2bTest (found in /path/to/reframe/tutorial/example2.py) @@ -178,6 +190,7 @@ The following example lists detailed information about the tutorial check: - systems: * - environments: PrgEnv-cray, PrgEnv-gnu, PrgEnv-intel, PrgEnv-pgi - modules: + - task allocation: inflexible - tags: tutorial - maintainers: you-can-type-your-email-here Found 13 check(s). From 12188192d610f433a6089fafdfd9282067d9fc03 Mon Sep 17 00:00:00 2001 From: Theofilos Manitaras Date: Tue, 21 May 2019 19:15:56 +0200 Subject: [PATCH 4/4] Address PR comments --- docs/running.rst | 26 +++++++++++++------------- reframe/frontend/cli.py | 2 +- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/docs/running.rst b/docs/running.rst index 1de39664a5..00a5f2580a 100644 --- a/docs/running.rst +++ b/docs/running.rst @@ -94,7 +94,7 @@ The following example lists detailed information about the tutorial check: - systems: daint:gpu - environments: PrgEnv-cray, PrgEnv-gnu, PrgEnv-pgi - modules: cudatoolkit - - task allocation: inflexible + - task allocation: standard - tags: tutorial - maintainers: you-can-type-your-email-here * Example1Test (found in /path/to/reframe/tutorial/example1.py) @@ -102,7 +102,7 @@ The following example lists detailed information about the tutorial check: - systems: * - environments: * - modules: - - task allocation: inflexible + - task allocation: standard - tags: tutorial - maintainers: you-can-type-your-email-here * Example4Test (found in /path/to/reframe/tutorial/example4.py) @@ -110,7 +110,7 @@ The following example lists detailed information about the tutorial check: - systems: daint:gpu - environments: PrgEnv-cray, PrgEnv-pgi - modules: craype-accel-nvidia60 - - task allocation: inflexible + - task allocation: standard - tags: tutorial - maintainers: you-can-type-your-email-here * SerialTest (found in /path/to/reframe/tutorial/example8.py) @@ -118,7 +118,7 @@ The following example lists detailed information about the tutorial check: - systems: * - environments: * - modules: - - task allocation: inflexible + - task allocation: standard - tags: tutorial - maintainers: you-can-type-your-email-here * OpenMPTest (found in /path/to/reframe/tutorial/example8.py) @@ -126,7 +126,7 @@ The following example lists detailed information about the tutorial check: - systems: * - environments: PrgEnv-cray, PrgEnv-gnu, PrgEnv-intel, PrgEnv-pgi - modules: - - task allocation: inflexible + - task allocation: standard - tags: tutorial - maintainers: you-can-type-your-email-here * MPITest (found in /path/to/reframe/tutorial/example8.py) @@ -134,7 +134,7 @@ The following example lists detailed information about the tutorial check: - systems: daint:gpu, daint:mc - environments: PrgEnv-cray, PrgEnv-gnu, PrgEnv-intel, PrgEnv-pgi - modules: - - task allocation: inflexible + - task allocation: standard - tags: tutorial - maintainers: you-can-type-your-email-here * OpenACCTest (found in /path/to/reframe/tutorial/example8.py) @@ -142,7 +142,7 @@ The following example lists detailed information about the tutorial check: - systems: daint:gpu - environments: PrgEnv-cray, PrgEnv-pgi - modules: craype-accel-nvidia60 - - task allocation: inflexible + - task allocation: standard - tags: tutorial - maintainers: you-can-type-your-email-here * CudaTest (found in /path/to/reframe/tutorial/example8.py) @@ -150,7 +150,7 @@ The following example lists detailed information about the tutorial check: - systems: daint:gpu - environments: PrgEnv-gnu, PrgEnv-cray, PrgEnv-pgi - modules: cudatoolkit - - task allocation: inflexible + - task allocation: standard - tags: tutorial - maintainers: you-can-type-your-email-here * Example3Test (found in /path/to/reframe/tutorial/example3.py) @@ -158,7 +158,7 @@ The following example lists detailed information about the tutorial check: - systems: daint:gpu, daint:mc - environments: PrgEnv-cray, PrgEnv-gnu, PrgEnv-intel, PrgEnv-pgi - modules: - - task allocation: inflexible + - task allocation: standard - tags: tutorial - maintainers: you-can-type-your-email-here * Example7Test (found in /path/to/reframe/tutorial/example7.py) @@ -166,7 +166,7 @@ The following example lists detailed information about the tutorial check: - systems: daint:gpu - environments: PrgEnv-gnu, PrgEnv-cray, PrgEnv-pgi - modules: cudatoolkit - - task allocation: inflexible + - task allocation: standard - tags: tutorial - maintainers: you-can-type-your-email-here * Example6Test (found in /path/to/reframe/tutorial/example6.py) @@ -174,7 +174,7 @@ The following example lists detailed information about the tutorial check: - systems: * - environments: * - modules: - - task allocation: inflexible + - task allocation: standard - tags: tutorial - maintainers: you-can-type-your-email-here * Example2aTest (found in /path/to/reframe/tutorial/example2.py) @@ -182,7 +182,7 @@ The following example lists detailed information about the tutorial check: - systems: * - environments: PrgEnv-cray, PrgEnv-gnu, PrgEnv-intel, PrgEnv-pgi - modules: - - task allocation: inflexible + - task allocation: standard - tags: tutorial - maintainers: you-can-type-your-email-here * Example2bTest (found in /path/to/reframe/tutorial/example2.py) @@ -190,7 +190,7 @@ The following example lists detailed information about the tutorial check: - systems: * - environments: PrgEnv-cray, PrgEnv-gnu, PrgEnv-intel, PrgEnv-pgi - modules: - - task allocation: inflexible + - task allocation: standard - tags: tutorial - maintainers: you-can-type-your-email-here Found 13 check(s). diff --git a/reframe/frontend/cli.py b/reframe/frontend/cli.py index 4ccbcda51d..9397c5f10a 100644 --- a/reframe/frontend/cli.py +++ b/reframe/frontend/cli.py @@ -27,7 +27,7 @@ def format_check(check, detailed): lines = [' * %s (found in %s)' % (check.name, inspect.getfile(type(check)))] - flex = 'flexible' if check.num_tasks <= 0 else 'inflexible' + flex = 'flexible' if check.num_tasks <= 0 else 'standard' if detailed: lines += [