ATen Operator Coverage Report - intel/torch-xpu-ops GitHub Wiki
To obtain aten operator coverage report, we need to follow the setups below:
- Source build. (We need to trigger codegen through source build.)
git clone https://github.com/pytorch/pytorch
cd pytorch
git submodule update --init --recursive
python setup.py install
Note: There is no need to complete the build; just wait for the codegen to finish, which usually happens before building the kernel.
- Report generation.
python pytorch/third_party/torch-xpu-ops/tools/check_ops.py
The output log:
/home/sdp/xyt/pytorch/build/aten/src/ATen/RegisterCUDA_0.cpp <- Generated files in use for report
/home/sdp/xyt/pytorch/build/aten/src/ATen/RegisterSparseCUDA_0.cpp
/home/sdp/xyt/pytorch/build/aten/src/ATen/RegisterSparseCsrCUDA_0.cpp
/home/sdp/xyt/pytorch/build/aten/src/ATen/RegisterNestedTensorCUDA_0.cpp
/home/sdp/xyt/pytorch/build/xpu/ATen/RegisterXPU_0.cpp
/home/sdp/xyt/pytorch/build/xpu/ATen/RegisterSparseXPU_0.cpp
/home/sdp/xyt/pytorch/build/xpu/ATen/RegisterSparseCsrXPU_0.cpp
/home/sdp/xyt/pytorch/build/xpu/ATen/RegisterNestedTensorXPU_0.cpp
============ CUDA ============ <- CUDA aten operator count
basic_keys: 1220
sparse_keys: 171
sparse_csr_keys: 139
nested_tensor_keys: 100
============ XPU ============ <- XPU aten operator count
basic_keys: 1104
sparse_keys: 160
sparse_csr_keys: 127
nested_tensor_keys: 93
============ basic_keys ============ <- Ops not available on XPU compared to CUDA. (basic)
_cholesky_solve_helper
_conv_depthwise2d
_conv_depthwise2d.out
_cslt_compress
_cslt_sparse_mm
...
============ sparse_keys ============ <- Ops not available on XPU compared to CUDA. (basic)
...
============ nested_tensor_keys ============ <- Ops not available on XPU compared to CUDA. (nested tensor)
...
Note: This program currently cannot output the data types supported by the ops.