You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

35 lines
977 B

7 years ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. #ifndef LOCAL_LAYER_H
  2. #define LOCAL_LAYER_H
  3. #include "dn_cuda.h"
  4. #include "image.h"
  5. #include "activations.h"
  6. #include "layer.h"
  7. #include "network.h"
  8. namespace DN{
  9. typedef layer local_layer;
  10. #ifdef GPU
  11. void forward_local_layer_gpu(local_layer layer, network net);
  12. void backward_local_layer_gpu(local_layer layer, network net);
  13. void update_local_layer_gpu(local_layer layer, update_args a);
  14. void push_local_layer(local_layer layer);
  15. void pull_local_layer(local_layer layer);
  16. #endif
  17. local_layer make_local_layer(int batch, int h, int w, int c, int n, int size, int stride, int pad, ACTIVATION activation);
  18. void forward_local_layer(const local_layer layer, network net);
  19. void backward_local_layer(local_layer layer, network net);
  20. void update_local_layer(local_layer layer, update_args a);
  21. void bias_output(float *output, float *biases, int batch, int n, int size);
  22. void backward_bias(float *bias_updates, float *delta, int batch, int n, int size);
  23. };
  24. #endif