Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ; intended to work for WISE L1b headers, not sure if there are other different
- ; or more general types of SIP WCS that come from different data sets
- ; and/or telescopes
- ;IDL> help,astr.distort
- ;** Structure <78c348>, 5 tags, length=416, data length=416, refs=2:
- ; NAME STRING 'SIP'
- ; A FLOAT Array[5, 5]
- ; B FLOAT Array[5, 5]
- ; AP FLOAT Array[5, 5]
- ; BP FLOAT Array[5, 5]
- function flatten_sip, astr
- ; to save space, DON'T include distort.name -- will assume it's always SIP
- distort = astr.distort
- addstr = {a: distort.a, b: distort.b, ap: distort.ap, bp: distort.bp}
- astr_flat = struct_trimtags(astr, except=['DISTORT'])
- astr_flat = struct_addtags(astr_flat, addstr)
- return, astr_flat
- end
- ; should test on small number of images from each of W1 and W2, and from
- ; each mission phase, to make sure nothing about the WISE SIP format
- ; changed over time
- pro test_flatten_sip
- fname = '/project/projectdirs/cosmo/data/wise/allsky/4band_p1bm_frm/0a/03590a/143/03590a143-w1-int-1b.fits'
- h = headfits(fname)
- extast, h, astr
- end
- ; see if anything about the WISE/NEOWISE SIP scheme has changed for
- ; more recent data
- pro test_neo4
- fname = '/project/projectdirs/cosmo/staging/wise/neowiser4/neowiser/p1bm_frm/3b/79673b/072/79673b072-w2-int-1b.fits'
- h = headfits(fname)
- extast, h, astr
- end
Add Comment
Please, Sign In to add comment