tensorflow::ops::Sign
#include <math_ops.h>
Возвращает элемент-мудрое указание знака числа.
Summary
y = sign(x) = -1 если x < 0; 0, если x == 0; 1, если x > 0.
Для комплексных чисел, y = sign(x) = x / |x|, если x != 0, в противном случае y = 0.
Пример использования: tf.math.sign([0., 2., -3.])
Args:
- scope: Объект Scope
Returns:
-
Output: Тензор y.
| Конструкторы и деструкторы | |
|---|---|
Sign(const ::tensorflow::Scope & scope, ::tensorflow::Input x) |
| Общедоступные атрибуты | |
|---|---|
operation | |
y | |
| Общедоступные функции | |
|---|---|
node() const | ::tensorflow::Node * |
operator::tensorflow::Input() const | |
operator::tensorflow::Output() const | |
Общедоступные атрибуты
operation
Operation operation
y
::tensorflow::Output y
Общедоступные функции
Sign
Sign( const ::tensorflow::Scope & scope, ::tensorflow::Input x )
узел
::tensorflow::Node * node() const
operator::tensorflow::Input
operator::tensorflow::Input() const
operator::tensorflow::Output
operator::tensorflow::Output() const
© 2022 The TensorFlow Authors. All rights reserved.
Licensed under the Creative Commons Attribution License 4.0.
Code samples licensed under the Apache 2.0 License.
https://www.tensorflow.org/api_docs/cc/class/tensorflow/ops/sign