UNet kernel_size=5 vs kernel_size=3

Hi all,

I am working on an image instance segmentation project. I have the exact same UNet model for kernel_size=3 (with padding=1) and for kernel_size=5 (with padding=2). I would expect that the model corresponding to the larger kernel required more memory (and computation time) due to the hight increase of number of trainable parameters, but this seems not to be happening significantly.

May my model be correct and not necessarily require more memory? Thank you in advance,

MLB9

The increase in memory usage between a kernel size of 3 and 5 might be tiny as the majority of the memory usage would come from the intermediate forward activations, which might have the same shape.

1 Like