Package org.nd4j.linalg.convolution
Class OldConvolution
- java.lang.Object
-
- org.nd4j.linalg.convolution.OldConvolution
-
public class OldConvolution extends Object
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static INDArray
col2im(INDArray col, int[] stride, int[] padding, int height, int width)
static INDArray
col2im(INDArray col, int sy, int sx, int ph, int pw, int h, int w)
Rearrange matrix columns into blocksstatic INDArray
im2col(INDArray img, int[] kernel, int[] stride, int[] padding)
static INDArray
im2col(INDArray img, int kh, int kw, int sy, int sx, int ph, int pw, int pval, boolean coverAll)
Implement column formatted imagesstatic int
outSize(int size, int k, int s, int p, boolean coverAll)
The out size for a convolutionstatic long
outSize(long size, long k, long s, long p, boolean coverAll)
-
-
-
Method Detail
-
col2im
public static INDArray col2im(INDArray col, int[] stride, int[] padding, int height, int width)
- Parameters:
col
-stride
-padding
-height
-width
-- Returns:
-
col2im
public static INDArray col2im(INDArray col, int sy, int sx, int ph, int pw, int h, int w)
Rearrange matrix columns into blocks- Parameters:
col
- the column transposed image to convertsy
- stride ysx
- stride xph
- padding heightpw
- padding widthh
- heightw
- width- Returns:
-
im2col
public static INDArray im2col(INDArray img, int[] kernel, int[] stride, int[] padding)
- Parameters:
img
-kernel
-stride
-padding
-- Returns:
-
im2col
public static INDArray im2col(INDArray img, int kh, int kw, int sy, int sx, int ph, int pw, int pval, boolean coverAll)
Implement column formatted images- Parameters:
img
- the image to processkh
- the kernel heightkw
- the kernel widthsy
- the stride along ysx
- the stride along xph
- the padding widthpw
- the padding heightpval
- the padding valuecoverAll
- whether to cover the whole image or not- Returns:
- the column formatted image
-
outSize
public static int outSize(int size, int k, int s, int p, boolean coverAll)
The out size for a convolution- Parameters:
size
-k
-s
-p
-coverAll
-- Returns:
-
outSize
public static long outSize(long size, long k, long s, long p, boolean coverAll)
-
-