Skip to content

Commit

Permalink
add extra check
Browse files Browse the repository at this point in the history
  • Loading branch information
mileslucas committed Sep 3, 2024
1 parent 97d05f9 commit da6fa16
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/vampires_dpp/combine_frames.py
Original file line number Diff line number Diff line change
Expand Up @@ -245,8 +245,9 @@ def combine_frames_headers(headers: Sequence[fits.Header], wcs=False):
# WCS
if wcs:
# need to get average CRVALs and PCs
output_header["CRVAL1"] = np.rad2deg(ave_ra), test_header.comments["CRVAL1"]
output_header["CRVAL2"] = np.rad2deg(ave_dec), test_header.comments["CRVAL2"]
if "CRVAL1" in test_header and "CRVAL2" in test_header:
output_header["CRVAL1"] = np.rad2deg(ave_ra), test_header.comments["CRVAL1"]
output_header["CRVAL2"] = np.rad2deg(ave_dec), test_header.comments["CRVAL2"]
if "PC1_1" in test_header:
output_header["PC1_1"] = table["PC1_1"].mean(), test_header.comments["PC1_1"]
output_header["PC1_2"] = table["PC1_2"].mean(), test_header.comments["PC1_2"]
Expand Down

0 comments on commit da6fa16

Please sign in to comment.