fn
unfold_op
→TensorImplPtrint unfold_op(const int & x, const int & kernel, const int & stride, const int & pad, const int & dilation)Python wrappers
Public Python APIs implemented by this engine symbol.Public entry point for Unfold (im2col).
Functional wrapper around UnfoldBackward::forward for building
custom convolution-like ops in user code.
Parameters
xTensorImplPtrInput of shape
(B, C, S_0, ..., S_{N-1}).kernelvector<int>Per-axis kernel size; length determines
N.stridevector<int>Per-axis stride.
padvector<int>Per-axis zero-padding.
dilationvector<int>Per-axis kernel-element spacing.
Returns
TensorImplPtrPatch-as-columns tensor of shape (B, C * prod(K), prod(O)).