Thanks for the question. Yes, that line of code is just normalizing the MPS to have norm equal to 1. The reason it only accesses the first MPS tensor (.ref(1)) is that the applyMPO function guarantees that the returned MPS will be in right-canonical gauge, so that the norm of the whole MPS equals the norm of the first MPS tensor.
The expression of the paper is the norm that the (unnormalized) METTS would have if one did the imaginary time evolution all in one big step. However, here the expH MPO is just for a step of tau, and so the norm afterward will be different (the same expression but with tau instead of beta). Dividing it off at every step or dividing it off at the very end will give the same final normalized state.
Hope that helps,