Is there a single function for this:
t = torch.rand(3) #tensor
m = t.mean() #mean
print(t)
print(m)
ma = (t-m) # mean absolute
print(ma)
ama = ma.abs() # make it absolute
print(ama)
mama = ama.mean() # take the mean
print(mama)

# tensor([0.3468, 0.4841, 0.3940])
# tensor(0.4083)
# tensor([-0.0615,  0.0758, -0.0143])
# tensor([0.0615, 0.0758, 0.0143])
# tensor(0.0505)