Skip to content

doc: input_signature cannot be a numpy array unlike documentation says #2396

@JohannesBuchner

Description

@JohannesBuchner

Describe the bug
The readme of from_keras (here: https://github.com/onnx/tensorflow-onnx?tab=readme-ov-file#from_keras-tf-20-and-newer)
says: "input_signature: a tf.TensorSpec or a numpy array defining the shape/dtype of the input"

However, this is wrong in two levels:
First, providing a single value gives an error saying that a list or tuple of TensorSpec was expected.
Second, providing a tuple with numpy arrays is also not allowed.

Urgency

System information

  • OS Platform and Distribution (e.g., Linux Ubuntu 18.04*): Ubuntu 24.04
  • TensorFlow Version: 2.19.0
  • Python version: 3.12
  • ONNX version (if applicable, e.g. 1.11*): 1.17.0
  • ONNXRuntime version (if applicable, e.g. 1.11*): 1.19.2

To Reproduce

Screenshots

Additional context

Activity

added
bugAn unexpected problem or unintended behavior
on Jun 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugAn unexpected problem or unintended behavior

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @JohannesBuchner

        Issue actions

          doc: input_signature cannot be a numpy array unlike documentation says · Issue #2396 · onnx/tensorflow-onnx