-
Notifications
You must be signed in to change notification settings - Fork 15
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Header fixes and LSSTCamSim support #473
Changes from all commits
3243da2
6f1a9a5
79dcd86
a5eb818
bbe3f90
10a6d6b
db0081b
fcb8cbe
a16ecce
18e29aa
4c167f2
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
*.fits binary | ||
*.fits.fz binary | ||
*.fits.gz binary |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
tree_rings_file_name: tree_ring_parameters_2018-04-26.txt | ||
vignetting_file_name: LSSTCam_vignetting_data.json | ||
telescope_format: LSST_%s.yaml | ||
bias_levels_file: LSSTCam_bias_levels_run_13421.json | ||
camera_name: LsstCam | ||
ndets: 189 |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -259,7 +259,6 @@ def get_primary_hdu(eimage, lsst_num, camera_name=None, | |
telcode = 'MC' | ||
elif camera_name == 'LsstComCamSim' : | ||
phdu.header['FILTER'] = ComCam_filter_map.get(band, None) | ||
phdu.header['TELESCOP'] = SIMONYI_TELESCOPE | ||
phdu.header['INSTRUME'] = 'ComCamSim' | ||
phdu.header['RAFTBAY'] = raft | ||
phdu.header['CCDSLOT'] = sensor | ||
|
@@ -270,16 +269,31 @@ def get_primary_hdu(eimage, lsst_num, camera_name=None, | |
telcode = 'CC' | ||
else: | ||
phdu.header['FILTER'] = LSSTCam_filter_map.get(band, None) | ||
phdu.header['INSTRUME'] = 'LSSTCam' | ||
if camera_name == 'LsstCamSim': | ||
phdu.header['INSTRUME'] = 'LSSTCamSim' | ||
else: | ||
phdu.header['INSTRUME'] = 'LSSTCam' | ||
phdu.header['RAFTBAY'] = raft | ||
phdu.header['CCDSLOT'] = sensor | ||
phdu.header['RA'] = ratel | ||
phdu.header['DEC'] = dectel | ||
phdu.header['ROTCOORD'] = 'sky' | ||
phdu.header['ROTPA'] = rotang | ||
telcode = 'MC' | ||
dayobs = eimage.header['DAYOBS'] | ||
seqnum = eimage.header['SEQNUM'] | ||
contrllr = eimage.header['CONTRLLR'] | ||
phdu.header['TELESCOP'] = SIMONYI_TELESCOPE | ||
phdu.header['TELCODE'] = telcode | ||
phdu.header['RASTART'] = ratel | ||
phdu.header['DECSTART'] = dectel | ||
phdu.header['ELSTART'] = eimage.header['ALTITUDE'] | ||
phdu.header['AZSTART'] = eimage.header['AZIMUTH'] | ||
if eimage.header['IMGTYPE'] == 'SKYEXP': | ||
phdu.header['RADESYS'] = 'ICRS' | ||
phdu.header['TRACKSYS'] = 'RADEC' | ||
else: | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. When does this get used? Simulated flats? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. (by this, I mean TRACKSYS = LOCAL). There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yes, for anything not on-sky, specifically any calibration frames. |
||
phdu.header['TRACKSYS'] = 'LOCAL' | ||
phdu.header['OBSID'] = f"{telcode}_{contrllr}_{dayobs}_{seqnum:06d}" | ||
phdu.header['MJD-OBS'] = mjd_obs | ||
phdu.header['HASTART'] = eimage.header['HASTART'] | ||
|
@@ -288,9 +302,10 @@ def get_primary_hdu(eimage, lsst_num, camera_name=None, | |
phdu.header['DATE-END'] = Time(mjd_end, format='mjd', scale='tai').to_value('isot') | ||
phdu.header['AMSTART'] = eimage.header['AMSTART'] | ||
phdu.header['AMEND'] = eimage.header['AMEND'] | ||
phdu.header['ORIGIN'] = "imSim" | ||
phdu.header['IMSIMVER'] = __version__ | ||
phdu.header['PKG00000'] = 'throughputs' | ||
phdu.header['VER00000'] = '1.4' | ||
phdu.header['VER00000'] = '1.9' | ||
phdu.header['CHIPID'] = det_name | ||
phdu.header['FOCUSZ'] = eimage.header['FOCUSZ'] | ||
|
||
|
This file was deleted.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe factor out some of the other common keywords too? E.g., 'RAFTBAY', 'CCDSLOT', 'RA', 'DEC', 'ROTCOORD', 'ROTPA', ...?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In order to do that more cleanly, I'd like to get rid of support for
LsstCamImSim
, otherwise I suspect the number ofif
statements will actually increase. In fact, in addition to getting rid ofLsstCamImSim
support, I'd like to support just*Sim
cameras explicitly, e.g.,LsstCamSim
andLsstComCamSim
, so also removingLsstCam
as an option. I'll post an issue with this proposal.