Thermalization, condensate growth, and defect formation in an out-of-equilibrium Bose gas