diff options
author | Aaron LI <aly@aaronly.me> | 2017-09-03 17:01:47 +0800 |
---|---|---|
committer | Aaron LI <aly@aaronly.me> | 2017-09-03 17:01:47 +0800 |
commit | 6653e976c4ab07e1e8b36bf2f7ad59bb9d723def (patch) | |
tree | 5895eab31d3a4c4a676cd1f68a8eb80a34508476 /python | |
parent | 1369952c740cff4b135a7fe9ca7b15e2cc92623a (diff) | |
download | atoolbox-6653e976c4ab07e1e8b36bf2f7ad59bb9d723def.tar.bz2 |
calc_radial_psd.py: do not require EXPOSURE keyword
Diffstat (limited to 'python')
-rwxr-xr-x | python/calc_radial_psd.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/python/calc_radial_psd.py b/python/calc_radial_psd.py index 23bd819..6bb1708 100755 --- a/python/calc_radial_psd.py +++ b/python/calc_radial_psd.py @@ -277,7 +277,7 @@ class AstroImage: print("Loading image ... ", end="", flush=True) with fits.open(image) as imgfits: self.image = imgfits[0].data.astype(np.float) - self.exposure = imgfits[0].header["EXPOSURE"] + self.exposure = imgfits[0].header.get("EXPOSURE") if verbose: print("DONE", flush=True) @@ -296,7 +296,7 @@ class AstroImage: print("Loading background map ... ", end="", flush=True) with fits.open(bkgmap) as imgfits: self.bkgmap = imgfits[0].data.astype(np.float) - self.exposure_bkg = imgfits[0].header["EXPOSURE"] + self.exposure_bkg = imgfits[0].header.get("EXPOSURE") if verbose: print("DONE", flush=True) |