按元素計算 x 的 acos。
用法
tf.math.acos(
x, name=None
)參數
-
x一個Tensor。必須是以下類型之一:bfloat16,half,float32,float64,uint8,int8,int16,int32,int64,complex64,complex128,string。 -
name操作的名稱(可選)。
返回
-
一個
Tensor。與 x 具有相同的類型。
提供輸入張量,tf.math.acos 運算返回張量每個元素的反餘弦值。如果 y = tf.math.cos(x) 那麽, x = tf.math.acos(y) 。
輸入範圍為 [-1, 1] ,輸出範圍為 [0, pi] 。
例如:
x = tf.constant([1.0, -0.5, 3.4, 0.2, 0.0, -2], dtype = tf.float32)
tf.math.acos(x)
<tf.Tensor:shape=(6,), dtype=float32,
numpy= array([0. , 2.0943952, nan, 1.3694383, 1.5707964, nan],
dtype=float32)>
相關用法
- Python tf.math.acosh用法及代碼示例
- Python tf.math.accumulate_n用法及代碼示例
- Python tf.math.angle用法及代碼示例
- Python tf.math.add_n用法及代碼示例
- Python tf.math.argmax用法及代碼示例
- Python tf.math.atan用法及代碼示例
- Python tf.math.argmin用法及代碼示例
- Python tf.math.add用法及代碼示例
- Python tf.math.asin用法及代碼示例
- Python tf.math.asinh用法及代碼示例
- Python tf.math.abs用法及代碼示例
- Python tf.math.atan2用法及代碼示例
- Python tf.math.atanh用法及代碼示例
- Python tf.math.special.fresnel_cos用法及代碼示例
- Python tf.math.polyval用法及代碼示例
- Python tf.math.is_finite用法及代碼示例
- Python tf.math.special.bessel_k0e用法及代碼示例
- Python tf.math.invert_permutation用法及代碼示例
- Python tf.math.segment_prod用法及代碼示例
- Python tf.math.bincount用法及代碼示例
注:本文由純淨天空篩選整理自tensorflow.org大神的英文原創作品 tf.math.acos。非經特殊聲明,原始代碼版權歸原作者所有,本譯文未經允許或授權,請勿轉載或複製。
