Grids of pre-main sequence stellar models. The accretion scenario at Z=0.001 and Z=0.020