intel / intel/torch-xpu-ops

[release/2.14] Failing test case `test_operator_empty_xpu_float32` from op_extended: AssertionError: Scalars are not close!

Open
#4,454 2 comments 0 reactions 0 assignees View on GitHub
os: Linux os: Windows os: WSL skipped test: ut
Dominant language
Python
Stars
113
Forks
128
Avg merge
5d 13h
Merged PRs (30d)
107

Description

### 🐛 Describe the bug

Cases:
op_extended,third_party.torch-xpu-ops.test.xpu.extended.test_ops_xpu.TestCompositeComplianceXPU,test_operator_empty_xpu_float32

Example Nightly:
https://github.com/intel/torch-xpu-ops/actions/runs/30204638220

Error log

```text
2026-07-26T16:43:44.1168315Z __________ TestCompositeComplianceXPU.test_operator_empty_xpu_float32 __________
2026-07-26T16:43:44.1168748Z [gw7] linux -- Python 3.10.20 /tmp/xpu-tool/Python/3.10.20/x64/bin/python
2026-07-26T16:43:44.1169087Z Traceback (most recent call last):
2026-07-26T16:43:44.1180812Z File "/__w/torch-xpu-ops/torch-xpu-ops/pytorch/third_party/torch-xpu-ops/test/xpu/extended/test_ops_xpu.py", line 221, in test_operator
2026-07-26T16:43:44.1181640Z test_composite_compliance_test_fn(self.proxy, device, dtype, op)
2026-07-26T16:43:44.1182201Z File "/__w/torch-xpu-ops/torch-xpu-ops/pytorch/third_party/torch-xpu-ops/test/xpu/../../../../test/test_ops.py", line 1948, in test_operator
2026-07-26T16:43:44.1182782Z composite_compliance.check_with_mode(op, args, kwargs, self.assertEqual)
2026-07-26T16:43:44.1183393Z File "/tmp/xpu-tool/Python/3.10.20/x64/lib/python3.10/site-packages/torch/testing/_internal/composite_compliance.py", line 415, in check_with_mode
2026-07-26T16:43:44.1183918Z assert_equal_fn(tree_map(unwrap, actual), expected)
2026-07-26T16:43:44.1184414Z File "/tmp/xpu-tool/Python/3.10.20/x64/lib/python3.10/site-packages/torch/testing/_internal/common_utils.py", line 4809, in assertEqual
2026-07-26T16:43:44.1184940Z raise error_metas.pop()[0].to_error( # type: ignore[index]
2026-07-26T16:43:44.1185260Z AssertionError: Scalars are not close!
2026-07-26T16:43:44.1185420Z
2026-07-26T16:43:44.1185550Z Expected 1.175494490952134e-38 but got -6.710257053375244.
2026-07-26T16:43:44.1185880Z Absolute difference: 6.710257053375244 (up to 1e-05 allowed)
2026-07-26T16:43:44.1186214Z Relative difference: 5.708454701425296e+38 (up to 1.3e-06 allowed)
2026-07-26T16:43:44.1186432Z
2026-07-26T16:43:44.1186778Z To execute this test, run the following from the base repo dir:
2026-07-26T16:43:44.1187290Z PYTORCH_TEST_WITH_SLOW=1 python test/xpu/extended/test_ops_xpu.py TestCompositeComplianceXPU.test_operator_empty_xpu_float32
```

### Versions

Version

```text
2026-07-26T16:06:27.5603007Z PyTorch version: 2.14.0a0+gitdc26b59
2026-07-26T16:06:27.5604222Z Is debug build: False
2026-07-26T16:06:27.5605182Z CUDA used to build PyTorch: None
2026-07-26T16:06:27.5606171Z ROCM used to build PyTorch: N/A
2026-07-26T16:06:27.5606800Z
2026-07-26T16:06:27.5607374Z OS: Ubuntu 24.04.4 LTS (x86_64)
2026-07-26T16:06:27.5609386Z GCC version: (Ubuntu 13.3.0-6ubuntu2~24.04.1) 13.3.0
2026-07-26T16:06:27.5610899Z Clang version: Could not collect
2026-07-26T16:06:27.5611888Z CMake version: version 3.31.6
2026-07-26T16:06:27.5612861Z Libc version: glibc-2.39
2026-07-26T16:06:27.5613399Z
2026-07-26T16:06:27.5614199Z Python version: 3.10.20 (main, Jun 16 2026, 21:01:32) [GCC 13.3.0] (64-bit runtime)
2026-07-26T16:06:27.5616474Z Python platform: Linux-5.15.0-176-generic-x86_64-with-glibc2.39
2026-07-26T16:06:27.5617841Z Is CUDA available: False
2026-07-26T16:06:27.5618760Z CUDA runtime version: No CUDA
2026-07-26T16:06:27.5619715Z CUDA_MODULE_LOADING set to: N/A
2026-07-26T16:06:27.5620704Z GPU models and configuration: No CUDA
2026-07-26T16:06:27.5621760Z Nvidia driver version: No CUDA
2026-07-26T16:06:27.5622680Z cuDNN version: No CUDA
2026-07-26T16:06:27.5623539Z Is XPU available: True
2026-07-26T16:06:27.5624413Z XPU used to build PyTorch: 20260000
2026-07-26T16:06:27.5625408Z Intel GPU driver version:
2026-07-26T16:06:27.5626365Z * intel-opencl-icd: 25.18.33578.51-1146~24.04
2026-07-26T16:06:27.5627461Z * libze1: 1.24.0.0-1146~24.04
2026-07-26T16:06:27.5628336Z Intel GPU models onboard:
2026-07-26T16:06:27.5629249Z * Intel(R) Data Center GPU Max 1100
2026-07-26T16:06:27.5630206Z * Intel(R) Data Center GPU Max 1100
2026-07-26T16:06:27.5631121Z * Intel(R) Data Center GPU Max 1100
2026-07-26T16:06:27.5632057Z * Intel(R) Data Center GPU Max 1100
2026-07-26T16:06:27.5632958Z * Intel(R) Data Center GPU Max 1100
2026-07-26T16:06:27.5633869Z * Intel(R) Data Center GPU Max 1100
2026-07-26T16:06:27.5634773Z * Intel(R) Data Center GPU Max 1100
2026-07-26T16:06:27.5635678Z * Intel(R) Data Center GPU Max 1100
2026-07-26T16:06:27.5636583Z Intel GPU models detected:
2026-07-26T16:06:27.5642868Z * [0] _XpuDeviceProperties(name='Intel(R) Data Center GPU Max 1100', platform_name='Intel(R) oneAPI Unified Runtime over Level-Zero', type='gpu', device_id=0xBDA, uuid=8680da0b-2f00-0000-0f00-000000000000, driver_version='1.6.33578+51', total_memory=49136MB, local_mem_size=128KB, last_level_cache_size=196608KB, max_compute_units=448, memory_clock_rate=3200MHz, memory_bus_width=64-bit, gpu_eu_count=448, gpu_subslice_count=56, max_work_group_size=1024, max_num_sub_groups=64, sub_group_sizes=[16 32], has_fp16=1, has_fp64=1, has_atomic64=1, is_integrated_gpu=0)
2026-07-26T16:06:27.5654271Z * [1] _XpuDeviceProperties(name='Intel(R) Data Center GPU Max 1100', platform_name='Intel(R) oneAPI Unified Runtime over Level-Zero', type='gpu', device_id=0xBDA, uuid=8680da0b-2f00-0000-1600-000000000000, driver_version='1.6.33578+51', total_memory=49136MB, local_mem_size=128KB, last_level_cache_size=196608KB, max_compute_units=448, memory_clock_rate=3200MHz, memory_bus_width=64-bit, gpu_eu_count=448, gpu_subslice_count=56, max_work_group_size=1024, max_num_sub_groups=64, sub_group_sizes=[16 32], has_fp16=1, has_fp64=1, has_atomic64=1, is_integrated_gpu=0)
2026-07-26T16:06:27.5665621Z * [2] _XpuDeviceProperties(name='Intel(R) Data Center GPU Max 1100', platform_name='Intel(R) oneAPI Unified Runtime over Level-Zero', type='gpu', device_id=0xBDA, uuid=8680da0b-2f00-0000-1a00-000000000000, driver_version='1.6.33578+51', total_memory=49136MB, local_mem_size=128KB, last_level_cache_size=196608KB, max_compute_units=448, memory_clock_rate=3200MHz, memory_bus_width=64-bit, gpu_eu_count=448, gpu_subslice_count=56, max_work_group_size=1024, max_num_sub_groups=64, sub_group_sizes=[16 32], has_fp16=1, has_fp64=1, has_atomic64=1, is_integrated_gpu=0)
2026-07-26T16:06:27.5676802Z * [3] _XpuDeviceProperties(name='Intel(R) Data Center GPU Max 1100', platform_name='Intel(R) oneAPI Unified Runtime over Level-Zero', type='gpu', device_id=0xBDA, uuid=8680da0b-2f00-0000-1e00-000000000000, driver_version='1.6.33578+51', total_memory=49136MB, local_mem_size=128KB, last_level_cache_size=196608KB, max_compute_units=448, memory_clock_rate=3200MHz, memory_bus_width=64-bit, gpu_eu_count=448, gpu_subslice_count=56, max_work_group_size=1024, max_num_sub_groups=64, sub_group_sizes=[16 32], has_fp16=1, has_fp64=1, has_atomic64=1, is_integrated_gpu=0)
2026-07-26T16:06:27.5688423Z * [4] _XpuDeviceProperties(name='Intel(R) Data Center GPU Max 1100', platform_name='Intel(R) oneAPI Unified Runtime over Level-Zero', type='gpu', device_id=0xBDA, uuid=8680da0b-2f00-0000-af00-000000000000, driver_version='1.6.33578+51', total_memory=49136MB, local_mem_size=128KB, last_level_cache_size=196608KB, max_compute_units=448, memory_clock_rate=3200MHz, memory_bus_width=64-bit, gpu_eu_count=448, gpu_subslice_count=56, max_work_group_size=1024, max_num_sub_groups=64, sub_group_sizes=[16 32], has_fp16=1, has_fp64=1, has_atomic64=1, is_integrated_gpu=0)
2026-07-26T16:06:27.5699609Z * [5] _XpuDeviceProperties(name='Intel(R) Data Center GPU Max 1100', platform_name='Intel(R) oneAPI Unified Runtime over Level-Zero', type='gpu', device_id=0xBDA, uuid=edadf662-40ad-3802-0000-000000000000, driver_version='1.6.33578+51', total_memory=49136MB, local_mem_size=128KB, last_level_cache_size=196608KB, max_compute_units=448, memory_clock_rate=3200MHz, memory_bus_width=64-bit, gpu_eu_count=448, gpu_subslice_count=56, max_work_group_size=1024, max_num_sub_groups=64, sub_group_sizes=[16 32], has_fp16=1, has_fp64=1, has_atomic64=1, is_integrated_gpu=0)
2026-07-26T16:06:27.5710811Z * [6] _XpuDeviceProperties(name='Intel(R) Data Center GPU Max 1100', platform_name='Intel(R) oneAPI Unified Runtime over Level-Zero', type='gpu', device_id=0xBDA, uuid=edc040d7-d709-5ff6-0000-000000000000, driver_version='1.6.33578+51', total_memory=49136MB, local_mem_size=128KB, last_level_cache_size=196608KB, max_compute_units=448, memory_clock_rate=3200MHz, memory_bus_width=64-bit, gpu_eu_count=448, gpu_subslice_count=56, max_work_group_size=1024, max_num_sub_groups=64, sub_group_sizes=[16 32], has_fp16=1, has_fp64=1, has_atomic64=1, is_integrated_gpu=0)
2026-07-26T16:06:27.5721937Z * [7] _XpuDeviceProperties(name='Intel(R) Data Center GPU Max 1100', platform_name='Intel(R) oneAPI Unified Runtime over Level-Zero', type='gpu', device_id=0xBDA, uuid=c8270f23-6d34-2345-0000-000000000000, driver_version='1.6.33578+51', total_memory=49136MB, local_mem_size=128KB, last_level_cache_size=196608KB, max_compute_units=448, memory_clock_rate=3200MHz, memory_bus_width=64-bit, gpu_eu_count=448, gpu_subslice_count=56, max_work_group_size=1024, max_num_sub_groups=64, sub_group_sizes=[16 32], has_fp16=1, has_fp64=1, has_atomic64=1, is_integrated_gpu=0)
2026-07-26T16:06:27.5727961Z HIP runtime version: N/A
2026-07-26T16:06:27.5728870Z MIOpen runtime version: N/A
2026-07-26T16:06:27.5729766Z Is XNNPACK available: False
2026-07-26T16:06:27.5730657Z Caching allocator config: N/A
2026-07-26T16:06:27.5731245Z
2026-07-26T16:06:27.5731554Z CPU:
2026-07-26T16:06:27.5732361Z Architecture: x86_64
2026-07-26T16:06:27.5733573Z CPU op-mode(s): 32-bit, 64-bit
2026-07-26T16:06:27.5734922Z Address sizes: 46 bits physical, 57 bits virtual
2026-07-26T16:06:27.5736363Z Byte Order: Little Endian
2026-07-26T16:06:27.5737484Z CPU(s): 192
2026-07-26T16:06:27.5738548Z On-line CPU(s) list: 0-191
2026-07-26T16:06:27.5739700Z Vendor ID: GenuineIntel
2026-07-26T16:06:27.5740946Z Model name: Intel(R) Xeon(R) Platinum 8468V
2026-07-26T16:06:27.5742159Z CPU family: 6
2026-07-26T16:06:27.5743144Z Model: 143
2026-07-26T16:06:27.5744178Z Thread(s) per core: 2
2026-07-26T16:06:27.5745180Z Core(s) per socket: 48
2026-07-26T16:06:27.5746171Z Socket(s): 2
2026-07-26T16:06:27.5747117Z Stepping: 8
2026-07-26T16:06:27.5748159Z Frequency boost: enabled
2026-07-26T16:06:27.5749228Z CPU(s) scaling MHz: 37%
2026-07-26T16:06:27.5750286Z CPU max MHz: 2401.0000
2026-07-26T16:06:27.5751396Z CPU min MHz: 800.0000
2026-07-26T16:06:27.5752988Z BogoMIPS: 4800.00
2026-07-26T16:06:27.5766820Z Flags: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc art arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf tsc_known_freq pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid dca sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm 3dnowprefetch cpuid_fault epb cat_l3 cat_l2 cdp_l3 invpcid_single intel_ppin cdp_l2 ssbd mba ibrs ibpb stibp ibrs_enhanced tpr_shadow vnmi flexpriority ept vpid ept_ad fsgsbase tsc_adjust bmi1 avx2 smep bmi2 erms invpcid cqm rdt_a avx512f avx512dq rdseed adx smap avx512ifma clflushopt clwb intel_pt avx512cd sha_ni avx512bw avx512vl xsaveopt xsavec xgetbv1 xsaves cqm_llc cqm_occup_llc cqm_mbm_total cqm_mbm_local split_lock_detect avx_vnni avx512_bf16 wbnoinvd dtherm ida arat pln pts avx512vbmi umip pku ospke waitpkg avx512_vbmi2 gfni vaes vpclmulqdq avx512_vnni avx512_bitalg tme avx512_vpopcntdq la57 rdpid bus_lock_detect cldemote movdiri movdir64b enqcmd fsrm md_clear serialize tsxldtrk pconfig arch_lbr amx_bf16 avx512_fp16 amx_tile amx_int8 flush_l1d arch_capabilities ibpb_exit_to_user
2026-07-26T16:06:27.5781087Z Virtualization: VT-x
2026-07-26T16:06:27.5782297Z L1d cache: 4.5 MiB (96 instances)
2026-07-26T16:06:27.5783581Z L1i cache: 3 MiB (96 instances)
2026-07-26T16:06:27.5784860Z L2 cache: 192 MiB (96 instances)
2026-07-26T16:06:27.5786125Z L3 cache: 195 MiB (2 instances)
2026-07-26T16:06:27.5787242Z NUMA node(s): 2
2026-07-26T16:06:27.5788355Z NUMA node0 CPU(s): 0-47,96-143
2026-07-26T16:06:27.5789543Z NUMA node1 CPU(s): 48-95,144-191
2026-07-26T16:06:27.5790825Z Vulnerability Gather data sampling: Not affected
2026-07-26T16:06:27.5792097Z Vulnerability Indirect target selection: Not affected
2026-07-26T16:06:27.5793355Z Vulnerability Itlb multihit: Not affected
2026-07-26T16:06:27.5794542Z Vulnerability L1tf: Not affected
2026-07-26T16:06:27.5795696Z Vulnerability Mds: Not affected
2026-07-26T16:06:27.5796885Z Vulnerability Meltdown: Not affected
2026-07-26T16:06:27.5798071Z Vulnerability Mmio stale data: Not affected
2026-07-26T16:06:27.5799274Z Vulnerability Reg file data sampling: Not affected
2026-07-26T16:06:27.5800461Z Vulnerability Retbleed: Not affected
2026-07-26T16:06:27.5801668Z Vulnerability Spec rstack overflow: Not affected
2026-07-26T16:06:27.5803456Z Vulnerability Spec store bypass: Mitigation; Speculative Store Bypass disabled via prctl and seccomp
2026-07-26T16:06:27.5805814Z Vulnerability Spectre v1: Mitigation; usercopy/swapgs barriers and __user pointer sanitization
2026-07-26T16:06:27.5808371Z Vulnerability Spectre v2: Mitigation; Enhanced / Automatic IBRS; IBPB conditional; PBRSB-eIBRS SW sequence; BHI BHI_DIS_S
2026-07-26T16:06:27.5810362Z Vulnerability Srbds: Not affected
2026-07-26T16:06:27.5811537Z Vulnerability Tsa: Not affected
2026-07-26T16:06:27.5812729Z Vulnerability Tsx async abort: Not affected
2026-07-26T16:06:27.5814179Z Vulnerability Vmscape: Mitigation; IBPB before exit to userspace
2026-07-26T16:06:27.5815293Z
2026-07-26T16:06:27.5815670Z Versions of relevant libraries:
2026-07-26T16:06:27.5816649Z [pip3] dpcpp-cpp-rt==2026.0.0
2026-07-26T16:06:27.5817570Z [pip3] impi-rt==2021.18.0
2026-07-26T16:06:27.5818486Z [pip3] intel-cmplr-lib-rt==2026.0.0
2026-07-26T16:06:27.5819481Z [pip3] intel-cmplr-lib-ur==2026.0.0
2026-07-26T16:06:27.5820451Z [pip3] intel-cmplr-lic-rt==2026.0.0
2026-07-26T16:06:27.5825058Z [pip3] intel-opencl-rt==2026.0.0
2026-07-26T16:06:27.5826018Z [pip3] intel-openmp==2026.0.0
2026-07-26T16:06:27.5826930Z [pip3] intel-pti==0.17.0
2026-07-26T16:06:27.5827856Z [pip3] intel-sycl-rt==2026.0.0
2026-07-26T16:06:27.5828750Z [pip3] mkl==2026.0.0
2026-07-26T16:06:27.5829542Z [pip3] mypy==1.16.0
2026-07-26T16:06:27.5830357Z [pip3] mypy_extensions==1.1.0
2026-07-26T16:06:27.5831259Z [pip3] numpy==1.24.4
2026-07-26T16:06:27.5832112Z [pip3] nvidia-cuda-cupti==13.3.75
2026-07-26T16:06:27.5833056Z [pip3] oneccl==2022.0.0
2026-07-26T16:06:27.5833919Z [pip3] oneccl-devel==2022.0.0
2026-07-26T16:06:27.5834855Z [pip3] onemkl-license==2026.0.0
2026-07-26T16:06:27.5835792Z [pip3] onemkl-sycl-blas==2026.0.0
2026-07-26T16:06:27.5836742Z [pip3] onemkl-sycl-dft==2026.0.0
2026-07-26T16:06:27.5837714Z [pip3] onemkl-sycl-lapack==2026.0.0
2026-07-26T16:06:27.5838673Z [pip3] onemkl-sycl-rng==2026.0.0
2026-07-26T16:06:27.5839606Z [pip3] onemkl-sycl-sparse==2026.0.0
2026-07-26T16:06:27.5840536Z [pip3] onnx==1.21.0
2026-07-26T16:06:27.5841367Z [pip3] onnx-ir==0.1.16
2026-07-26T16:06:27.5842200Z [pip3] onnxscript==0.6.2
2026-07-26T16:06:27.5843045Z [pip3] optree==0.13.0
2026-07-26T16:06:27.5843825Z [pip3] tbb==2023.0.0
2026-07-26T16:06:27.5844617Z [pip3] tcmlib==1.5.0
2026-07-26T16:06:27.5845424Z [pip3] torch==2.14.0a0+gitdc26b59
2026-07-26T16:06:27.5846363Z [pip3] torchao==0.18.0.dev20260726+xpu
2026-07-26T16:06:27.5847338Z [pip3] torchaudio==2.11.0a0+c0cbdb9
2026-07-26T16:06:27.5848304Z [pip3] torchvision==0.29.0a0+3f87802
2026-07-26T16:06:27.5849276Z [pip3] triton-xpu==3.7.2+git5fcc14d9
2026-07-26T16:06:27.5850244Z [pip3] umf==1.1.0
2026-07-26T16:06:27.5851097Z [conda] No relevant packages
2026-07-26T16:06:28.2354127Z + pip list
2026-07-26T16:06:28.2355193Z + grep -E 'torch|intel'
2026-07-26T16:06:28.6360900Z intel-cmplr-lib-rt 2026.0.0
2026-07-26T16:06:28.6363202Z intel-cmplr-lib-ur 2026.0.0
2026-07-26T16:06:28.6364427Z intel-cmplr-lic-rt 2026.0.0
2026-07-26T16:06:28.6365476Z intel-opencl-rt 2026.0.0
2026-07-26T16:06:28.6366431Z intel-openmp 2026.0.0
2026-07-26T16:06:28.6367371Z intel-pti 0.17.0
2026-07-26T16:06:28.6368333Z intel-sycl-rt 2026.0.0
2026-07-26T16:06:28.6369329Z torch 2.14.0a0+gitdc26b59
2026-07-26T16:06:28.6370470Z torchao 0.18.0.dev20260726+xpu
2026-07-26T16:06:28.6371553Z torchaudio 2.11.0a0+c0cbdb9
2026-07-26T16:06:28.6372583Z torchvision 0.29.0a0+3f87802
2026-07-26T16:06:28.6374592Z ++ python -c 'import torch; print(torch.version.git_version)'
2026-07-26T16:06:31.0462019Z + TORCH_CHECK_ID=dc26b59876c3726fe657d77782b2dcd302bb0c8b
```

Contributor guide

Open the contributing guide

Research direction

Reproduce the failure with PYTORCH_TEST_WITH_SLOW=1 python test/xpu/extended/test_ops_xpu.py TestCompositeComplianceXPU.test_operator_empty_xpu_float32. Start at test/xpu/extended/test_ops_xpu.py line 221 and follow the composite compliance check reported in the traceback. Done means the float32 empty-XPU operator case produces the expected scalar and the targeted test passes.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
testing-qa
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.