Skip to content

Unsupported operations for TensorFlow word embeddings demo model #1328

@marshallpierce

Description

@marshallpierce

Describe the bug
The simple TensorFlow word embeddings demo produces a model that tf2onnx can't convert.

Urgency
We are prototyping using onnx (via onnxruntime), so the more of our models we can convert the more likely we are to be able to move forward with onnx. :)

System information

  • OS Platform and Distribution (e.g., Linux Ubuntu 16.04): macOS 10.15.7
  • Tensorflow Version: 2.4.1
  • Python version: 3.8.7

To Reproduce
Follow the TensorFlow word embeddings demo notebook at https://www.tensorflow.org/tutorials/text/word_embeddings, and add a cell to save the model with model.save('file name here').

Converting the model via python -m tf2onnx.convert --saved-model saved --output word-embeddings.onnx --opset 13 produces:

ERROR - Unsupported ops: Counter({'StaticRegexReplace': 2, 'StringLower': 1, 'StringSplitV2': 1, 'RaggedTensorToTensor': 1})

Expected behavior
The model should convert without error.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions