HolyFuckItsAlive #13

Merged
jastornig merged 105 commits from Delta-Error-Test into main 2023-09-23 22:27:54 +02:00
2 changed files with 13 additions and 0 deletions
Showing only changes of commit e86009ecf5 - Show all commits

View file

@ -21,9 +21,21 @@ Neural_Network* new_network(int input_size, int hidden_size, int output_size, do
network->bias_3 = matrix_create(hidden_size, 1);
//network.bias_output = matrix_create(output_size, 1); // do we need it?
return network;
}
void randomize_network(Neural_Network* network, int scope){
matrix_randomize(network->weights_1, scope);
matrix_randomize(network->weights_2, scope);
matrix_randomize(network->weights_3, scope);
matrix_randomize(network->weights_output, scope);
matrix_randomize(network->bias_1, scope);
matrix_randomize(network->bias_2, scope);
matrix_randomize(network->bias_3, scope);
}
//void print_network(Neural_Network* network){};
void free_network(Neural_Network* network){

View file

@ -29,6 +29,7 @@ static const int MAX_BYTES = 100;
Neural_Network* new_network(int input_size, int hidden_size, int output_size, double learning_rate);
//void print_network(Neural_Network* network);
void randomize_network(Neural_Network* network, int scope);
void free_network(Neural_Network* network);
void save_network(Neural_Network* network);