コード例 #1
0
        public static NdArray <Real> SingleInputForward(NdArray <Real> x, IFunction <Real> arcCos)
        {
            Real[] resultData = new Real[x.Data.Length];

            for (int i = 0; i < resultData.Length; i++)
            {
                resultData[i] = Math.Acos(x.Data[i]);
            }

            return(new NdArray <Real>(resultData, x.Shape, x.BatchCount, arcCos));
        }
コード例 #2
0
ファイル: Single.cs プロジェクト: ZhengDaoWang/runtime
 static float IFloatingPoint <float> .Acos(float x)
 => MathF.Acos(x);
コード例 #3
0
ファイル: Single.cs プロジェクト: ManickaP/runtime
 /// <inheritdoc cref="IFloatingPoint{TSelf}.Acos(TSelf)" />
 public static float Acos(float x) => MathF.Acos(x);