I believe the soft bake before exposure is to allow any solvent in the SU-8 to evaporate and thus make the resist more solid. As for the post exposure bake, the UV exposure enables the activation of the photoactive component in the SU-8 photoresist but needs energy to continue the reaction; the heat brings this energy.