Library/ManagedCuda/CudaDNN/CudaDNNNativeMethods.cs
/// <summary>
/// Performs backward pass of Batch Normalization layer. Returns x gradient, bnScale gradient and bnBias gradient
/// </summary>
/// <param name="handle"></param>
/// <param name="mode"></param>
/// <param name="alphaDataDiff"></param>
/// <param name="betaDataDiff"></param>
/// <param name="alphaParamDiff"></param>
/// <param name="betaParamDiff"></param>
/// <param name="xDesc"></param>
/// <param name="x"></param>
/// <param name="dyDesc"></param>
/// <param name="dy"></param>
/// <param name="dxDesc"></param>
/// <param name="dx"></param>
/// <param name="dBnScaleBiasDesc"></param>
/// <param name="bnScale"></param>
/// <param name="dBnScaleResult"></param>
/// <param name="dBnBiasResult"></param>
/// <param name="epsilon"></param>
/// <param name="savedMean"></param>
/// <param name="savedInvVariance"></param>
/// <returns></returns>
Performs backward pass of Batch Normalization layer.
Performs backward pass of Batch Normalization layer .
[DllImport(CUDNN_API_DLL_NAME)]
        public static extern cudnnStatus cudnnBatchNormalizationBackward(
                                        cudnnHandle handle,
                                        cudnnBatchNormMode mode,
                                        ref float alphaDataDiff,
                                        ref float betaDataDiff,
                                        ref float alphaParamDiff,
                                        ref float betaParamDiff,
                                        cudnnTensorDescriptor xDesc, 
                                        CUdeviceptr x,
                                        cudnnTensorDescriptor dyDesc,
                                        CUdeviceptr dy,
                                        cudnnTensorDescriptor dxDesc,
                                        CUdeviceptr dx,
                                        cudnnTensorDescriptor dBnScaleBiasDesc,
                                        CUdeviceptr bnScale, 
                                        CUdeviceptr dBnScaleResult,
                                        CUdeviceptr dBnBiasResult,
                                        double epsilon,
                                        CUdeviceptr savedMean,
                                        CUdeviceptr savedInvVariance );
[ DllImport ( CUDNN_API_DLL_NAME ) ] public static extern cudnnStatus cudnnBatchNormalizationBackward ( cudnnHandle handle , cudnnBatchNormMode mode , ref float alphaDataDiff , ref float betaDataDiff , ref float alphaParamDiff , ref float betaParamDiff , cudnnTensorDescriptor xDesc , CUdeviceptr x , cudnnTensorDescriptor dyDesc , CUdeviceptr dy , cudnnTensorDescriptor dxDesc , CUdeviceptr dx , cudnnTensorDescriptor dBnScaleBiasDesc , CUdeviceptr bnScale , CUdeviceptr dBnScaleResult , CUdeviceptr dBnBiasResult , double epsilon , CUdeviceptr savedMean , CUdeviceptr savedInvVariance ) ;
Performs backward pass of Batch Normalization layer.
Performs backward pass of Batch Normalization layer .
// same desc for x, dx, dy /* Shared tensor desc for the 4 tensors below */ // bnBias doesn't affect backpropagation /* scale and bias diff are not backpropagated below this layer */ /* Same epsilon as forward pass */ /* Optionally cached intermediate results from
                                           forward pass */
None
handle
cudnnHandle
None
mode
cudnnBatchNormMode
None
float
ref
xDesc
cudnnTensorDescriptor
None
x
CUdeviceptr
None
dyDesc
cudnnTensorDescriptor
None
dy
CUdeviceptr
None
dxDesc
cudnnTensorDescriptor
None
dx
CUdeviceptr
None
dBnScaleBiasDesc
cudnnTensorDescriptor
None
bnScale
CUdeviceptr
None
dBnScaleResult
CUdeviceptr
None
dBnBiasResult
CUdeviceptr
None
epsilon
double
None
savedMean
CUdeviceptr
None
savedInvVariance
CUdeviceptr
None
alphaDataDiff
None
betaDataDiff
None
alphaParamDiff
None
betaParamDiff
None