typedef struct node{
void *val;
struct node *next;
struct node *prev;
} node;
typedef struct list{
int size;
node *front;
node *back;
} list;
typedef struct matrix{
int rows, cols;
float **vals;
} matrix;
typedef struct{
float x, y, w, h;
} box;
typedef struct{
int id;
float x,y,w,h;
float left, right, top, bottom;
} box_label;
typedef struct{
int w, h;
matrix X; // X.cols = total pixel , rows = batch(64) , vals = each pixel's value (we can find information in data.c's load_data_detection)
matrix y; // y.cols = 5*boxes( boxes default 90 ) , y.rows = batch(64) ,
int shallow;
int *num_boxes;
box **boxes;
} data;
typedef struct detection{
box bbox;
int classes;
float *prob;
float *mask;
float objectness;
int sort_class;
} detection;
검출한 데이터에 대한 정보를 담고 있습니다.
typedef struct{
char *key;
char *val;
int used;
} kvp;
typedef struct{
char *type;
list *options;
}section;
typedef struct size_params{
int batch;
int inputs;
int h;
int w;
int c;
int index;
int time_steps;
network *net;
} size_params;
typedef struct{
float dx, dy, dw, dh;
} dbox;
struct timeval {
long tv_sec; // 1초
long tv_usec; // 1/1000000초
};