conv1d_op
Structs
Struct: Conv1d
Namespace for 1D convolution operations.
Fields
Methods
compute_shape(mut curr: ArrayShape, args: List[ArrayShape])
Computes the shape of an array after a 1-dimensional convolution operation.
__call__(mut curr: Array, args: List[Array])
vjp(primals: List[Array], grad: Array, out: Array) -> List[Array]
jvp(primals: List[Array], tangents: List[Array]) -> Array
fwd(arg0: Array, kernel: Array, bias: Array, stride: Int, padding: Int, dilation: Int, groups: Int) -> Array
more details
Functions
conv1d
conv1d(arg0: Array, kernel: Array, bias: Array, stride: Int, padding: Int, dilation: Int, groups: Int) -> Array
Applies a 1D convolution over an input signal composed of several input planes.
Args
-
arg0
:Array
Input tensor of shape (batch_size, in_channels, length). -
kernel
:Array
Convolution kernel of shape (out_channels, in_channels // groups, kernel_size). -
bias
:Array
Bias tensor of shape (out_channels). -
stride
:Int
Stride of the convolution. -
padding
:Int
Zero-padding added to both sides of the input. -
dilation
:Int
Spacing between kernel elements. -
groups
:Int
Number of blocked connections from input channels to output channels.
Returns
Array
- Output tensor of shape (batch_size, out_channels, output_length).
Last updated on