Skip to main content
`Ctrl`+`K`

# FUSION

MIOpen: FUSION
Enumerations | Functions
FUSION

## Enumerations

enum | miopenFusionDirection_t { miopenVerticalFusion = 0 , miopenHorizontalFusion = 1 }
| Kernel fusion direction in the network. More...

## Functions

| MIOPEN_DECLARE_OBJECT (miopenFusionPlanDescriptor)
| MIOpen fusion interface.
miopenStatus_t | miopenCreateFusionPlan (miopenFusionPlanDescriptor_t *fusePlanDesc, const miopenFusionDirection_t fuseDirection, const miopenTensorDescriptor_t inputDesc)
| Creates the kenrel fusion plan descriptor object.
miopenStatus_t | miopenDestroyFusionPlan (miopenFusionPlanDescriptor_t fusePlanDesc)
| Destroy the fusion plan descriptor object.
miopenStatus_t | miopenCompileFusionPlan (miopenHandle_t handle, miopenFusionPlanDescriptor_t fusePlanDesc)
| Compiles the fusion plan.
miopenStatus_t | miopenFusionPlanGetOp (miopenFusionPlanDescriptor_t fusePlanDesc, const int op_idx, miopenFusionOpDescriptor_t *op)
| Allows access to the operators in a fusion plan.
miopenStatus_t | miopenFusionPlanGetWorkSpaceSize (miopenHandle_t handle, miopenFusionPlanDescriptor_t fusePlanDesc, size_t *workSpaceSize, miopenConvFwdAlgorithm_t algo)
| Query the workspace size required for the fusion plan.
miopenStatus_t | miopenFusionPlanConvolutionGetAlgo (miopenFusionPlanDescriptor_t fusePlanDesc, const int requestAlgoCount, int *returnedAlgoCount, miopenConvFwdAlgorithm_t *returnedAlgos)
| Returns the supported algorithms for the convolution operator in the Fusion Plan.
miopenStatus_t | miopenFusionPlanConvolutionSetAlgo (miopenFusionPlanDescriptor_t fusePlanDesc, miopenConvFwdAlgorithm_t algo)
| Requests the fusion runtime to choose a particular algorithm for the added convolution operation.
miopenStatus_t | miopenCreateOpConvForward (miopenFusionPlanDescriptor_t fusePlanDesc, miopenFusionOpDescriptor_t *convOp, miopenConvolutionDescriptor_t convDesc, const miopenTensorDescriptor_t wDesc)
| Creates forward convolution operator.
miopenStatus_t | miopenCreateOpActivationForward (miopenFusionPlanDescriptor_t fusePlanDesc, miopenFusionOpDescriptor_t *activFwdOp, miopenActivationMode_t mode)
| Creates a forward activation operator.
miopenStatus_t | miopenCreateOpActivationBackward (miopenFusionPlanDescriptor_t fusePlanDesc, miopenFusionOpDescriptor_t *activBwdOp, miopenActivationMode_t mode)
| Creates a backward activation operator.
miopenStatus_t | miopenCreateOpBiasForward (miopenFusionPlanDescriptor_t fusePlanDesc, miopenFusionOpDescriptor_t *biasOp, const miopenTensorDescriptor_t bDesc)
| Creates a forward bias operator.
miopenStatus_t | miopenCreateOpBatchNormInference (miopenFusionPlanDescriptor_t fusePlanDesc, miopenFusionOpDescriptor_t *bnOp, const miopenBatchNormMode_t bn_mode, const miopenTensorDescriptor_t bnScaleBiasMeanVarDesc)
| Creates a forward inference batch normalization operator.
miopenStatus_t | miopenCreateOpBatchNormForward (miopenFusionPlanDescriptor_t fusePlanDesc, miopenFusionOpDescriptor_t *bnFwdOp, const miopenBatchNormMode_t bn_mode, bool runningMeanVariance)
| Creates a forward training batch normalization operator.
miopenStatus_t | miopenCreateOpBatchNormBackward (miopenFusionPlanDescriptor_t fusePlanDesc, miopenFusionOpDescriptor_t *bnBwdOp, const miopenBatchNormMode_t bn_mode)
| Creates a back propagation batch normalization operator.
miopenStatus_t | miopenCreateOperatorArgs (miopenOperatorArgs_t *args)
| Creates an operator argument object.
miopenStatus_t | miopenDestroyOperatorArgs (miopenOperatorArgs_t args)
| Destroys an operator argument object.
miopenStatus_t | miopenSetOpArgsConvForward (miopenOperatorArgs_t args, const miopenFusionOpDescriptor_t convOp, const void *alpha, const void *beta, const void *w)
| Sets the arguments for forward convolution op.
miopenStatus_t | miopenSetOpArgsActivForward (miopenOperatorArgs_t args, const miopenFusionOpDescriptor_t activFwdOp, const void *alpha, const void *beta, double activAlpha, double activBeta, double activGamma)
| Sets the arguments for forward activation op.
miopenStatus_t | miopenSetOpArgsActivBackward (miopenOperatorArgs_t args, const miopenFusionOpDescriptor_t activBwdOp, const void *alpha, const void *beta, const void *y, const void *reserved, double activAlpha, double activBeta, double activGamma)
| Sets the arguments for backward activation op.
miopenStatus_t | miopenSetOpArgsBatchNormInference (miopenOperatorArgs_t args, const miopenFusionOpDescriptor_t bnOp, const void *alpha, const void *beta, const void *bnScale, const void *bnBias, const void *estimatedMean, const void *estimatedVariance, double epsilon)
| Sets the arguments for inference batch normalization op.
miopenStatus_t | miopenSetOpArgsBatchNormForward (miopenOperatorArgs_t args, const miopenFusionOpDescriptor_t bnOp, const void *alpha, const void *beta, const void *bnScale, const void *bnBias, void *savedMean, void *savedInvVariance, void *runningMean, void *runningVariance, double expAvgFactor, double epsilon)
| Sets the arguments for forward batch normalization op.
miopenStatus_t | miopenSetOpArgsBatchNormBackward (miopenOperatorArgs_t args, const miopenFusionOpDescriptor_t bnOp, const void *alpha, const void *beta, const void *x, const void *bnScale, const void *bnBias, void *resultBnScaleDiff, void *resultBnBiasDiff, const void *savedMean, const void *savedInvVariance)
| Sets the arguments for backward batch normalization op.
miopenStatus_t | miopenSetOpArgsBiasForward (miopenOperatorArgs_t args, const miopenFusionOpDescriptor_t biasOp, const void *alpha, const void *beta, const void *bias)
| Sets the arguments for forward bias op.
miopenStatus_t | miopenExecuteFusionPlan (const miopenHandle_t handle, const miopenFusionPlanDescriptor_t fusePlanDesc, const miopenTensorDescriptor_t inputDesc, const void *input, const miopenTensorDescriptor_t outputDesc, void *output, miopenOperatorArgs_t args)
| Executes the fusion plan. Only compatible with NHWC/NDHWC tensor layouts.
miopenStatus_t | miopenExecuteFusionPlan_v2 (const miopenHandle_t handle, const miopenFusionPlanDescriptor_t fusePlanDesc, const miopenTensorDescriptor_t inputDesc, const void *input, const miopenTensorDescriptor_t outputDesc, void *output, miopenOperatorArgs_t args, void *workspace, size_t workspaceSize)
| Executes the fusion plan with a workspace buffer for layout transformations.

miopenStatus_t

miopenConvolutionBiasActivationForward (miopenHandle_t handle, const void *alpha1, const miopenTensorDescriptor_t xDesc, const void *x, const miopenTensorDescriptor_t wDesc, const void *w, const miopenConvolutionDescriptor_t convDesc, miopenConvFwdAlgorithm_t algo, void *workspace, size_t workspaceSizeInBytes, const void *alpha2, const miopenTensorDescriptor_t zDesc, const void *z, const miopenTensorDescriptor_t biasDesc, const void *bias, const miopenActivationDescriptor_t activationDesc, const miopenTensorDescriptor_t yDesc, void *y)

| Prepares and executes the Convlution+Bias+Activation Fusion.

## Detailed Description

## Enumeration Type Documentation

## ◆ miopenFusionDirection_t

enum miopenFusionDirection_t

Kernel fusion direction in the network.

Enumerator
miopenVerticalFusion | fuses layers vertically, current the only supported mode
miopenHorizontalFusion | fuses layers horizontally, this is unimplemented

## Function Documentation

## ◆ MIOPEN_DECLARE_OBJECT()

MIOPEN_DECLARE_OBJECT | ( | miopenFusionPlanDescriptor |  | ) |

MIOpen fusion interface.

## ◆ miopenCompileFusionPlan()

miopenStatus_t miopenCompileFusionPlan | ( | miopenHandle_t | handle,
|  | miopenFusionPlanDescriptor_t | fusePlanDesc )

Compiles the fusion plan.

Parameters

  handle | MIOpen handle (input)
  fusePlanDesc | A fusion plan descriptor (input)

Returns
  miopenStatus_t

## ◆ miopenConvolutionBiasActivationForward()

miopenStatus_t miopenConvolutionBiasActivationForward | ( | miopenHandle_t | handle,
|  | const void * | alpha1,
|  | const miopenTensorDescriptor_t | xDesc,
|  | const void * | x,
|  | const miopenTensorDescriptor_t | wDesc,
|  | const void * | w,
|  | const miopenConvolutionDescriptor_t | convDesc,
|  | miopenConvFwdAlgorithm_t | algo,
|  | void * | workspace,
|  | size_t | workspaceSizeInBytes,
|  | const void * | alpha2,
|  | const miopenTensorDescriptor_t | zDesc,
|  | const void * | z,
|  | const miopenTensorDescriptor_t | biasDesc,
|  | const void * | bias,
|  | const miopenActivationDescriptor_t | activationDesc,
|  | const miopenTensorDescriptor_t | yDesc,
|  | void * | y )

Prepares and executes the Convlution+Bias+Activation Fusion.

Parameters

  handle | MIOpen handle (input)
  alpha1 | floating point scaling factor, allocated on the host (input)
  xDesc | Tensor descriptor for input data tensor x (input)
  x | Data tensor x (input)
  wDesc | Tensor descriptor for weight tensor w (input)
  w | Weights tensor w (input)
  convDesc | Convolution layer descriptor (input)
  algo | Algorithm selected (inputs)
  workspace | Pointer to workspace required (input)
  workspaceSizeInBytes | Size of the memory in bytes pointed to by workSpace above
  alpha2 | floating point scaling factor, allocated on the host (input)
  zDesc | Tensor descriptor for tensor z (input)
  z | Data tensor z (input)
  biasDesc | Tensor descriptor for input data tensor x (input)
  bias | Data tensor bias (input)
  activationDesc | Activation descriptor that specifies the activation mode
  yDesc | Tensor descriptor for output data tensor y (input)
  y | Output data tensor

## ◆ miopenCreateFusionPlan()

miopenStatus_t miopenCreateFusionPlan | ( | miopenFusionPlanDescriptor_t * | fusePlanDesc,
|  | const miopenFusionDirection_t | fuseDirection,
|  | const miopenTensorDescriptor_t | inputDesc )

Creates the kenrel fusion plan descriptor object.

Parameters

  fusePlanDesc | Pointer to a fusion plan (output)
  fuseDirection | Horizontal or Vertical fusion (input)
  inputDesc | Descriptor to tensor for the input (input)

Returns
  miopenStatus_t

## ◆ miopenCreateOpActivationBackward()

miopenStatus_t miopenCreateOpActivationBackward | ( | miopenFusionPlanDescriptor_t | fusePlanDesc,
|  | miopenFusionOpDescriptor_t * | activBwdOp,
|  | miopenActivationMode_t | mode )

Creates a backward activation operator.

Parameters

  fusePlanDesc | A fusion plan descriptor (input)
  activBwdOp | Pointer to an operator type (output)
  mode | Activation version (input)

Returns
  miopenStatus_t

## ◆ miopenCreateOpActivationForward()

miopenStatus_t miopenCreateOpActivationForward | ( | miopenFusionPlanDescriptor_t | fusePlanDesc,
|  | miopenFusionOpDescriptor_t * | activFwdOp,
|  | miopenActivationMode_t | mode )

Creates a forward activation operator.

Parameters

  fusePlanDesc | A fusion plan descriptor (input)
  activFwdOp | Pointer to an operator type (output)
  mode | Activation version (input)

Returns
  miopenStatus_t

## ◆ miopenCreateOpBatchNormBackward()

miopenStatus_t miopenCreateOpBatchNormBackward | ( | miopenFusionPlanDescriptor_t | fusePlanDesc,
|  | miopenFusionOpDescriptor_t * | bnBwdOp,
|  | const miopenBatchNormMode_t | bn_mode )

Creates a back propagation batch normalization operator.

Parameters

  fusePlanDesc | A fusion plan descriptor (input)
  bnBwdOp | Pointer to an operator type (output)
  bn_mode | Batch normalization layer mode (input)

Returns
  miopenStatus_t

## ◆ miopenCreateOpBatchNormForward()

miopenStatus_t miopenCreateOpBatchNormForward | ( | miopenFusionPlanDescriptor_t | fusePlanDesc,
|  | miopenFusionOpDescriptor_t * | bnFwdOp,
|  | const miopenBatchNormMode_t | bn_mode,
|  | bool | runningMeanVariance )

Creates a forward training batch normalization operator.

Parameters

  fusePlanDesc | A fusion plan descriptor (input)
  bnFwdOp | Pointer to an operator type (output)
  bn_mode | Batch normalization layer mode (input)
  runningMeanVariance | Toggles whether or not to save population statistics for inference; batch statistic are required (input)

Returns
  miopenStatus_t

## ◆ miopenCreateOpBatchNormInference()

miopenStatus_t miopenCreateOpBatchNormInference | ( | miopenFusionPlanDescriptor_t | fusePlanDesc,
|  | miopenFusionOpDescriptor_t * | bnOp,
|  | const miopenBatchNormMode_t | bn_mode,
|  | const miopenTensorDescriptor_t | bnScaleBiasMeanVarDesc )

Creates a forward inference batch normalization operator.

Parameters

  fusePlanDesc | A fusion plan descriptor (input)
  bnOp | Pointer to an operator type (output)
  bn_mode | Batch normalization layer mode (input)
  bnScaleBiasMeanVarDesc | Gamma, beta, mean, variance tensor descriptor (input)

Returns
  miopenStatus_t

## ◆ miopenCreateOpBiasForward()

miopenStatus_t miopenCreateOpBiasForward | ( | miopenFusionPlanDescriptor_t | fusePlanDesc,
|  | miopenFusionOpDescriptor_t * | biasOp,
|  | const miopenTensorDescriptor_t | bDesc )

Creates a forward bias operator.

Parameters

  fusePlanDesc | A fusion plan descriptor (input)
  biasOp | Pointer to an operator type (output)
  bDesc | bias tensor descriptor (input)

Returns
  miopenStatus_t

## ◆ miopenCreateOpConvForward()

miopenStatus_t miopenCreateOpConvForward | ( | miopenFusionPlanDescriptor_t | fusePlanDesc,
|  | miopenFusionOpDescriptor_t * | convOp,
|  | miopenConvolutionDescriptor_t | convDesc,
|  | const miopenTensorDescriptor_t | wDesc )

Creates forward convolution operator.

Parameters

  fusePlanDesc | A fusion plan descriptor (input)
  convOp | Pointer to an operator type (output)
  convDesc | Convolution layer descriptor (input)
  wDesc | Descriptor for the weights tensor (input)

Returns
  miopenStatus_t

## ◆ miopenCreateOperatorArgs()

miopenStatus_t miopenCreateOperatorArgs | ( | miopenOperatorArgs_t * | args | ) |

Creates an operator argument object.

Parameters

  args | Pointer to an operator argument type (output)

Returns
  miopenStatus_t

## ◆ miopenDestroyFusionPlan()

miopenStatus_t miopenDestroyFusionPlan | ( | miopenFusionPlanDescriptor_t | fusePlanDesc | ) |

Destroy the fusion plan descriptor object.

Parameters

  fusePlanDesc | A fusion plan descriptor type

Returns
  miopenStatus_t

## ◆ miopenDestroyOperatorArgs()

miopenStatus_t miopenDestroyOperatorArgs | ( | miopenOperatorArgs_t | args | ) |

Destroys an operator argument object.

Parameters

  args | An operator argument type (output)

Returns
  miopenStatus_t

## ◆ miopenExecuteFusionPlan()

miopenStatus_t miopenExecuteFusionPlan | ( | const miopenHandle_t | handle,
|  | const miopenFusionPlanDescriptor_t | fusePlanDesc,
|  | const miopenTensorDescriptor_t | inputDesc,
|  | const void * | input,
|  | const miopenTensorDescriptor_t | outputDesc,
|  | void * | output,
|  | miopenOperatorArgs_t | args )

Executes the fusion plan. Only compatible with NHWC/NDHWC tensor layouts.

Deprecated
  This function is deprecated and may be removed in a future release. Use miopenExecuteFusionPlan_v2 instead.

Parameters

  handle | MIOpen handle (input)
  fusePlanDesc | fused plan descriptor (input)
  inputDesc | Descriptor of the input tensor (input)
  input | Source data tensor (input)
  outputDesc | Decriptor of the output tensor (input)
  output | Destination data tensor (output)
  args | An argument object of the fused kernel (input)

Returns
  miopenStatus_t

## ◆ miopenExecuteFusionPlan_v2()

miopenStatus_t miopenExecuteFusionPlan_v2 | ( | const miopenHandle_t | handle,
|  | const miopenFusionPlanDescriptor_t | fusePlanDesc,
|  | const miopenTensorDescriptor_t | inputDesc,
|  | const void * | input,
|  | const miopenTensorDescriptor_t | outputDesc,
|  | void * | output,
|  | miopenOperatorArgs_t | args,
|  | void * | workspace,
|  | size_t | workspaceSize )

Executes the fusion plan with a workspace buffer for layout transformations.

Parameters

  handle | MIOpen handle (input)
  fusePlanDesc | fused plan descriptor (input)
  inputDesc | Descriptor of the input tensor (input)
  input | Source data tensor (input)
  outputDesc | Decriptor of the output tensor (input)
  output | Destination data tensor (output)
  args | An argument object of the fused kernel (input)
  workspace | A pointer to an intermediate workspace (input)
  workspaceSize | Size of the memory in bytes pointed to by workSpace above (input)

Returns
  miopenStatus_t

## ◆ miopenFusionPlanConvolutionGetAlgo()

miopenStatus_t miopenFusionPlanConvolutionGetAlgo | ( | miopenFusionPlanDescriptor_t | fusePlanDesc,
|  | const int | requestAlgoCount,
|  | int * | returnedAlgoCount,
|  | miopenConvFwdAlgorithm_t * | returnedAlgos )

Returns the supported algorithms for the convolution operator in the Fusion Plan.

A Convolution operator in a fusion plan may be implemented by different algorithms representing different tradeoffs of memory and performance. The returned list of algorithms is sorted in decreasing order of priority. Therefore, if the user does not request an algorithm to be set using the miopenFusionPlanConvolutionSetAlgo call, the first algorithm in the list would be used to execute the convolution in the fusion plan. Moreover this call must be immediately preceded by the miopenCreateOpConvForward call for the op in question.

Parameters

  fusePlanDesc | A fusion plan descriptor (input)
  requestAlgoCount | Number of algorithms to return (input)
  returnedAlgoCount | The actual number of returned algorithms; always be less than equal to requestAlgoCount (output)
  returnedAlgos | Pointer to the list of supported algorithms

Returns
  miopenStatus_t

## ◆ miopenFusionPlanConvolutionSetAlgo()

miopenStatus_t miopenFusionPlanConvolutionSetAlgo | ( | miopenFusionPlanDescriptor_t | fusePlanDesc,
|  | miopenConvFwdAlgorithm_t | algo )

Requests the fusion runtime to choose a particular algorithm for the added convolution operation.

Please see the description for miopenFusionPlanConvolutionGetAlgo

Parameters

  fusePlanDesc | A fusion plan descriptor (input)
  algo | Requested algorithm for the convolution operator (input)

Returns
  miopenStatus_t

## ◆ miopenFusionPlanGetOp()

miopenStatus_t miopenFusionPlanGetOp | ( | miopenFusionPlanDescriptor_t | fusePlanDesc,
|  | const int | op_idx,
|  | miopenFusionOpDescriptor_t * | op )

Allows access to the operators in a fusion plan.

This api call does bounds checking on the supplied op_idx and would return miopenStatusError if the index is out of bounds

Parameters

  fusePlanDesc | A fusion plan descriptor (input)
  op_idx | Index of the required operator in the fusion plan, in the order of insertion
  op | returned pointer to the operator

Returns
  miopenStatus_t

## ◆ miopenFusionPlanGetWorkSpaceSize()

miopenStatus_t miopenFusionPlanGetWorkSpaceSize | ( | miopenHandle_t | handle,
|  | miopenFusionPlanDescriptor_t | fusePlanDesc,
|  | size_t * | workSpaceSize,
|  | miopenConvFwdAlgorithm_t | algo )

Query the workspace size required for the fusion plan.

Parameters

  handle | MIOpen handle (input)
  fusePlanDesc | A fusion plan descriptor (input)
  workSpaceSize | Pointer to memory to return size in bytes (output)
  algo | Algorithm selected (inputs)

Returns
  miopenStatus_t

## ◆ miopenSetOpArgsActivBackward()

miopenStatus_t miopenSetOpArgsActivBackward | ( | miopenOperatorArgs_t | args,
|  | const miopenFusionOpDescriptor_t | activBwdOp,
|  | const void * | alpha,
|  | const void * | beta,
|  | const void * | y,
|  | const void * | reserved,
|  | double | activAlpha,
|  | double | activBeta,
|  | double | activGamma )

Sets the arguments for backward activation op.

Parameters

  args | An arguments object type (output)
  activBwdOp | Activation backwards operator (input)
  alpha | Floating point scaling factor, allocated on the host (input)
  beta | Floating point shift factor, allocated on the host (input)
  y | Data tensor y, output of activations in the forward direction (input)
  reserved | Data tensor reserved memory space; currently should be nullptr (input)
  activAlpha | Double precision activation parameter which depends on activation mode (input)
  activBeta | Double precision activation parameter which depends on activation mode (input)
  activGamma | Double precision activation parameter which depends on activation mode (input)

Returns
  miopenStatus_t

## ◆ miopenSetOpArgsActivForward()

miopenStatus_t miopenSetOpArgsActivForward | ( | miopenOperatorArgs_t | args,
|  | const miopenFusionOpDescriptor_t | activFwdOp,
|  | const void * | alpha,
|  | const void * | beta,
|  | double | activAlpha,
|  | double | activBeta,
|  | double | activGamma )

Sets the arguments for forward activation op.

Parameters

  args | An arguments object type (output)
  activFwdOp | Activation backwards operator (input)
  alpha | Floating point scaling factor, allocated on the host (input)
  beta | Floating point shift factor, allocated on the host (input)
  activAlpha | Double precision activation parameter which depends on activation mode (input)
  activBeta | Double precision activation parameter which depends on activation mode (input)
  activGamma | Double precision activation parameter which depends on activation mode (input)

Returns
  miopenStatus_t

## ◆ miopenSetOpArgsBatchNormBackward()

miopenStatus_t miopenSetOpArgsBatchNormBackward | ( | miopenOperatorArgs_t | args,
|  | const miopenFusionOpDescriptor_t | bnOp,
|  | const void * | alpha,
|  | const void * | beta,
|  | const void * | x,
|  | const void * | bnScale,
|  | const void * | bnBias,
|  | void * | resultBnScaleDiff,
|  | void * | resultBnBiasDiff,
|  | const void * | savedMean,
|  | const void * | savedInvVariance )

Sets the arguments for backward batch normalization op.

Parameters

  args | An arguments object type (output)
  bnOp | Batch normalization forward operator (input)
  alpha | Floating point scaling factor, allocated on the host (input)
  beta | Floating point shift factor, allocated on the host (input)
  x | Pointer to the forward input tensor memory (input)
  bnScale | Pointer to the gamma tensor memory (input)
  bnBias | Pointer to the beta tensor memory (input)
  resultBnScaleDiff | Pointer to the gamma gradient tensor memory (output)
  resultBnBiasDiff | Pointer to the beta gradient tensor memory (output)
  savedMean | Pointer to batch mean memory (input)
  savedInvVariance | Pointer to batch inverse variance memory (input)

Returns
  miopenStatus_t

## ◆ miopenSetOpArgsBatchNormForward()

miopenStatus_t miopenSetOpArgsBatchNormForward | ( | miopenOperatorArgs_t | args,
|  | const miopenFusionOpDescriptor_t | bnOp,
|  | const void * | alpha,
|  | const void * | beta,
|  | const void * | bnScale,
|  | const void * | bnBias,
|  | void * | savedMean,
|  | void * | savedInvVariance,
|  | void * | runningMean,
|  | void * | runningVariance,
|  | double | expAvgFactor,
|  | double | epsilon )

Sets the arguments for forward batch normalization op.

Parameters

  args | An arguments object type (output)
  bnOp | Batch normalization forward operator (input)
  alpha | Floating point scaling factor, allocated on the host (input)
  beta | Floating point shift factor, allocated on the host (input)
  bnScale | Pointer to the gamma tensor memory (input)
  bnBias | Pointer to the beta tensor memory (input)
  savedMean | Pointer to batch mean memory (input)
  savedInvVariance | Pointer to batch inverse variance memory (input)
  runningMean | Pointer to population mean memory (input)
  runningVariance | Pointer to population variance memory (input)
  expAvgFactor | Scalar value for control of population statistics (input)
  epsilon | Scalar value for numerical stability (input)

Returns
  miopenStatus_t

## ◆ miopenSetOpArgsBatchNormInference()

miopenStatus_t miopenSetOpArgsBatchNormInference | ( | miopenOperatorArgs_t | args,
|  | const miopenFusionOpDescriptor_t | bnOp,
|  | const void * | alpha,
|  | const void * | beta,
|  | const void * | bnScale,
|  | const void * | bnBias,
|  | const void * | estimatedMean,
|  | const void * | estimatedVariance,
|  | double | epsilon )

Sets the arguments for inference batch normalization op.

Parameters

  args | An arguments object type (output)
  bnOp | Batch normalization inference operator (input)
  alpha | Floating point scaling factor, allocated on the host (input)
  beta | Floating point shift factor, allocated on the host (input)
  bnScale | Pointer to the gamma tensor memory (input)
  bnBias | Pointer to the beta tensor memory (input)
  estimatedMean | Pointer to population mean memory (input)
  estimatedVariance | Pointer to population variance memory (input)
  epsilon | Scalar value for numerical stability (input)

Returns
  miopenStatus_t

## ◆ miopenSetOpArgsBiasForward()

miopenStatus_t miopenSetOpArgsBiasForward | ( | miopenOperatorArgs_t | args,
|  | const miopenFusionOpDescriptor_t | biasOp,
|  | const void * | alpha,
|  | const void * | beta,
|  | const void * | bias )

Sets the arguments for forward bias op.

Parameters

  args | An arguments object type (output)
  biasOp | Forward bias operator (input)
  alpha | Floating point scaling factor, allocated on the host (input)
  beta | Floating point shift factor, allocated on the host (input)
  bias | Pointer to the forward bias input tensor memory (input)

Returns
  miopenStatus_t

## ◆ miopenSetOpArgsConvForward()

miopenStatus_t miopenSetOpArgsConvForward | ( | miopenOperatorArgs_t | args,
|  | const miopenFusionOpDescriptor_t | convOp,
|  | const void * | alpha,
|  | const void * | beta,
|  | const void * | w )

Sets the arguments for forward convolution op.

Parameters

  args | An arguments object type (output)
  convOp | Forward convolution operator (input)
  alpha | Floating point scaling factor, allocated on the host (input)
  beta | Floating point shift factor, allocated on the host (input)
  w | Pointer to tensor memory (input)

Returns
  miopenStatus_t