diff options
author | Aaron LI <aaronly.me@outlook.com> | 2016-04-28 21:02:27 +0800 |
---|---|---|
committer | Aaron LI <aaronly.me@outlook.com> | 2016-04-28 21:02:27 +0800 |
commit | b2d8d255680aaf43db6bcc4048021cdd6b2eb9c5 (patch) | |
tree | 9475590baac485c8e9d0b1d8c356172b12fe3464 | |
parent | 44f8d54f8ca3d01308d11c41a24d7ff9de4ab536 (diff) | |
download | cexcess-b2d8d255680aaf43db6bcc4048021cdd6b2eb9c5.tar.bz2 |
make_stowbkg_image.sh: update keyword "DETNAM" after merge
-rwxr-xr-x | make_stowbkg_image.sh | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/make_stowbkg_image.sh b/make_stowbkg_image.sh index fdd824d..ea75fef 100755 --- a/make_stowbkg_image.sh +++ b/make_stowbkg_image.sh @@ -5,7 +5,12 @@ # Based on `ciao_blanksky.sh' (v5.0; 2015-06-02) # # Aaron LI -# 2016-04-20 +# Created: 2016-04-20 +# Updated: 2016-04-28 +# +# Changelog: +# 2016-04-28: +# * Update keyword "DETNAM" after merge # ## error code {{{ @@ -195,12 +200,14 @@ AI_NUM=`echo ${BKG_LKP} | tr ' ' '\n' | \grep 'acis[0123]iD' | wc -l` if [ ${AS_NUM} -eq 1 ]; then printf "## ACIS-S, chip: 7\n" CCD="7" + DETNAM="ACIS-7" BKG_ROOT="stowbkg_c7" STOWBKG=`lookup_bgstow ${BKG_LKP}` cp -v ${STOWBKG} ${BKG_ROOT}_orig.fits elif [ ${AI_NUM} -eq 4 ]; then printf "## ACIS-I, chip: 0-3\n" CCD="0:3" + DETNAM="ACIS-0123" BKG_ROOT="stowbkg_c0-3" AI_FILES="" for bkg in ${BKG_LKP}; do @@ -215,6 +222,10 @@ elif [ ${AI_NUM} -eq 4 ]; then # merge 4 chips blanksky evt files punlearn dmmerge dmmerge "${AI_FILES}" ${BKG_ROOT}_orig.fits clobber=yes + # update DETNAM + punlearn dmhedit + dmhedit infile="${BKG_ROOT}_orig.fits" filelist=none operation=add \ + key=DETNAM value="${DETNAM}" rm -fv `echo ${AI_FILES} | tr ',' ' '` # remove original files else printf "## ERROR: UNKNOW blanksky files:\n" |