Skip to content

Commit da98c52

Browse files
committed
increase max_failed_tests for PyTorch 2.1.2 to 4 for Sapphire Rapids
1 parent 33f4321 commit da98c52

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

eb_hooks.py

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
CPU_TARGET_AARCH64_GENERIC = 'aarch64/generic'
2727
CPU_TARGET_A64FX = 'aarch64/a64fx'
2828

29+
CPU_TARGET_SAPPHIRE_RAPIDS = 'x86_64/intel/sapphire_rapids'
2930
CPU_TARGET_ZEN4 = 'x86_64/amd/zen4'
3031

3132
EESSI_RPATH_OVERRIDE_ATTR = 'orig_rpath_override_dirs'
@@ -817,11 +818,16 @@ def pre_test_hook_ignore_failing_tests_netCDF(self, *args, **kwargs):
817818

818819
def pre_test_hook_increase_max_failed_tests_arm_PyTorch(self, *args, **kwargs):
819820
"""
820-
Pre-test hook for PyTorch: increase max failing tests for ARM for PyTorch 2.1.2
821-
See https://github.com/EESSI/software-layer/pull/444#issuecomment-1890416171
821+
Pre-test hook for PyTorch: increase max failing tests for ARM and Intel Sapphire Rapids for PyTorch 2.1.2
822+
See https://github.com/EESSI/software-layer/pull/444#issuecomment-1890416171 and
823+
https://github.com/EESSI/software-layer/pull/875#issuecomment-2606854400
822824
"""
823-
if self.name == 'PyTorch' and self.version == '2.1.2' and get_cpu_architecture() == AARCH64:
824-
self.cfg['max_failed_tests'] = 10
825+
cpu_target = get_eessi_envvar('EESSI_SOFTWARE_SUBDIR')
826+
if self.name == 'PyTorch' and self.version == '2.1.2':
827+
if get_cpu_architecture() == AARCH64:
828+
self.cfg['max_failed_tests'] = 10
829+
if cpu_target == CPU_TARGET_SAPPHIRE_RAPIDS:
830+
self.cfg['max_failed_tests'] = 4
825831

826832

827833
def pre_single_extension_hook(ext, *args, **kwargs):

0 commit comments

Comments
 (0)