tf.estimator.export.ServingInputReceiver
Stay organized with collections
Save and categorize content based on your preferences.
A return type for a serving_input_receiver_fn.
View aliases
Compat aliases for migration
See
Migration guide for
more details.
`tf.compat.v1.estimator.export.ServingInputReceiver`
tf.estimator.export.ServingInputReceiver(
features, receiver_tensors, receiver_tensors_alternatives=None
)
Attributes |
features
|
A Tensor , SparseTensor , or dict of string or int to Tensor
or SparseTensor , specifying the features to be passed to the model.
Note: if features passed is not a dict, it will be wrapped in a dict
with a single entry, using 'feature' as the key. Consequently, the
model
must accept a feature dict of the form {'feature': tensor}. You may use
TensorServingInputReceiver if you want the tensor to be passed as is.
|
receiver_tensors
|
A Tensor , SparseTensor , or dict of string to Tensor
or SparseTensor , specifying input nodes where this receiver expects to
be fed by default. Typically, this is a single placeholder expecting
serialized tf.Example protos.
|
receiver_tensors_alternatives
|
a dict of string to additional groups of
receiver tensors, each of which may be a Tensor , SparseTensor , or dict
of string to Tensor orSparseTensor . These named receiver tensor
alternatives generate additional serving signatures, which may be used to
feed inputs at different points within the input receiver subgraph. A
typical usage is to allow feeding raw feature Tensor s downstream of
the tf.parse_example() op. Defaults to None.
|
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 2023-10-06 UTC.
[null,null,["Last updated 2023-10-06 UTC."],[],[],null,["# tf.estimator.export.ServingInputReceiver\n\n\u003cbr /\u003e\n\n|-----------------------------------------------------------------------------------------------------------------------------------------------|\n| [View source on GitHub](https://github.com/tensorflow/estimator/tree/master/tensorflow_estimator/python/estimator/export/export.py#L108-L162) |\n\nA return type for a serving_input_receiver_fn.\n\n#### View aliases\n\n\n**Compat aliases for migration**\n\nSee\n[Migration guide](https://www.tensorflow.org/guide/migrate) for\nmore details.\n\n\\`tf.compat.v1.estimator.export.ServingInputReceiver\\`\n\n\u003cbr /\u003e\n\n tf.estimator.export.ServingInputReceiver(\n features, receiver_tensors, receiver_tensors_alternatives=None\n )\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Attributes ---------- ||\n|---------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `features` | A `Tensor`, `SparseTensor`, or dict of string or int to `Tensor` or `SparseTensor`, specifying the features to be passed to the model. Note: if `features` passed is not a dict, it will be wrapped in a dict with a single entry, using 'feature' as the key. Consequently, the model must accept a feature dict of the form {'feature': tensor}. You may use `TensorServingInputReceiver` if you want the tensor to be passed as is. |\n| `receiver_tensors` | A `Tensor`, `SparseTensor`, or dict of string to `Tensor` or `SparseTensor`, specifying input nodes where this receiver expects to be fed by default. Typically, this is a single placeholder expecting serialized `tf.Example` protos. |\n| `receiver_tensors_alternatives` | a dict of string to additional groups of receiver tensors, each of which may be a `Tensor`, `SparseTensor`, or dict of string to `Tensor` or`SparseTensor`. These named receiver tensor alternatives generate additional serving signatures, which may be used to feed inputs at different points within the input receiver subgraph. A typical usage is to allow feeding raw feature `Tensor`s *downstream* of the tf.parse_example() op. Defaults to None. |\n\n\u003cbr /\u003e"]]