title: Normalizing pixel Values in PyTorch
body: <p>I am currently working with the CORnet-Z neural network and I am training it on an alternative version of the ImageNet image dataset.</p>
  <p>I looked through the code and noticed this image value normalization method:</p>
  <pre><code>normalize = torchvision.transforms.Normalize(mean=[0.485, 0.456, 0.406],
                                               std=[0.229, 0.224, 0.225])
  ...
  </code></pre>
  <blockquote>
  <p>And then implemented later in the train, val, and test class:</p>
  </blockquote>
  <pre><code>torchvision.transforms.Compose([
      torchvision.transforms.RandomResizedCrop(256),
      torchvision.transforms.RandomHorizontalFlip(),
      torchvision.transforms.ToTensor(),
      normalize]))
  </code></pre>
  <p>I was wondering if I could rewrite this to just take the RGB pixel values and divide them by 255 to have a scale of 0-1 to work with.</p>
  <p>According to the <code>torchvision.transforms</code> documentation this is not an implemented approach.</p>