generated from freudenreichan/info2Praktikum-NeuronalesNetz
NN-Tests: Dateikopf als Konstante FILE_HEADER_STRING
Konstante mit dem Tag des Netzwerk-Formats (__info2_neural_network_file_format__), nicht dem des Bildformats, damit loadModel die Testdatei akzeptiert. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
9356a19fb0
commit
912ec986f3
1 file changed
+3
-3
@@ -4,15 +4,15 @@
|
||||
#include <math.h>
|
||||
#include "unity.h"
|
||||
#include "neuralNetwork.h"
|
||||
|
||||
#define FILE_HEADER_STRING "__info2_neural_network_file_format__"
|
||||
|
||||
static void prepareNeuralNetworkFile(const char *path, const NeuralNetwork nn)
|
||||
{
|
||||
FILE *file = fopen(path, "wb");
|
||||
|
||||
|
||||
if(file != NULL)
|
||||
{
|
||||
const char *fileTag = "__info2_neural_network_file_format__";
|
||||
const char *fileTag = FILE_HEADER_STRING;
|
||||
|
||||
fwrite(fileTag, sizeof(char), strlen(fileTag), file);
|
||||
|
||||
|
||||
Reference in new issue
Block a user