That is because you need floatTensors to pass into SmoothL1. L1 loss is for regression, it can only be done for continuous tensors like floatTensors. IntTensors or LongTensors are not continuous (they are discrete).
So your code should be
age_loss = F.smooth_l1_loss(age_expect.float(), age_targets.float())