Skip to main content
`Ctrl`+`K`

# ReLU

MIOpen: ReLU
Functions
ReLU

## Functions

miopenStatus_t | miopenGetPReLUBackwardWorkspaceSize (miopenHandle_t handle, miopenTensorDescriptor_t inputDesc, miopenTensorDescriptor_t weightDesc, size_t *sizeInBytes)
| Helper function to query the minimum workspace size required by the PReLU backward call.
miopenStatus_t | miopenPReLUBackward (miopenHandle_t handle, void *workspace, size_t workspaceSizeInBytes, miopenTensorDescriptor_t inputDesc, const void *input, miopenTensorDescriptor_t weightDesc, const void *weight, miopenTensorDescriptor_t doutputDesc, const void *doutput, miopenTensorDescriptor_t dinputDesc, void *dinput, miopenTensorDescriptor_t dweightDesc, void *dweight)
| Execute a PReLU backward layer.

## Detailed Description

## Function Documentation

## ◆ miopenGetPReLUBackwardWorkspaceSize()

miopenStatus_t miopenGetPReLUBackwardWorkspaceSize | ( | miopenHandle_t | handle,
|  | miopenTensorDescriptor_t | inputDesc,
|  | miopenTensorDescriptor_t | weightDesc,
|  | size_t * | sizeInBytes )

Helper function to query the minimum workspace size required by the PReLU backward call.

Parameters

  handle | MIOpen Handle (input)
  inputDesc | Tensor descriptor for input tensor (input)
  weightDesc | Tensor descriptor for weight tensor (input)
  sizeInBytes | Pointer to data to return the minimum workspace size

Returns
  miopenStatus_t

## ◆ miopenPReLUBackward()

miopenStatus_t miopenPReLUBackward | ( | miopenHandle_t | handle,
|  | void * | workspace,
|  | size_t | workspaceSizeInBytes,
|  | miopenTensorDescriptor_t | inputDesc,
|  | const void * | input,
|  | miopenTensorDescriptor_t | weightDesc,
|  | const void * | weight,
|  | miopenTensorDescriptor_t | doutputDesc,
|  | const void * | doutput,
|  | miopenTensorDescriptor_t | dinputDesc,
|  | void * | dinput,
|  | miopenTensorDescriptor_t | dweightDesc,
|  | void * | dweight )

Execute a PReLU backward layer.

Parameters

  handle | MIOpen handle (input)
  workspace | Address of the allocated workspace data (input)
  workspaceSizeInBytes | Size in bytes of the allocated workspace data (input)
  inputDesc | Tensor descriptor for input tensor (input)
  input | Data tensor input (input)
  weightDesc | Tensor descriptor for weight tensor (input)
  weight | Data tensor weight (input)
  doutputDesc | Tensor descriptor for output gradient (input)
  doutput | Gradient of output (input)
  dinputDesc | Tensor descriptor for input gradient (input)
  dinput | Gradient of input (output)
  dweightDesc | Tensor descriptor for weight gradient (input)
  dweight | Gradient of weight (output)