An extension of the Kramers rate theory to cusped and smooth potentials