예제 #1
0
 /// <summary>
 /// Applies a 1D average pooling over an input signal composed of several input planes.
 /// </summary>
 /// <param name="x">The input signal tensor</param>
 /// <param name="kernelSize">The size of the window</param>
 /// <param name="stride">The stride of the window. Default value is kernel_size</param>
 /// <returns></returns>
 static public TorchTensor AvgPool1d(TorchTensor x, long kernelSize, long?stride = null)
 {
     using (var d = Modules.AvgPool1d(kernelSize, stride)) {
         return(d.forward(x));
     }
 }