Minor changes in mGradMag