aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/core/framework/partial_tensor_shape.h
diff options
context:
space:
mode:
authorGravatar Peter Hawkins <phawkins@google.com>2017-03-06 15:33:13 -0800
committerGravatar TensorFlower Gardener <gardener@tensorflow.org>2017-03-06 15:45:45 -0800
commit1d8934f63718c6b5009f1f84b336d2ac218c0922 (patch)
tree47dd069a30bb6c7df294f6da151f6d1ad280e6ae /tensorflow/core/framework/partial_tensor_shape.h
parent9ccda399bc9e948255285326fb1dfd960b78df2d (diff)
Add convenience methods to ShapeInference: MakeShapeFromTensorShape() and MakeShapeFromPartialTensorShape(). Update existing users of MakeShapeFromShapeProto to use the new helper methods where possible.
Change: 149353816
Diffstat (limited to 'tensorflow/core/framework/partial_tensor_shape.h')
-rw-r--r--tensorflow/core/framework/partial_tensor_shape.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/tensorflow/core/framework/partial_tensor_shape.h b/tensorflow/core/framework/partial_tensor_shape.h
index 1504b8c983..7a70167d7c 100644
--- a/tensorflow/core/framework/partial_tensor_shape.h
+++ b/tensorflow/core/framework/partial_tensor_shape.h
@@ -40,7 +40,7 @@ class PartialTensorShape {
PartialTensorShape() : is_unknown_(true) {}
/// \brief Construct a `PartialTensorShape` from the provided sizes.
- /// REQUIRES: `dim_sizes[i] >= 0`
+ /// REQUIRES: `dim_sizes[i] >= -1`; `-1` means `unknown`.
explicit PartialTensorShape(gtl::ArraySlice<int64> dim_sizes);
PartialTensorShape(std::initializer_list<int64> dim_sizes)
: PartialTensorShape(gtl::ArraySlice<int64>(dim_sizes)) {}