Semi-global practical asymptotic stability and averaging