Compensation of internal thermal stresses in InGaAsP/InP lasers for polarization stabilization