Esempio n. 1
0
        /// <summary>実数から3次元ベクトルを構成</summary>
        public static Tensor TrivectorCast(Tensor x, Tensor y, Tensor z)
        {
            Function function = new Functions.Trivector.TrivectorCast();

            Shape v_shape = function.OutputShapes(x.Shape)[0];

            Tensor v = new Tensor(v_shape);

            function.Execute(new Tensor[] { x, y, z }, new Tensor[] { v });

            return(y);
        }
Esempio n. 2
0
        /// <summary>実数から3次元ベクトルを構成</summary>
        public static VariableNode TrivectorCast(VariableNode x, VariableNode y, VariableNode z)
        {
            Function function = new Functions.Trivector.TrivectorCast();

            return(Apply(function, x, y, z)[0]);
        }