This commit is contained in:
Ghost_Element 2023-09-23 12:33:42 +02:00
parent 8ebb1f7640
commit 6557fbadfc

View file

@ -16,7 +16,7 @@ Neural_Network* new_network(int input_size, int hidden_size, int hidden_amount,
network->output_size = output_size;
network->learning_rate = learning_rate;
Matrix** weights = malloc(sizeof(Matrix)*(hidden_amount + 1));
Matrix** weights = malloc(sizeof(Matrix*)*(hidden_amount + 1));
network->weights = weights;
network->weights[0] = matrix_create(hidden_size, input_size+1);