| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| character(len=*), | private, | parameter | :: | activation_name(*) | = | [character(len("sigmoid"))::"gelu", "relu", "sigmoid", "step", "swish"] |
| enumerator | :: | gelu | = | 1 | |
| enumerator | :: | relu | = | 2 | |
| enumerator | :: | sigmoid | = | 3 | |
| enumerator | :: | step | = | 4 | |
| enumerator | :: | swish | = | 5 |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| integer(kind=c_int), | intent(in) | :: | selection |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| character(len=*), | intent(in) | :: | name |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(activation_t), | intent(in) | :: | self | |||
| real, | intent(in) | :: | x |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(activation_t), | intent(in) | :: | self | |||
| real, | intent(in) | :: | x |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(activation_t), | intent(in) | :: | self | |||
| double precision, | intent(in) | :: | x |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(activation_t), | intent(in) | :: | self | |||
| double precision, | intent(in) | :: | x |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(activation_t), | intent(in) | :: | self | |||
| type(activation_t), | intent(in) | :: | rhs |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(activation_t), | intent(in) | :: | self |
| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| integer(kind=c_int), | private | :: | selection_ | = | sigmoid |
| private elemental, module function construct_from_component (selection) | |
| private elemental, module function construct_from_name (name) |
| generic, public :: differentiate => default_real_differentiate, double_precision_differentiate | |
| generic, public :: evaluate => default_real_evaluate, double_precision_evaluate | |
| procedure, public, non_overridable :: function_name | |
| generic, public :: operator(==) => equals | |
| procedure, private, non_overridable :: default_real_differentiate | |
| procedure, private, non_overridable :: default_real_evaluate | |
| procedure, private, non_overridable :: double_precision_differentiate | |
| procedure, private, non_overridable :: double_precision_evaluate | |
| procedure, private :: equals |