Class PoolingDescriptor
An opaque structure holding the description of a pooling operation.
Inheritance
Implements
Inherited Members
Namespace: ManagedCuda.CudaDNN
Assembly: CudaDNN.dll
Syntax
public class PoolingDescriptor : IDisposable
Constructors
| Improve this Doc View SourcePoolingDescriptor()
Declaration
public PoolingDescriptor()
Properties
| Improve this Doc View SourceDesc
Returns the inner handle.
Declaration
public cudnnPoolingDescriptor Desc { get; }
Property Value
Type | Description |
---|---|
cudnnPoolingDescriptor |
Methods
| Improve this Doc View SourceDispose()
Dispose
Declaration
public void Dispose()
Dispose(Boolean)
For IDisposable
Declaration
protected virtual void Dispose(bool fDisposing)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | fDisposing |
Finalize()
For dispose
Declaration
protected void Finalize()
GetPooling2dDescriptor(ref cudnnPoolingMode, ref cudnnNanPropagation, ref Int32, ref Int32, ref Int32, ref Int32, ref Int32, ref Int32)
This function queries a previously created 2D pooling descriptor object.
Declaration
public void GetPooling2dDescriptor(ref cudnnPoolingMode mode, ref cudnnNanPropagation maxpoolingNanOpt, ref int windowHeight, ref int windowWidth, ref int verticalPadding, ref int horizontalPadding, ref int verticalStride, ref int horizontalStride)
Parameters
Type | Name | Description |
---|---|---|
cudnnPoolingMode | mode | Enumerant to specify the pooling mode. |
cudnnNanPropagation | maxpoolingNanOpt | Nan propagation option for max pooling. |
System.Int32 | windowHeight | Height of the pooling window. |
System.Int32 | windowWidth | Width of the pooling window. |
System.Int32 | verticalPadding | Size of vertical padding. |
System.Int32 | horizontalPadding | Size of horizontal padding. |
System.Int32 | verticalStride | Pooling vertical stride. |
System.Int32 | horizontalStride | Pooling horizontal stride. |
GetPooling2dForwardOutputDim(TensorDescriptor, ref Int32, ref Int32, ref Int32, ref Int32)
This function provides the output dimensions of a tensor after 2d pooling has been applied
Declaration
public void GetPooling2dForwardOutputDim(TensorDescriptor inputTensorDesc, ref int n, ref int c, ref int h, ref int w)
Parameters
Type | Name | Description |
---|---|---|
TensorDescriptor | inputTensorDesc | Handle to the previously initialized input tensor descriptor. |
System.Int32 | n | Number of images in the output |
System.Int32 | c | Number of channels in the output |
System.Int32 | h | Height of images in the output |
System.Int32 | w | Width of images in the output |
GetPoolingNdDescriptor(Int32, ref cudnnPoolingMode, ref cudnnNanPropagation, ref Int32, Int32[], Int32[], Int32[])
This function queries a previously initialized generic pooling descriptor object.
Declaration
public void GetPoolingNdDescriptor(int nbDimsRequested, ref cudnnPoolingMode mode, ref cudnnNanPropagation maxpoolingNanOpt, ref int nbDims, int[] windowDimA, int[] paddingA, int[] strideA)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | nbDimsRequested | Dimension of the expected pooling descriptor. It is also the minimum size of the arrays windowDimA, paddingA and strideA in order to be able to hold the results |
cudnnPoolingMode | mode | Enumerant to specify the pooling mode. |
cudnnNanPropagation | maxpoolingNanOpt | Nan propagation option for max pooling. |
System.Int32 | nbDims | Actual dimension of the pooling descriptor. |
System.Int32[] | windowDimA | Array of dimension of at least nbDimsRequested that will be filled with the window parameters from the provided pooling descriptor. |
System.Int32[] | paddingA | Array of dimension of at least nbDimsRequested that will be filled with the padding parameters from the provided pooling descriptor. |
System.Int32[] | strideA | Array of dimension at least nbDimsRequested that will be filled with the stride parameters from the provided pooling descriptor. |
GetPoolingNdForwardOutputDim(TensorDescriptor, Int32, Int32[])
This function provides the output dimensions of a tensor after Nd pooling has been applied
Declaration
public void GetPoolingNdForwardOutputDim(TensorDescriptor inputTensorDesc, int nbDims, int[] outputTensorDimA)
Parameters
Type | Name | Description |
---|---|---|
TensorDescriptor | inputTensorDesc | Handle to the previously initialized input tensor descriptor. |
System.Int32 | nbDims | Number of dimensions in which pooling is to be applied. |
System.Int32[] | outputTensorDimA | Array of nbDims output dimensions |
SetPooling2dDescriptor(cudnnPoolingMode, cudnnNanPropagation, Int32, Int32, Int32, Int32, Int32, Int32)
This function initializes a previously created generic pooling descriptor object into a 2D description.
Declaration
public void SetPooling2dDescriptor(cudnnPoolingMode mode, cudnnNanPropagation maxpoolingNanOpt, int windowHeight, int windowWidth, int verticalPadding, int horizontalPadding, int verticalStride, int horizontalStride)
Parameters
Type | Name | Description |
---|---|---|
cudnnPoolingMode | mode | Enumerant to specify the pooling mode. |
cudnnNanPropagation | maxpoolingNanOpt | Nan propagation option for max pooling. |
System.Int32 | windowHeight | Height of the pooling window. |
System.Int32 | windowWidth | Width of the pooling window. |
System.Int32 | verticalPadding | Size of vertical padding. |
System.Int32 | horizontalPadding | Size of horizontal padding |
System.Int32 | verticalStride | Pooling vertical stride. |
System.Int32 | horizontalStride | Pooling horizontal stride. |
SetPoolingNdDescriptor(cudnnPoolingMode, cudnnNanPropagation, Int32, Int32[], Int32[], Int32[])
This function initializes a previously created generic pooling descriptor object.
Declaration
public void SetPoolingNdDescriptor(cudnnPoolingMode mode, cudnnNanPropagation maxpoolingNanOpt, int nbDims, int[] windowDimA, int[] paddingA, int[] strideA)
Parameters
Type | Name | Description |
---|---|---|
cudnnPoolingMode | mode | Enumerant to specify the pooling mode. |
cudnnNanPropagation | maxpoolingNanOpt | Nan propagation option for max pooling. |
System.Int32 | nbDims | Dimension of the pooling operation. |
System.Int32[] | windowDimA | Array of dimension nbDims containing the window size for each dimension. |
System.Int32[] | paddingA | Array of dimension nbDims containing the padding size for each dimension. |
System.Int32[] | strideA | Array of dimension nbDims containing the striding size for each dimension. |