```
X, Y = np.meshgrid(np.arange(img.shape[0]) - detector_center[0], np.arange(img.shape[1]) - detector_center[1])
return X.ravel(), Y.ravel(), img.ravel()
```
replaces this entire function.  Should change docs to say it returns 1D arrays.  Maybe we want to package up x and y, but I think I should definitely be it's own array.