Size dependence of magnetic switching in perpendicularly magnetized MgO/Co/Pt pillars close to the spin reorientation transition