You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: tutorials/spherex/spherex_psf.md
+28-33Lines changed: 28 additions & 33 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -219,7 +219,7 @@ The goal of this tutorial now is to find the PSF corresponding to our input coor
219
219
+++
220
220
221
221
```{warning}
222
-
In the SPHEREx spectral image versions prior or equal to 6.5.5, there was a missmatch between the spatial layout of the PSF zones and the the indexing of the PSF zones in the image header. This has now been fixed in versions 6.5.6 and beyond.
222
+
In the SPHEREx spectral image versions prior or equal to 6.5.5, there was a mismatch between the spatial layout of the PSF zones and the indexing of the PSF zones in the image header. This has now been fixed in versions 6.5.6 and beyond.
223
223
224
224
For more information about these changes, see the following webpage: [PSF Erratum](https://irsa.ipac.caltech.edu/data/SPHEREx/docs/psfhdrerr.html)
225
225
@@ -235,7 +235,7 @@ def parse_version(v):
235
235
# detect modifiers
236
236
modifier = None
237
237
base = v
238
-
238
+
239
239
if "+" in v:
240
240
base, modifier = v.split("+", 1)
241
241
@@ -277,46 +277,45 @@ The function that can be used to update the header is shown below. The function
277
277
* changes the PSF zone indexing and
278
278
* changes the version of the header such that it is consistent with the new released images
279
279
280
-
Note that this function an work as standalone function to process many images.
280
+
Note that this function can work as standalone function to process many images.
281
281
282
282
```{code-cell} ipython3
283
283
def update_psf_header(old_hdul):
284
284
"""
285
-
Fix a old PSF FITS file header by rewriting only the per-plane header metadata
285
+
Fix an old PSF FITS file header by rewriting only the per-plane header metadata
286
286
so that plane k corresponds to x-fast ordering:
287
287
k0 = iy * bins_x + ix
288
288
289
289
The cube data are left untouched.
290
290
291
291
Parameters
292
292
----------
293
-
old_hdul : astropy hdul
293
+
old_hdul : fits.HDUList
294
294
Old SPHEREx Spectral Image HDUL
295
295
296
296
Return
297
297
----------
298
-
new_hdul : astropy hdul
298
+
new_hdul : fits.HDUList
299
299
New SPHEREx Spectral Image HDUL with updated PSF zone data in header and updated version number
0 commit comments