Calculating mean and stdev of entire dataset for transforms.Normalize() function

train_dataset = torchvision.datasets.ImageFolder(
transforms.Normalize(mean=[3 mean values of RGB channels],
std=[3 stdev values of RGB channels])
My image size is 398, 398 (Height, Width). I am resizing it to 224, 224 (Height, Width). I need to pass mean and stddev values of entire image dataset to transforms.Normalize() function. I am using image width and height in number of pixels while calculating mean and stdev of entire dataset. shall I use original size i.e. 398, 398 pixels or 224, 224 pixels in mean and stdev calculation of entire dataset.