Large deviations for non-uniformly expanding maps