This is one way, but I doubt it is what you wanted as you weren’t very specific.
min_v = torch.min(vector)
range_v = torch.max(vector) - min_v
if range_v > 0:
    normalised = (vector - min) / range_v
else:
    normalised = torch.zeros(vector.size())