iree-org / iree

A retargetable MLIR-based machine learning compiler and runtime toolkit.

Home Page:http://iree.dev/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

custom op 'linalg.pad_tensor' is unknown

pshung opened this issue · comments

Describe the bug

I've compiled a tensorflow saved_model using 'iree-import-tf'.
The generated MLIR contains the "linalg.pad_tensor" operation.
When I compile using 'iree-compile', it shows that "custom op 'linalg.pad_tensor' is unknown"

I find there is a patch that moving this operation to 'tensor' dialet.
https://reviews.llvm.org/D117892

Is there a consistency issue between the front end and the MLIR?

BTW, the tool 'iree-import-tf' is installed by python pip.
How can I build 'iree-import-tf' from the source?

It's been moved for a while. The latest release/tag should contain the change. You won't hit the issue if you update the package.

For building it from source, please see https://google.github.io/iree/building-from-source/python-bindings-and-importers/#python-bindings-and-importers

I'm using the latest tag 'candidate-20220413.106'
It has the same issue.

Maybe what I need to update is the 'iree-import-tf'?
Is there an pre-built 'iree-import-tf' which can fix this issue? (If I don't wanna build those command-line tools from source)