DataBunch using Size parameter

data = ImageDataBunch.from_name_re(path_img, fnames, pat, ds_tfms=get_transforms() ,bs=bs).normalize(imagenet_stats)

learn = cnn_learner(data, models.alexnet,metrics=error_rate)

this is my code cells for image classifer model training. I didn’t define size parameter for Image Data Bunch because my images are 2046x2056 resolution quality . When ı did it like that on kaggle it is take 9 hours to training. So am ı have to add size parameter .What is size parameter changes and working for ? Any suggestion for what ı should to do ? Thanks

The parameter size changes the image size via downscaling of the original images. Hence, using a smaller resolution makes training faster.

Is it changes model performance ?Because I will test it again with 2046x2056 resolution images.

Yes, it will. Maybe watch the fastai video lessons, then you will understand what is going on in more detail.

https://course.fast.ai/

I whatched them maybe 3 times but there is no extra info about performance changing. If it will decrase performance, making training faster is useless for me .

Can I change size with rate ? something like size = 1023x1028

Lesson 3 the Camvid part contains everything you need (including explanations).

thanks ı will check it out

Decreasing the image size will surely affect the performance, but that performance loss should not be that much. You can just start from a smaller size and then gradually increase the size.