예제 #1
0
        /// <summary>四元数2次元畳み込み</summary>
        public static VariableNode QuaternionConvolution2D(VariableNode x, VariableNode w, int stride, bool gradmode = false)
        {
            Function function =
                new Functions.QuaternionConvolution.QuaternionConvolution2D(x.Shape, w.Shape, stride, gradmode);

            VariableNode y = Apply(function, x, w)[0];

            return(y);
        }
예제 #2
0
        /// <summary>四元数2次元畳み込み</summary>
        public static Tensor QuaternionConvolution2D(Tensor x, Tensor w, int stride, bool gradmode = false)
        {
            Functions.QuaternionConvolution.QuaternionConvolution2D function =
                new Functions.QuaternionConvolution.QuaternionConvolution2D(x.Shape, w.Shape, stride, gradmode);

            Tensor y = new Tensor(function.OutShape);

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

            return(y);
        }