Fixed resize of network for low resolution network like 128x128

This commit is contained in:
AlexeyAB
2018-05-17 17:02:42 +03:00
parent e39d101109
commit 9ba0beb413

View File

@ -132,6 +132,8 @@ void train_detector(char *datacfg, char *cfgfile, char *weightfile, int *gpus, i
int random_val = rand() % 12;
int dim_w = (random_val + (init_w / 32 - 5)) * 32; // +-160
int dim_h = (random_val + (init_h / 32 - 5)) * 32; // +-160
if (dim_w < 32) dim_w = 32;
if (dim_h < 32) dim_h = 32;
printf("%d x %d \n", dim_w, dim_h);
args.w = dim_w;