| 51 | }; |
| 52 | |
| 53 | static inline float activation(float input, int activation) |
| 54 | { |
| 55 | if(activation >= 0) |
| 56 | { |
| 57 | if(input < 0 && activation != 1) |
| 58 | input = 0; |
| 59 | if(activation == 1 && input > 1) |
| 60 | input = 1; |
| 61 | if(activation == 6 && input > 6) |
| 62 | input = 6; |
| 63 | if(activation == 1 && input < -1) |
| 64 | input = -1; |
| 65 | } |
| 66 | |
| 67 | return input; |
| 68 | } |
| 69 | |
| 70 | typedef int (*ref_conv_kernel_t)(const void* input, void* output, const void* kernel, const void* bias, op_data* param); |
| 71 |
no outgoing calls
no test coverage detected