AIfES 2  2.0.0
ailayer_leaky_relu_default.h File Reference

Default implementation of the Leaky ReLU layer . More...

Go to the source code of this file.

Data Structures

struct  ailayer_leaky_relu_f32
 Data-type specific Leaky ReLU layer struct for F32 . More...
 

Typedefs

typedef struct ailayer_leaky_relu_f32 ailayer_leaky_relu_f32_t
 

Functions

ailayer_tailayer_leaky_relu_f32_default (ailayer_leaky_relu_f32_t *layer, ailayer_t *input_layer)
 Initializes and connect a Leaky ReLU layer with the F32 default implementation. More...
 

Detailed Description

Default implementation of the Leaky ReLU layer .

Version
2.0alpha

AIfES is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see https://www.gnu.org/licenses/.

Hardware independent implementations of the Leaky ReLU layer in F32 data-type. For more information about the Leaky ReLU layer refer to ailayer_leaky_relu.h.

Function Documentation

◆ ailayer_leaky_relu_f32_default()

ailayer_t* ailayer_leaky_relu_f32_default ( ailayer_leaky_relu_f32_t layer,
ailayer_t input_layer 
)

Initializes and connect a Leaky ReLU layer with the F32 default implementation.

Example: Create the layer structure:

ailayer_leaky_relu_f32_t leaky_relu_layer = {
.alpha = 0.01f
};
Data-type specific Leaky ReLU layer struct for F32 .
Definition: ailayer_leaky_relu_default.h:43
aiscalar_f32_t alpha
Data type-specific parameter used to calculate Leaky ReLU function for input values < 0.
Definition: ailayer_leaky_relu_default.h:45

Example: Initialize and connect the layer:

x = ailayer_leaky_relu_f32_default(&leaky_relu_layer, x);
ailayer_t * ailayer_leaky_relu_f32_default(ailayer_leaky_relu_f32_t *layer, ailayer_t *input_layer)
Initializes and connect a Leaky ReLU layer with the F32 default implementation.
Parameters
*layerthe layer structure to be initialized
*input_layerthe prior layer that provides the input to this Leaky ReLU layer
Returns
the initialized Leaky ReLU layer structure