#include <string_ops.h>
Optional attribute setters for AsString.
Public attributes | |
---|---|
fill_ = "" | StringPiece |
precision_ = -1 | int64 |
scientific_ = false | bool |
shortest_ = false | bool |
width_ = -1 | int64 |
Public functions | |
---|---|
Fill(StringPiece x) | The value to pad if width > -1. |
Precision(int64 x) | The post-decimal precision to use for floating point numbers. |
Scientific(bool x) | Use scientific notation for floating point numbers. |
Shortest(bool x) | Use shortest representation (either scientific or standard) for floating point numbers. |
Width(int64 x) |
Pad pre-decimal numbers to this width. |
StringPiece tensorflow::ops::AsString::Attrs::fill_ = ""
int64 tensorflow::ops::AsString::Attrs::precision_ = -1
bool tensorflow::ops::AsString::Attrs::scientific_ = false
bool tensorflow::ops::AsString::Attrs::shortest_ = false
int64 tensorflow::ops::AsString::Attrs::width_ = -1
Attrs tensorflow::ops::AsString::Attrs::Fill( StringPiece x )
The value to pad if width > -1.
If empty, pads with spaces. Another typical value is '0'. String cannot be longer than 1 character.
Defaults to ""
Attrs tensorflow::ops::AsString::Attrs::Precision( int64 x )
The post-decimal precision to use for floating point numbers.
Only used if precision > -1.
Defaults to -1
Attrs tensorflow::ops::AsString::Attrs::Scientific( bool x )
Use scientific notation for floating point numbers.
Defaults to false
Attrs tensorflow::ops::AsString::Attrs::Shortest( bool x )
Use shortest representation (either scientific or standard) for floating point numbers.
Defaults to false
Attrs tensorflow::ops::AsString::Attrs::Width( int64 x )
Pad pre-decimal numbers to this width.
Applies to both floating point and integer numbers. Only used if width > -1.
Defaults to -1
© 2017 The TensorFlow Authors. All rights reserved.
Licensed under the Creative Commons Attribution License 3.0.
Code samples licensed under the Apache 2.0 License.
https://www.tensorflow.org/api_docs/cc/struct/tensorflow/ops/as-string/attrs.html