[mlir][taco] Add a utility to create an MLIR sparse tensor from a file.
authorBixia Zheng <bixia@google.com>
Fri, 28 Jan 2022 18:56:50 +0000 (10:56 -0800)
committerBixia Zheng <bixia@google.com>
Tue, 1 Feb 2022 23:43:53 +0000 (15:43 -0800)
commitae7ee655a9f1386feed49d6eb5c902bfebb752ec
tree0ed9e0cd93261bfcee7d7b7405d5020a07833d68
parent46add4901fb08dcca14c4caaef908f86a108c27f
[mlir][taco] Add a utility to create an MLIR sparse tensor from a file.

Move the functions that retrieve the supporting C library, compile an MLIR
module and build a JIT execution engine to mlir_pytaco_utils.

Add a function to create an MLIR sparse tensor from a file and return a pointer
to the MLIR sparse tensor as well as the shape of the sparse tensor.

Add unit tests.

Reviewed By: aartbik

Differential Revision: https://reviews.llvm.org/D118496
mlir/test/Integration/Dialect/SparseTensor/taco/tools/mlir_pytaco.py
mlir/test/Integration/Dialect/SparseTensor/taco/tools/mlir_pytaco_utils.py
mlir/test/Integration/Dialect/SparseTensor/taco/unit_test_tensor_utils.py [new file with mode: 0644]