From 79690e2eaaa047cf94ac5ae31349f66bf0c67028 Mon Sep 17 00:00:00 2001 From: Aaron LI Date: Thu, 23 Feb 2017 19:44:29 +0800 Subject: clean_evt2.py: Update "DETNAM" keyword after filter out chips --- bin/clean_evt2.py | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'bin/clean_evt2.py') diff --git a/bin/clean_evt2.py b/bin/clean_evt2.py index 5b53922..0712e6e 100755 --- a/bin/clean_evt2.py +++ b/bin/clean_evt2.py @@ -27,6 +27,7 @@ from acispy.manifest import get_manifest from acispy.pfiles import setup_pfiles from acispy.acis import ACIS from acispy.ds9 import ds9_view +from acispy.header import write_keyword logging.basicConfig(level=logging.INFO) @@ -176,6 +177,7 @@ def main(): else: infile = manifest.getpath("evt2", relative=True) chips = ACIS.get_chips_str(infile, sep="-") + chips_all = ACIS.get_chips_str(infile) logger.info("infile: %s" % infile) logger.info("chips: %s" % chips) @@ -187,6 +189,8 @@ def main(): gtifile = os.path.splitext(lcfile)[0] + ".gti" filter_chips(infile, evt2_chips, chips, clobber=args.clobber) + write_keyword(evt2_chips, keyword="DETNAM", + value="ACIS-{0}".format(chips_all)) detect_sources(evt2_chips, srcfile, clobber=args.clobber) remove_sources(evt2_chips, evt2_rmsrc, srcfile, clobber=args.clobber) extract_lightcurve(evt2_rmsrc, lcfile, clobber=args.clobber) -- cgit v1.2.2