added additional IDL routine for checking the mask files for the presence of nonzero pixels from within bcd_phot.pro
modified metadata creation to include params['cbcd'], get_photometry_idl now passes the mask_path to bcd_phot.pro so it can read the file and pass it to badpix_aperture.pro to look for nonzero pixels, also bcd_phot.pro now produces an additional log file containing source measurements which had were rejected because of nonzero mask pixels in the aperture
fixed bug from moving functions to util without proper imports
fixed bug from moving functions to util without proper imports
added new IDL function to get the bits set in a mask file pixel value
added flag argument 'mask' to bcd_phot.pro to switch on/off the mask checking functionality -- still expects the mask file path either way
modified bcd_phot.py to work with the new bcd_phot.pro flag argument -- checks the metadata file for the value of key 'mask' to determine the IDL call
modified run.py to look for additional key 'mask' in the params dict of YAML setup file, then pass it on to metadata files -- determines whether bcd_phot.pro should read in mask files and check for flagged pixels in the source apertures
added comment: URL for original I took code snippets from
bugfix: masked_list.txt file not initialized by bcd_phot.py so bcd_phot.pro had nothing to append lines to
bugfix: 'cbcd' should be 'mask' on line 59
bugfix: keyword 'mask' was being overwritten causing bcd_phot.pro to crash -- changed kewyord to 'use_mask'
bugfix: errant double quotation mark in bcd_phot.py
bugfix: forgot to change the keyword name to 'use_mask' in IDL call from bcd_phot.py
added IDL function bit_flag.pro to get bit flag and implemented new logic in badpix_aperture.pro to get all bits within aperture and return the bit flag corresponding to the set of all bits, which is now written to disk in the masked_list.txt files
badpix branch now keeps track of which bit flags are in aperture and saves the corresponding 'fatal bit pattern' (mopex language) in the masked_list.txt files
bugfix: missing comma in IDL return statement
bugfix: bitflag converted to float because it was placed inside array with float pixel coordinates, changed syntax to keep it as an int
added logic to bcd_phot.pro to handle the cases where combinations of bits 2, 4, and 7 are the only bits set within the aperture
fixed bugs in bcd_phot.pro: finite pixel value check was not indexing the x/y arrays, and the mask check section was using the same index variable in an internal for loop as the outer loop - infinite loop resulted