Depending on the definition of your specific loss function, the reduction may affect the training performance. One of the advantages of reduction=mean is that it makes the update term independent of the batch size. So if you want to use a constant learning rate, you better take the average of loss values. Again, it totally depends on the task and the derivation of the loss function.