# tf.io.decode_json_example

<br />

|---|
| [![](https://www.tensorflow.org/images/tf_logo_32px.png) TensorFlow 2 version](https://www.tensorflow.org/api_docs/python/tf/io/decode_json_example) |

Convert JSON-encoded Example records to binary protocol buffer strings.

#### View aliases


**Main aliases**

\`tf.decode_json_example\`
**Compat aliases for migration**

See
[Migration guide](https://www.tensorflow.org/guide/migrate) for
more details.

[`tf.compat.v1.decode_json_example`](https://www.tensorflow.org/api_docs/python/tf/io/decode_json_example), [`tf.compat.v1.io.decode_json_example`](https://www.tensorflow.org/api_docs/python/tf/io/decode_json_example), \`tf.compat.v2.io.decode_json_example\`

<br />

    tf.io.decode_json_example(
        json_examples, name=None
    )

This op translates a tensor containing Example records, encoded using
the [standard JSON
mapping](https://developers.google.com/protocol-buffers/docs/proto3#json),
into a tensor containing the same records encoded as binary protocol
buffers. The resulting tensor can then be fed to any of the other
Example-parsing ops.

<br />

<br />

<br />

| ## Args ||
|---|---|
| `json_examples` | A `Tensor` of type `string`. Each string is a JSON object serialized according to the JSON mapping of the Example proto. |
| `name` | A name for the operation (optional). |

<br />

<br />

<br />

<br />

| ## Returns ||
|---|---|
| A `Tensor` of type `string`. ||

<br />