Expand description
Channel-wise normalisation for CHW image tensors.
Provides the standard (x - mean) / std transformation used before
feeding images to neural networks, applied independently per channel.
Constants§
- IMAGENET_
MEAN - ImageNet per-channel mean (RGB order, values pre-scaled to [0, 1]).
- IMAGENET_
STD - ImageNet per-channel standard deviation (RGB order).
Functions§
- normalize_
chw - Normalize a CHW image channel-wise:
output[c, h, w] = (input[c, h, w] - mean[c]) / std[c].