Open dingjiangang opened 5 years ago
while(1){ image aug = random_augment_image(im, 0, .75, 320, 448, 320, 320); show_image(aug, "aug", 1); free_image(aug);
for(k = 0; k < c; ++k){ for(j = 0; j < h; ++j){ for(i = 0; i < w; ++i){ int dst_index = i + w*j + w*h*k; int src_index = k + c*i + c*w*j; im.data[dst_index] = (float)data[src_index]/255.; } } some variable is not define, so some problem happens;
./src/image.c: In function ‘test_resize’: ./src/image.c:1467:22: error: ‘h’ undeclared (first use in this function) for(j = 0; j < h; ++j){ ^ compilation terminated due to -Wfatal-errors. Makefile:85: recipe for target 'obj/image.o' failed right now, you better not use opencv in compiling the project, it's enough to use the original image load function
while(1){ image aug = random_augment_image(im, 0, .75, 320, 448, 320, 320); show_image(aug, "aug", 1); free_image(aug);
./src/image.c: In function ‘test_resize’: ./src/image.c:1467:22: error: ‘h’ undeclared (first use in this function) for(j = 0; j < h; ++j){ ^ compilation terminated due to -Wfatal-errors. Makefile:85: recipe for target 'obj/image.o' failed