Distortion calibration of the PILATUS1M detector