agrpz:

However, using different prefetch_factor values did not absolutely change the used GPU memory


I wouldn’t expect it to change the GPU memory usage, since the data is preloaded on the host and each batch is pushed to the device in the training loop in the common use case. This also seems to be your workflow, as I cannot see any GPU usage in the  MRIDataset.