Merge remote-tracking branch 'origin/Development' into Development

This commit is contained in:
Thomas 2023-09-22 10:03:41 +02:00
commit 06b87520b5
2 changed files with 18 additions and 10 deletions

View file

@ -383,13 +383,13 @@ double square(double input) {
return input * input;
}
double loss_function(Matrix* output_matrix, int image_label) {
Matrix* temp = matrix_copy(output_matrix);
temp->numbers[1, image_label] -= 1;
apply(square, temp);
matrix_free(temp);
return matrix_sum(temp);;
}
//double loss_function(Matrix* output_matrix, int image_label) {
// Matrix* temp = matrix_copy(output_matrix);
//
// temp->numbers[1][image_label] -= 1;
// apply(square, temp);
//
// matrix_free(temp);
//
// return matrix_sum(temp);;
//}