If I understand your use case correctly you would like to pass each 32x32 patch into the model and classify it independently? If so you could unfold the patches and permute and view the tensor to create a tensor of [batch_size=num_samples*num_patches, channels, 32, 32] and use it as the new input. Of course you would also need to repeat the target tensor accordingly, since each 256x256 input image is now creating 16 32x32 patches assuming none of them overlap.