fixed crash during PSF fit