Impact of varying vacuum levels on self-heating in photonic thermometers