Fix indexing bug in PSF/Residual offset calculation

This bug didn't impact the standard testcase as the PSF peak
position was always identical in both x and y directions.