Hi,
I have a batch of tensor. How can I efficiently normalize it to the range of [0, 1].
For example,
The tensor is A with dimension [batch=25, height=3, width=3]. I can use for-loop to finish this normalization like
# batchwise normalize to [0, 1] along with height and width
for i in range(batch):          
    min_ele = torch.min(A[i])
    A[i] -= min_ele
    A[i] /= torch.max(A[i])

However, this solution is low. Is there any efficient way?
Thanks!