From 8c85fcda0dd1d838b9235c278e02e24b5d9bc775 Mon Sep 17 00:00:00 2001 From: stammjo100588 Date: Mon, 17 Nov 2025 12:26:58 +0100 Subject: [PATCH] Kommentare --- imageInput.c | 2 +- matrix.c | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/imageInput.c b/imageInput.c index e9618cc..728da02 100644 --- a/imageInput.c +++ b/imageInput.c @@ -150,7 +150,7 @@ void clearSeries(GrayScaleImageSeries *series) //Funktion gibt ale komponenten series->images = NULL; } - if (series->labels != NULL) //prüfen ob es ein kabel array gibt + if (series->labels != NULL) //prüfen ob es ein label array gibt { free(series->labels); //sonst speicher für alle labels freigeben und pointer auf NULL setzen series->labels = NULL; diff --git a/matrix.c b/matrix.c index 69505ab..701d1c0 100644 --- a/matrix.c +++ b/matrix.c @@ -67,6 +67,8 @@ Matrix add(const Matrix matrix1, const Matrix matrix2) return result; } + //Boradcasting Fall bei neuronlen Netzwerken + // Case B: matrix1 besteht aus (rows x cols) und matrix2 ist (rows x 1) -> einmal alle rows einzeln auf die andere Addieren if (matrix1.rows == matrix2.rows && matrix2.cols == 1 && matrix1.cols > 1) { @@ -84,6 +86,8 @@ Matrix add(const Matrix matrix1, const Matrix matrix2) return result; } + //Broadcasting Fall + // Case C: matrix1 ist (rows x 1) und matrix2 ist (rows x cols) -> einmal alle cols einzeln auf die andere Addieren if (matrix2.rows == matrix1.rows && matrix1.cols == 1 && matrix2.cols > 1) { @@ -138,4 +142,4 @@ Matrix multiply(const Matrix matrix1, const Matrix matrix2) } return result; } -} +} \ No newline at end of file