Branching ratios, cross sections, and radiative lifetimes of rare earth ions in solids: Application to Tm3+ and Ho3+ ions in LiYF4