Localized magnetohydrodynamic instabilities in Tokamaks with non-circular cross sections