tf.contrib.autograph.stack
Stay organized with collections
Save and categorize content based on your preferences.
Stacks the input, if it admits the notion of stacking.
tf.contrib.autograph.stack(
list_or_tensor, element_dtype=None, strict=True
)
For example, a list of tensors can be stacked into a larger tensor. This
function is similar to tf.stack, but it accepts non-lists and lists of
non-tensors as arguments. In the latter case, the function does nothing.
Args |
list_or_tensor
|
Any
|
element_dtype
|
tf.DType, optional dtypedtype for the elements in the list.
Required if the input is stackable, and the list is untyped.
|
strict
|
bool, if True an error is raised if the input is not stackable.
Otherwise the function is a no-op.
|
Returns |
Any, if the input is stackable, the result will be a tf.Tensor. Otherwise,
if strict=False, the result will be list_or_tensor.
|
Raises |
ValueError
|
if strict=True and the input is not stackable.
|
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.
Last updated 2020-10-01 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 2020-10-01 UTC."],[],[]]