torch-mlir/lib/Conversion
Felix Schneider fb21a85874
[TorchToLinalg] Lower grouped conv2d to linalg Op with correct dimension ordering (#2623)
The linalg Op `linalg.conv_2d_ngchw_fgchw` had a bug where

1. Weights were accessed as G,F,C,H,W instead of as F,G,C,H,W
2. Output was accessed as N,F,G,H,W instead of as N,G,F,H,W

Now this has been fixed in
https://github.com/llvm/llvm-project/pull/73855 which broke the
torch-mlir lowering to that Op.

This patch switches lowering in torch-mlir to the newly introduced
`linalg.conv_2d_ngchw_gfchw` op which accesses weights in an order that
is compatible with PyTorch's memory layout.

Fix https://github.com/llvm/torch-mlir/issues/2622
2023-12-08 14:18:23 +01:00
..
TorchConversionToMLProgram Re-organize project structure to separate PyTorch dependencies from core project. (#2542) 2023-11-02 19:45:55 -07:00
TorchOnnxToTorch [MLIR][ONNX] Add OnnxToTorch support for atan and bitwise ops 2023-11-28 17:19:07 +05:30
TorchToArith Fix for unused variable failure when trying to bump torch-mlir in IREE (#2560) 2023-11-08 15:55:41 -08:00
TorchToLinalg [TorchToLinalg] Lower grouped conv2d to linalg Op with correct dimension ordering (#2623) 2023-12-08 14:18:23 +01:00
TorchToSCF Re-organize project structure to separate PyTorch dependencies from core project. (#2542) 2023-11-02 19:45:55 -07:00
TorchToStablehlo Advance llvm-project and stablehlo. (#2619) 2023-12-07 23:13:42 -08:00
TorchToTMTensor Re-organize project structure to separate PyTorch dependencies from core project. (#2542) 2023-11-02 19:45:55 -07:00
TorchToTosa Re-organize project structure to separate PyTorch dependencies from core project. (#2542) 2023-11-02 19:45:55 -07:00
Utils [Torch Dialect]Support aten.cosine_similarity (#2364) 2023-11-08 15:28:30 +08:00
CMakeLists.txt Initial TorchOnnxToTorch conversion pipeline. (#2585) 2023-11-21 21:02:55 -08:00
PassDetail.h Minor fixes for `ConvertTorchConversionToMLProgram`. (#1991) 2023-04-04 09:09:58 -07:00
Passes.cpp Remove mlir-hlo (replace with stablehlo). (#2460) 2023-09-12 19:10:02 -07:00