Count the number of cards in your library. Your life total becomes that number.
In a Two-Headed Giant game, Invincible Hymn will essentially set your team’s life total to the number of cards in your library. For example, suppose your team has 8 life and you have thirty cards in your library. Your life total (being the same as your team’s life total) changes from 8 life to 30 life, for a net gain of 22 life. Your team’s life total becomes 30 (22 + 8).
Invincible Hymn checks the number of cards in your library just once: when it resolves. It doesn’t continuously modify your life total as your library size changes.
For your life total to become the appropriate number, you actually gain or lose the necessary amount of life. For example, if your life total is 20 and your library has thirty-two cards in it when Invincible Hymn resolves, Invincible Hymn will cause you to gain 12 life. Other cards that interact with life gain or life loss will interact with Invincible Hymn accordingly.