moved datatypes to headerfile

This commit is contained in:
gurkenhabicht 2018-05-19 21:01:28 +02:00
parent 45804b1916
commit 0651b58bac
4 changed files with 36 additions and 34 deletions

View File

@ -20,19 +20,6 @@ Created by Stefan Friese on 26.04.2018
typedef SSIZE_T ssize_t;
#endif
typedef struct {
double *weights;
unsigned windowSize;
unsigned samplesCount;
double learnrate;
} mldata_t;
enum fileHeader{
LOCAL_MEAN_HEADER,
DIRECT_PREDECESSOR_HEADER,
DIFFERENTIAL_PREDECESSOR_HEADER
};
double *xSamples;
mldata_t *mlData = NULL; // Machine learning
point_t *points = NULL; // Graphing

View File

@ -1,6 +1,14 @@
/* * machine learning * */
typedef struct {
double *weights;
unsigned windowSize;
unsigned samplesCount;
double learnrate;
} mldata_t;
/* *svg graph building* */
typedef struct {
typedef struct { // Axis x,y
double xVal[7];
double yVal[7];
}point_t;
@ -10,12 +18,13 @@ typedef struct {
unsigned char red, green, blue;
}colorChannel_t;
typedef struct {
typedef struct { // Storage for image data
int x, y;
colorChannel_t *data;
}imagePixel_t;
}imagePixel_t;
enum fileSuffix_t{ // used in conjunction with mkFileName()
/** file handling* */
enum fileSuffix_t{ // Used in conjunction with mkFileName()
PURE_WEIGHTS,
USED_WEIGHTS,
DIRECT_PREDECESSOR,
@ -25,4 +34,9 @@ enum fileSuffix_t{ // used in conjunction with mkFileName()
DIFFERENTIAL_PREDECESSOR
};
enum fileHeader{
LOCAL_MEAN_HEADER,
DIRECT_PREDECESSOR_HEADER,
DIFFERENTIAL_PREDECESSOR_HEADER
};

View File

@ -20,19 +20,6 @@ Created by Stefan Friese on 26.04.2018
typedef SSIZE_T ssize_t;
#endif
typedef struct {
double *weights;
unsigned windowSize;
unsigned samplesCount;
double learnrate;
} mldata_t;
enum fileHeader{
LOCAL_MEAN_HEADER,
DIRECT_PREDECESSOR_HEADER,
DIFFERENTIAL_PREDECESSOR_HEADER
};
double *xSamples;
mldata_t *mlData = NULL; // Machine learning
point_t *points = NULL; // Graphing

View File

@ -1,6 +1,14 @@
/* * machine learning * */
typedef struct {
double *weights;
unsigned windowSize;
unsigned samplesCount;
double learnrate;
} mldata_t;
/* *svg graph building* */
typedef struct {
typedef struct { // Axis x,y
double xVal[7];
double yVal[7];
}point_t;
@ -10,12 +18,13 @@ typedef struct {
unsigned char red, green, blue;
}colorChannel_t;
typedef struct {
typedef struct { // Storage for image data
int x, y;
colorChannel_t *data;
}imagePixel_t;
}imagePixel_t;
enum fileSuffix_t{ // used in conjunction with mkFileName()
/** file handling* */
enum fileSuffix_t{ // Used in conjunction with mkFileName()
PURE_WEIGHTS,
USED_WEIGHTS,
DIRECT_PREDECESSOR,
@ -25,4 +34,9 @@ enum fileSuffix_t{ // used in conjunction with mkFileName()
DIFFERENTIAL_PREDECESSOR
};
enum fileHeader{
LOCAL_MEAN_HEADER,
DIRECT_PREDECESSOR_HEADER,
DIFFERENTIAL_PREDECESSOR_HEADER
};