#ifndef PREPROCESSING_H #define PREPROCESSING_H typedef struct feature Feature; struct feature { float value; Feature *next_feature; }; typedef struct onehotlabel OneHotLabel; struct onehotlabel { float value; OneHotLabel *next; }; typedef enum type Type; enum type { TRAIN = 0 , TEST = 1 , VALID = 2 }; typedef struct sample Sample; struct sample { Feature *first_feature; OneHotLabel *first_hot; Sample *next_sample; Type t; }; typedef struct data Data; struct data { Sample *first_sample; Sample *last_sample; int size; }; Feature *init_feature(float value); OneHotLabel *init_onehotlabel(float value); Sample *init_sample(); Data *init_data(); void add_sample_to_data(Data *data, Sample *sample); void destroy_sample(Sample *sample); void destroy_data(Data *data); Data *csv_to_samples(char *path_to_csv, int n_features, char *features_separator, float train_percent, char *apply_onthot_encode, int n_classes); void print_data(const Data *data); #endif