Here, __getittem__ loads a single sample.
Once you call the dataloader, it will load the N amount of samples you set by calling N times __getittem__ and stacking the tensors in a smart way. This is what they call Automatic Batching.
You can disable that, setting the dataloader in batch mode. This is, __getitem__ will no longer load a sample but a batch (ofc you have to code the stacking and so own your self). This will just convert numpy arrays in pytorch tensors but that’s all.  More info here: torch.utils.data — PyTorch 1.10.0 documentation 1
Scroll down until you see Loading Batched and Non-Batched Data and ** Disable automatic batching**