00001 #ifndef SOFTMAX_LAYER_H 00002 #define SOFTMAX_LAYER_H 00003 #include "layer.h" 00004 #include "network.h" 00005 00006 typedef layer softmax_layer; 00007 00008 void softmax_array(float *input, int n, float temp, float *output); 00009 softmax_layer make_softmax_layer(int batch, int inputs, int groups); 00010 void forward_softmax_layer(const softmax_layer l, network_state state); 00011 void backward_softmax_layer(const softmax_layer l, network_state state); 00012 00013 #ifdef GPU 00014 void pull_softmax_layer_output(const softmax_layer l); 00015 void forward_softmax_layer_gpu(const softmax_layer l, network_state state); 00016 void backward_softmax_layer_gpu(const softmax_layer l, network_state state); 00017 #endif 00018 00019 #endif