Library/ManagedCuda/CudaDNN/CudaDNNContext.cs
/// <summary>  
/// This function is used to query the amount of reserve needed to run dropout with the input dimensions given by xDesc.   
/// The same reserve space is expected to be passed to cudnnDropoutForward and cudnnDropoutBackward, and its contents is   
/// expected to remain unchanged between cudnnDropoutForward and cudnnDropoutBackward calls.   
/// </summary>  
/// <param name="xDesc">Handle to a previously initialized tensor descriptor, describing input to a dropout operation.</param>  
This function is used to query the amount of reserve needed to run dropout with the input dimensions given by xDesc.
The same reserve space is expected to be passed to cudnnDropoutForward and cudnnDropoutBackward, and its contents is
expected to remain unchanged between cudnnDropoutForward and cudnnDropoutBackward calls.
This function is used to query the amount of reserve needed to run dropout with the input dimensions given by xDesc . The same reserve space is expected to be passed to cudnnDropoutForward and cudnnDropoutBackward and its contents is expected to remain unchanged between cudnnDropoutForward and cudnnDropoutBackward calls .
public SizeT GetDropoutReserveSpaceSize(TensorDescriptor xDesc)
        {
            SizeT sizeInBytes = new SizeT();
            res = CudaDNNNativeMethods.cudnnDropoutGetReserveSpaceSize(xDesc.Desc, ref sizeInBytes);
            Debug.WriteLine(String.Format("{0:G}, {1}: {2}", DateTime.Now, "cudnnDropoutGetReserveSpaceSize", res));
            if (res != cudnnStatus.Success) throw new CudaDNNException(res);
            return sizeInBytes;
        }
public SizeT GetDropoutReserveSpaceSize ( TensorDescriptor xDesc ) { SizeT sizeInBytes = new SizeT ( ) ; res = CudaDNNNativeMethods . cudnnDropoutGetReserveSpaceSize ( xDesc . Desc , ref sizeInBytes ) ; Debug . WriteLine ( String . Format ( " " , DateTime . Now , " " , res ) ) ; if ( res != cudnnStatus . Success ) throw new CudaDNNException ( res ) ; return sizeInBytes ; }
This function is used to query the amount of reserve needed to run dropout with the input dimensions given by xDesc.
This function is used to query the amount of reserve needed to run dropout with the input dimensions given by xDesc .
xDesc
TensorDescriptor
Handle to a previously initialized tensor descriptor, describing input to a dropout operation.
Handle to a previously initialized tensor descriptor describing input to a dropout operation .