tfc.ops.entropy_encode_channel
Stay organized with collections
Save and categorize content based on your preferences.
Encodes each input in value
.
tfc.ops.entropy_encode_channel(
handle, value, name=None
)
In general, entropy encoders in handle
reference multiple distributions.
The last (innermost) dimension of value
determines which distribution is used
to encode value
. For example, if value
is a 3-D array, then value(i,j,k)
is encoded using the k
-th distribution.
handle
controls the number of coding streams. Suppose that value
has the
shape [2, 3, 4]
and that handle
has shape [2]
. Then the first slice
[0, :, :]
of shape [3, 4]
is encoded into handle[0]
and the second
slice [1, :, :]
is encoded into handle[1]
. If handle
has shape []
, then
there is only one handle, and the entire input is encoded into a single stream.
Values must be in the provided ranges specified when the input handle
was
originally created, unless overflow functionality was enabled. The handle
may
be produced by the CreateRangeEncoder
op, or may be passed through from a
different EntropyEncodeChannel/EntropyEncodeIndex
op.
Because the op modifies handle
, the corresponding input edge to the op nodes
of this type should not have other consumers in the graph.
Args |
handle
|
A Tensor of type variant .
|
value
|
A Tensor . Must be one of the following types: int32 .
|
name
|
A name for the operation (optional).
|
Returns |
A Tensor of type variant .
|
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates. Some content is licensed under the numpy license.
Last updated 2024-04-26 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-04-26 UTC."],[],[],null,["# tfc.ops.entropy_encode_channel\n\n\u003cbr /\u003e\n\nEncodes each input in `value`.\n\n#### View aliases\n\n\n**Main aliases**\n\n[`tfc.entropy_encode_channel`](https://www.tensorflow.org/api_docs/python/tfc/ops/entropy_encode_channel)\n\n\u003cbr /\u003e\n\n tfc.ops.entropy_encode_channel(\n handle, value, name=None\n )\n\nIn general, entropy encoders in `handle` reference multiple distributions.\nThe last (innermost) dimension of `value` determines which distribution is used\nto encode `value`. For example, if `value` is a 3-D array, then `value(i,j,k)`\nis encoded using the `k`-th distribution.\n\n`handle` controls the number of coding streams. Suppose that `value` has the\nshape `[2, 3, 4]` and that `handle` has shape `[2]`. Then the first slice\n`[0, :, :]` of shape `[3, 4]` is encoded into `handle[0]` and the second\nslice `[1, :, :]` is encoded into `handle[1]`. If `handle` has shape `[]`, then\nthere is only one handle, and the entire input is encoded into a single stream.\n\nValues must be in the provided ranges specified when the input `handle` was\noriginally created, unless overflow functionality was enabled. The `handle` may\nbe produced by the `CreateRangeEncoder` op, or may be passed through from a\ndifferent `EntropyEncodeChannel/EntropyEncodeIndex` op.\n\nBecause the op modifies `handle`, the corresponding input edge to the op nodes\nof this type should not have other consumers in the graph.\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Args ---- ||\n|----------|----------------------------------------------------------|\n| `handle` | A `Tensor` of type `variant`. |\n| `value` | A `Tensor`. Must be one of the following types: `int32`. |\n| `name` | A name for the operation (optional). |\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Returns ------- ||\n|---|---|\n| A `Tensor` of type `variant`. ||\n\n\u003cbr /\u003e"]]