photcal_fitslist
Last updated: July 05,2018

Process a list of FITS images to derive photometric zeropoint values that may be installed in the FITS header of each processed image.

  
% photcal_fitslist --help
Usage: photcal_fitslist ./S/list.0 usno N 
arg1 - Name of file with list of FITS images (can be full path)
arg2 - photometry catalog to use (usno,ps1)
arg3 - run in debug mode (Y/N)

Below I show a more practical example that I have been using on the NGC3379 data in July 2018.

  
% pwd                /home/sco/N3379/T2
% ls
local_red/  S/

% photcal_fitslist ./S/list.1 ps1 Y



A summary description of the process.

Each image in the input file (list.0 in the example above) will pe processed to derive the photometric zeropoint for a 1-second exposure (i.e. the ZP values are EXPTIME-normalized). To accomplish this we need three basic sets of data for each image:

  1. A catalog of source (centroid) positions
  2. A catalog of instrumental magnitudes for the sources
  3. A list of standard magnitudes for some subset of the image sources
This code (photcal_fitslist) is really just a wrapper script for a number of image processing and visualization codes. It loops through each input image and performs various bookkeeping tasks to verfiy that each image can be processed and then performs the zeropoint analysis.

I'll break trhe flow (per image) of a photcal_fitslist run into a few major sectiosn.

Initial bookkeeping: A local copy of the (wcs-calibrated) FITS image is gathered. If a catalog from a previous IMGCAT0 run is avaliable, that is copied to the local directory also. For the image Rsco2039.fis, here is what I would see at this stage:

% ls 
local_red/  Rsco2039.fits  Rsco2039.parlab  Rsco2039.table  S/

Gather ZP data with zpstars: Like the wcsf_* series of astrometry routines, this process initially was built assuming the USNO-B1.0 catalog would be used as the primary calibration source. For astrometry this was fine since the USNO astrometry is quite accurate. However, the USNO photometry is relatively poor in quality, and I prefer to use other sources. In the current pipeline discussed here I rely on the PanSTARRS (PS1) gri photometry and corresponding BVR magnitudes derived from the transformed PS1 data. The primary tool for collecting the three data sets listed above is zpstars. The processing flow we employ with zpstars will depend on how we extablish the image source positions (i.e. use USNO or IMGCAT0 sources) and what photometric system we will be transforming to (i.e. usno or ps1). These details are covered in the discussion of zpstars. Here are the (new) files related to Rsco2039.fits that I would see at this stage:

Rsco2039.info	        == mido.sh image parameters of selected objects 
Rsco2039.rdxy           == the (Ra,Dec,Equinox,X,Y) for the selected objects 
Rsco2039-usno.cdfp      == inital USNO catalog of the field   
Rsco2039.cdfp            == floating point coordinate file of selected objects  
Rsco2039_zp.table,parlab == table file of USNO (only) ZP data 

Case 1: Use USNO phtometry for ZP: The data in the *_zp.table file will be used to compute a mean ZP. This value is installed in the FITS header.

Case 2: Use gri PS1 photometry for ZP: After a firts pass processing of all images to gather ZP sources (preferably stars) the magnitudes for these sources must be collected from the online PS1 website. The ps1_setup routine will step the user through this process. The goal is to install a gri data file named "griBVR.cdfp" into the ZPTAB archive (i.e. ./local_red/ZPTAB/griBVR.cdfp).

Compute gri ZP: If we are in a Case 2 situation, then we must make a scond pass oof a photcal_fitslist run. The command line would look like:

% photcal_fitslist ./S/list.1 ps1 N
In most cases, this will take about a minute or so per image to complete.

We can make a summary table for the full set of ZP determinations using the gethead routine.


% ls local_red/ZP
Rsco2039.fits  Rsco2040.fits  Rsco2041.fits  Rsco2042.fits  Rsco2043.fits
% gethead ./local_red/ZP/*.fits INSFILTE ZPSEC ZPERR NUMZP 
Rsco2039.fits   R   -8.76235 0.034183   40
Rsco2040.fits   R   -8.86470 0.002344   60
Rsco2041.fits   R   -8.89663 0.013554   68
Rsco2042.fits   B   -9.79989 0.018791   64
Rsco2043.fits   V   -9.26939 0.010166   23
In Jul2018 I add some options to the modules used in photcal_fitslist that allow me to easily change the mido.sh photometry on the fly (by changing the size of the circle apertures painted in the zpstars step). Using this new capablity I rederived the ZP values for the above images:

% gethead ./local_red/ZP/*.fits INSFILTE ZPSEC ZPERR NUMZP 
Rsco2039.fits   R   -8.79392 0.007837   74
Rsco2040.fits   R   -8.86507 0.002382   96
Rsco2041.fits   R   -8.90970 0.004795   66
Rsco2042.fits   B   -9.82242 0.008243   59
Rsco2043.fits   V   -9.30222 0.018677   50
The answers do change (though not a huge amount) becasue I used more (fainter) stars and I used an aperture radius (8") that was better matched to the PSF width found on my set of NGC3370 PFC images.




Back to SCO code page