I am trying to solve a multiclass classification problem in which I have over 7000 pictures with labels. While preprocessing the data, I use a torchvision.Compose with Normalize() function included at the end. Said function performs the following operation for all the three channels:

Which is convenient for many cases but what I need is to standarize my data, that is to say, make it with 0 mean and variance 1. I cannot seem to find an easy way to do this without using other libraries.
I am not providing code as my problem is not related to a specific error but more towards a general lack of knowledge that could not be solved by searching on this forum/Stack Overflow/torchvision documentation.