Modeling of laser-pumped Tm and Ho lasers accounting for upconversion and ground-state depletion