示例#1
0
        /// <summary>全結合</summary>
        public static VariableNode Dense(VariableNode x, VariableNode w)
        {
            Function function =
                new Functions.ConnectionDense.Dense(x.Shape, w.Shape);

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

            return(y);
        }
示例#2
0
        /// <summary>全結合</summary>
        public static Tensor Dense(Tensor x, Tensor w)
        {
            Functions.ConnectionDense.Dense function =
                new Functions.ConnectionDense.Dense(x.Shape, w.Shape);

            Tensor y = new Tensor(function.OutShape);

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

            return(y);
        }