TransAlta beats Q2 EPS estimates as revenue reaches $493 million