Support complex types of float and double. See the added test for an example.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
mlir/test/Integration/Dialect/SparseTensor/taco/tools/mlir_pytaco.py | ||
---|---|---|
78 | I have been using np.complex128/np.complex64 for these, since I like the bit-number at the end (which is also consistent with what we do for float). Do you mind changing that here? | |
mlir/test/Integration/Dialect/SparseTensor/taco/tools/mlir_pytaco_api.py | ||
44 | same question on complex128, or is this defined by taco this way? | |
mlir/test/Integration/Dialect/SparseTensor/taco/tools/mlir_pytaco_utils.py | ||
142 | note that we now have mlir.runtime.as_ctype() and mlir.runtime.C128/C64 so I don't think you need to do this "doubling" trick anymore | |
151 | we have mlir.runtime.to_numpy() |
mlir/test/Integration/Dialect/SparseTensor/taco/tools/mlir_pytaco.py | ||
---|---|---|
75 | Note that we can include np.float16 also now! |
Use runtime.as_ctype and runtime.to_numpy.
replace csingle/cdouble with complex64/128.
mlir/test/Integration/Dialect/SparseTensor/taco/tools/mlir_pytaco_utils.py | ||
---|---|---|
142 | use runtime.as_ctype and runtime.to_numpy |
few last naming nitpicks, but this looks solid!
mlir/test/Integration/Dialect/SparseTensor/taco/test_tensor_complex.py | ||
---|---|---|
14 | complex64/128? | |
mlir/test/Integration/Dialect/SparseTensor/taco/tools/mlir_pytaco_api.py | ||
44 | same question, did you keep this csingle/cdouble on purpose? | |
mlir/test/Integration/Dialect/SparseTensor/taco/tools/mlir_pytaco_utils.py | ||
96 | np.complex64/128? | |
149 | yes, nice! |
mlir/test/Integration/Dialect/SparseTensor/taco/tools/mlir_pytaco.py | ||
---|---|---|
75 | Will add this and test in another PR. |
complex64/128?