# uvot_fluxes_wget.pl vrs. 2018-01-16 fem at 180511d20h13m19s537887usUT
# /Home/eud/uvot_tdrss/perl/uvot_fluxes_wget.pl -seq=00831888992 -use_uvot -rebin -plot_mag -sens_corr -search_src_reg -wrk_dir=/local/home/khamseen/khamseen10/uvot_tdrss/uvot_lc -web -zp_2011 -gamma=1.0 -use_filter_wtd=white v b u
# Current directory: /local/home/khamseen/khamseen10/uvot_tdrss/uvot_lc
# ========= GRB180511 ===================
Could not find/read custom source region custom_831888_src.reg
Used archived BAT position of 214.50800 -62.45700
Reference: GCN_Position_Notice_Fri_11_May_18_07:28:00_UT
The position is (14:18:01.92, -62:27:25.2)
Using source region:
# Region file format: DS9 version 3.0
# uvot_fluxes.pl bat
global font="helvetica 12 bold" select=1 edit=1 move=1 delete=1 include=1 fixed=0 source=1
fk5;circle(214.508,-62.457,3") # color=red dash=0
Source region spec. is: 214.508 -62.457 3"
Region file centered at (214.508,-62.457), which is (14:18:01.92, -62:27:25.2)
Could not find/read custom background region custom_831888_bkg.reg
Made source region file with 5" aper with name uvot_flux_src5.reg
Coincidence losses are calculated using a 5" aperture.
Exposure times (t_exp) have NOT been corrected for coinc. loss, but rates and mags have been.
The no. of background pixels has been corrected by the ratio of coincidence loss corrections in the source and background regions.
The errors have been adjusted to account for the binomial distribution of counts at large rates.
A table entry starting with # is an exposure with no aspect solution.
A table entry starting with ! has no pixels in either source or background region.
A table entry starting with % is unreliable because it is not well inside the image.
Upper limits in tables give the 0.9987 confidence limit using Bayesian analysis for detection taking the observed counts into account.
Upper limits in plots give the 0.9772 confidence limit using Bayesian analysis.
Weighted rates in tables (wtd_rate) combine rates from different exposures weighted by the expected source rate divided by the background rate
The source is assumed to produce the same magnitude in all filters.
The source is assumed to decay as t**(-1.0), and the rate is normalized so that the white filter produces 1 cps at 1000 sec.
The Rebinned Data for All_files combine rates from different exposures weighted by the expected rate divided by the observed sigma squared.
A plot of these data is stored in uvot_fluxes_wtd_date.ps and .gif.
A zero point of 20.29 is adopted for weighting rates.
*** Since no accurate position is available, set rates to 0. and compute ULs based on expected background in source aperture.
Because there are many possible positions for a source, the confidence levels should be increased for upper limits.
Using the ratio of the BAT region and the aperture of 3600.0,
3 sigma should become about 5.1 sigma and 2 sigma should become about 4.5 sigma.
Accordingly confidence limits in the tables have been adjusted from 0.9987 to 0.99999964.
No adjustment has been made for the confidence limits for the rebinned data or the plots.
Subtract UTCF of -20.92226 from uncorrected trigger time of 547715739.07 in BAT summary file
# ============ Reading file sw00831888992uwh_sk.img ================
Use keyword TRIGTIME of 547715760 for trigger time.
Long-term sensitivity correction to zero point is -0.192 at 547721990
The processing date in extension 0 is: 2018-05-11T20:06:13
The trigger time is: 547715760. The reference is keyword in image file
Using zero point of 20.098 for filter WHITE
Use aperture correction of 1.108 based on aperture of 3.00
Using background region based on sources found in extension 4:
# Region file format: DS9 version 3.0
global color=red font="helvetica 10 normal" select=1 edit=1 move=1 delete=1 include=1 fixed=0 source
fk5;circle(214.508,-62.457,25")
fk5;-circle(214.508,-62.457,12.5")
fk5;-circle(214.498272,-62.457289,6")
fk5;-circle(214.512407,-62.460563,6")
 Ext   Exposure      t-trig coinc  t_exp   src  pix    bkg   pix net_rate +/-   mag   UL sum_rate  +/-    mag  UL sumexp wtd_rate  +/-   mag  wt/t
   1 wh547721990I    6230.3  0.95  147.4  387.3 112  18951  5098  0.000 0.163 99.00 20.3  0.0000 0.1629 99.00 20.3   147  0.000  1.226 99.00 0.045 
   2 wh547721990E    6230.3  0.95  147.4  386.9 111  18926  5092  0.000 0.162 99.00 20.3 
   3 wh547722559I    6799.0  0.95  196.6  562.3 116  25214  5128  0.000 0.143 99.00 20.4  0.0000 0.1075 99.00 20.8   344  0.000  0.850 99.00 0.042 
   4 wh547728636I   12876.2  0.95  295.1  751.5 108  37680  5088  0.000 0.113 99.00 20.7  0.0000 0.0778 99.00 21.1   639  0.000  0.764 99.00 0.033 
   5 wh547728939I   13179.6  0.95  295.0  789.7 112  38231  5108  0.000 0.115 99.00 20.7  0.0000 0.0645 99.00 21.3   934  0.000  0.706 99.00 0.029 
   6 wh547729243I   13483.2  0.95  295.0  856.1 120  38235  5120  0.000 0.120 99.00 20.6  0.0000 0.0568 99.00 21.4  1229  0.000  0.663 99.00 0.027 
    Sum (T+  6230 to  13783):            3520.9       3520.9 (est. in src region)   SNR_unwtd_sum:   0.00 0.999999638888889 signif. UL:  21.45
  0  1229 547727219   11458.5   2324.5  -5228.2    0.0000   0.0568 99.000 99.000 -99.000
Total wtd_rate (for all exposures so far):  0.000 +/- 0.656 snr:  0.0 mag: 99.00 UL: 18.79
Rebinned Data for sw00831888992uwh_sk.img using a zero point of 20.098:
 No Exposure     t-avg        + / -       net_rate      +/-   mag   +/-     t-avg  sum_rate     +/-   mag   +/-   UL3
  0      327    6644.4    354.3   -414.1    0.0000   0.1075 99.00 99.00    6644.4    0.0000   0.1075 99.00 99.00 21.25
  1      842   13329.4    453.6   -453.2    0.0000   0.0669 99.00 99.00   11459.1    0.0000   0.0568 99.00 99.00 21.94
=========================================================
================ Start New Filter V ==================
=========================================================
# ============ Reading file sw00831888992uvv_sk.img ================
Use keyword TRIGTIME of 547715760 for trigger time.
Long-term sensitivity correction to zero point is -0.245 at 547716831
The processing date in extension 0 is:  2018-05-11T20:06:13
The trigger time is: 547715760. The reference is keyword in image file
Using zero point of 17.645 for filter V
Use aperture correction of  1.087 based on aperture of  3.00
Using background region based on sources found in extension 2:
# Region file format: DS9 version 3.0
global color=red font="helvetica 10 normal" select=1 edit=1 move=1 delete=1 include=1 fixed=0 source
fk5;circle(214.508,-62.457,25")
fk5;-circle(214.508,-62.457,12.5")
fk5;-circle(214.498360,-62.457302,6")
fk5;-circle(214.512387,-62.460535,6")
 Ext   Exposure      t-trig coinc  t_exp   src  pix    bkg   pix net_rate +/-   mag   UL sum_rate  +/-    mag  UL sumexp wtd_rate  +/-   mag  wt/t
   1 vv547716830E    1070.9  0.99   10.9    3.5 112    321  5106  0.000 0.272 99.00 17.3 
   2 vv547722969I    7209.6  0.99  196.6  113.8 108   5713  5088  0.000 0.062 99.00 18.9  0.0000 0.0622 99.00 18.9   197  0.000  5.196 99.00 0.019 
    Sum (T+  7210 to   7409):             121.3        121.3 (est. in src region)   SNR_unwtd_sum:   0.00 0.999999638888889 signif. UL:  18.89
  0   197 547723070    7309.5     99.9    -99.9    0.0000   0.0622 99.000 99.000 -99.000
Total wtd_rate (for all exposures so far):  0.000 +/- 0.639 snr:  0.0 mag: 99.00 UL: 16.36
Rebinned Data for sw00831888992uvv_sk.img using a zero point of 17.645:
 No Exposure     t-avg        + / -       net_rate      +/-   mag   +/-     t-avg  sum_rate     +/-   mag   +/-   UL3
  0      195    7309.5     99.9    -99.9    0.0000   0.0622 99.00 99.00    7309.5    0.0000   0.0622 99.00 99.00 19.39
=========================================================
================ Start New Filter B ==================
=========================================================
# ============ Reading file sw00831888992ubb_sk.img ================
Use keyword TRIGTIME of 547715760 for trigger time.
Long-term sensitivity correction to zero point is -0.141 at 547722354
The processing date in extension 0 is:  2018-05-11T20:06:13
The trigger time is: 547715760. The reference is keyword in image file
Using zero point of 18.969 for filter B
Use aperture correction of  1.108 based on aperture of  3.00
Using background region based on sources found in extension 4:
# Region file format: DS9 version 3.0
global color=red font="helvetica 10 normal" select=1 edit=1 move=1 delete=1 include=1 fixed=0 source
fk5;circle(214.508,-62.457,25")
fk5;-circle(214.508,-62.457,12.5")
fk5;-circle(214.498361,-62.457277,6")
fk5;-circle(214.512426,-62.460530,6")
 Ext   Exposure      t-trig coinc  t_exp   src  pix    bkg   pix net_rate +/-   mag   UL sum_rate  +/-    mag  UL sumexp wtd_rate  +/-   mag  wt/t
   1 bb547722354I    6594.2  0.98  196.6  196.7 116   8932  5136  0.000 0.082 99.00 19.9  0.0000 0.0823 99.00 19.9   197  0.000  1.859 99.00 0.042 
   2 bb547727724I   11964.1  0.98  295.0  298.9 112  13499  5104  0.000 0.066 99.00 20.1  0.0000 0.0517 99.00 20.4   492  0.000  1.534 99.00 0.031 
   3 bb547728027I   12267.6  0.98  295.0  296.9 116  13589  5104  0.000 0.068 99.00 20.1  0.0000 0.0411 99.00 20.7   787  0.000  1.351 99.00 0.028 
   4 bb547728331I   12571.2  0.98  295.0  286.9 116  13283  5124  0.000 0.067 99.00 20.1  0.0000 0.0351 99.00 20.8  1082  0.000  1.222 99.00 0.026 
    Sum (T+  6594 to  12871):            1107.5       1107.5 (est. in src region)   SNR_unwtd_sum:   0.00 0.999999638888889 signif. UL:  20.84
  0  1082 547727137   11377.1   1493.8  -4782.9    0.0000   0.0351 99.000 99.000 -99.000
Total wtd_rate (for all exposures so far):  0.000 +/- 0.573 snr:  0.0 mag: 99.00 UL: 17.81
Rebinned Data for sw00831888992ubb_sk.img using a zero point of 18.969:
 No Exposure     t-avg        + / -       net_rate      +/-   mag   +/-     t-avg  sum_rate     +/-   mag   +/-   UL3
  0 1.06e+03   11377.0   1493.9  -4782.9    0.0000   0.0351 99.00 99.00   11377.0    0.0000   0.0351 99.00 99.00 21.34
=========================================================
================ Start New Filter U ==================
=========================================================
# ============ Reading file sw00831888992uuu_sk.img ================
Use keyword TRIGTIME of 547715760 for trigger time.
Long-term sensitivity correction to zero point is -0.152 at 547722149
The processing date in extension 0 is:  2018-05-11T20:06:13
The trigger time is: 547715760. The reference is keyword in image file
Using zero point of 18.188 for filter U
Use aperture correction of  1.100 based on aperture of  3.00
Using background region based on sources found in extension 1:
# Region file format: DS9 version 3.0
global color=red font="helvetica 10 normal" select=1 edit=1 move=1 delete=1 include=1 fixed=0 source
fk5;circle(214.508,-62.457,25")
fk5;-circle(214.508,-62.457,12.5")
fk5;-circle(214.498173,-62.457353,6")
fk5;-circle(214.512355,-62.460578,6")
 Ext   Exposure      t-trig coinc  t_exp   src  pix    bkg   pix net_rate +/-   mag   UL sum_rate  +/-    mag  UL sumexp wtd_rate  +/-   mag  wt/t
   1 uu547722148I    6388.9  0.99  196.6   81.5 104   4225  5072  0.000 0.053 99.00 19.6  0.0000 0.0530 99.00 19.6   197  0.000  2.384 99.00 0.050 
   2 uu547723584I    7824.8  0.99  153.7   82.0 116   3354  5080  0.000 0.064 99.00 19.4  0.0000 0.0409 99.00 19.9   350  0.000  1.969 99.00 0.044 
    Sum (T+  6389 to   7981):             163.2        163.2 (est. in src region)   SNR_unwtd_sum:   0.00 0.999999638888889 signif. UL:  19.89
  0   350 547722869    7109.3    871.8   -720.3    0.0000   0.0409 99.000 99.000 -99.000
Total wtd_rate (for all exposures so far):  0.000 +/- 0.546 snr:  0.0 mag: 99.00 UL: 17.08
Rebinned Data for sw00831888992uuu_sk.img using a zero point of 18.188:
 No Exposure     t-avg        + / -       net_rate      +/-   mag   +/-     t-avg  sum_rate     +/-   mag   +/-   UL3
  0      348    7109.1    871.9   -720.2    0.0000   0.0409 99.00 99.00    7109.1    0.0000   0.0409 99.00 99.00 20.39
=========================================================
================ Start New Filter UVW1 ==================
=========================================================
# ============ Reading file sw00831888992uw1_sk.img ================
Use keyword TRIGTIME of 547715760 for trigger time.
Long-term sensitivity correction to zero point is -0.353 at 547723380
The processing date in extension 0 is:  2018-05-11T20:06:13
The trigger time is: 547715760. The reference is keyword in image file
Using zero point of 17.087 for filter UVW1
Use aperture correction of  1.123 based on aperture of  3.00
Using background region based on sources found in extension 1:
# Region file format: DS9 version 3.0
global color=red font="helvetica 10 normal" select=1 edit=1 move=1 delete=1 include=1 fixed=0 source
fk5;circle(214.508,-62.457,25")
fk5;-circle(214.508,-62.457,12.5")
 Ext   Exposure      t-trig coinc  t_exp   src  pix    bkg   pix net_rate +/-   mag   UL sum_rate  +/-    mag  UL sumexp wtd_rate  +/-   mag  wt/t
   1 w1547723380I    7620.0  1.00  196.6   24.6 120   1276  5880  0.000 0.030 99.00 19.1  0.0000 0.0295 99.00 19.1   197  0.000  4.352 99.00 0.051 
    Sum (T+  7620 to   7820):              26.0         26.0 (est. in src region)   SNR_unwtd_sum:   0.00 0.999999638888889 signif. UL:  19.15
  0   197 547723480    7719.9     99.9    -99.9    0.0000   0.0295 99.000 99.000 -99.000
Total wtd_rate (for all exposures so far):  0.000 +/- 0.553 snr:  0.0 mag: 99.00 UL: 15.96
Rebinned Data for sw00831888992uw1_sk.img using a zero point of 17.087:
 No Exposure     t-avg        + / -       net_rate      +/-   mag   +/-     t-avg  sum_rate     +/-   mag   +/-   UL3
  0      196    7719.9     99.9    -99.9    0.0000   0.0295 99.00 99.00    7719.9    0.0000   0.0295 99.00 99.00 19.64
=========================================================
================ Start New Filter UVM2 ==================
=========================================================
# ============ Reading file sw00831888992um2_sk.img ================
Use keyword TRIGTIME of 547715760 for trigger time.
Long-term sensitivity correction to zero point is -0.338 at 547723175
The processing date in extension 0 is:  2018-05-11T20:06:13
The trigger time is: 547715760. The reference is keyword in image file
Using zero point of 16.512 for filter UVM2
Use aperture correction of  1.106 based on aperture of  3.00
Using background region based on sources found in extension 1:
# Region file format: DS9 version 3.0
global color=red font="helvetica 10 normal" select=1 edit=1 move=1 delete=1 include=1 fixed=0 source
fk5;circle(214.508,-62.457,25")
fk5;-circle(214.508,-62.457,12.5")
 Ext   Exposure      t-trig coinc  t_exp   src  pix    bkg   pix net_rate +/-   mag   UL sum_rate  +/-    mag  UL sumexp wtd_rate  +/-   mag  wt/t
High bkg:   1 m2547723174I  196.6    533  5860  0.463  0.020
   1 m2547723174I    7414.8  1.00  196.6    9.2 112    533  5860  0.000 0.018 99.00 19.1  0.0000 0.0181 99.00 19.1   197  0.000  4.425 99.00 0.079 
    Sum (T+  7415 to   7615):              10.2         10.2 (est. in src region)   SNR_unwtd_sum:   0.00 0.999999638888889 signif. UL:  19.10
  0   197 547723275    7514.7     99.9    -99.9    0.0000   0.0181 99.000 99.000 -99.000
Total wtd_rate (for all exposures so far):  0.000 +/- 0.541 snr:  0.0 mag: 99.00 UL: 15.41
Rebinned Data for sw00831888992um2_sk.img using a zero point of 16.512:
 No Exposure     t-avg        + / -       net_rate      +/-   mag   +/-     t-avg  sum_rate     +/-   mag   +/-   UL3
  0      196    7514.7     99.9    -99.9    0.0000   0.0181 99.00 99.00    7514.7    0.0000   0.0181 99.00 99.00 19.60
=========================================================
================ Start New Filter UVW2 ==================
=========================================================
# ============ Reading file sw00831888992uw2_sk.img ================
Use keyword TRIGTIME of 547715760 for trigger time.
Long-term sensitivity correction to zero point is -0.429 at 547722765
The processing date in extension 0 is:  2018-05-11T20:06:13
The trigger time is: 547715760. The reference is keyword in image file
Using zero point of 16.951 for filter UVW2
Use aperture correction of  1.108 based on aperture of  3.00
Using background region based on sources found in extension 2:
# Region file format: DS9 version 3.0
global color=red font="helvetica 10 normal" select=1 edit=1 move=1 delete=1 include=1 fixed=0 source
fk5;circle(214.508,-62.457,25")
fk5;-circle(214.508,-62.457,12.5")
 Ext   Exposure      t-trig coinc  t_exp   src  pix    bkg   pix net_rate +/-   mag   UL sum_rate  +/-    mag  UL sumexp wtd_rate  +/-   mag  wt/t
High bkg:   1 w2547722764I  196.6    963  5844  0.839  0.027
   1 w2547722764I    7004.7  1.00  196.6   20.5 112    963  5844  0.000 0.024 99.00 19.2  0.0000 0.0245 99.00 19.2   197  0.000  3.767 99.00 0.069 
High bkg:   2 w2547729549I  306.8   1511  5872  0.839  0.022
   2 w2547729549I   13789.2  1.00  306.8   23.7 116   1511  5872  0.000 0.020 99.00 19.4  0.0000 0.0155 99.00 19.7   503  0.000  3.195 99.00 0.047 
High bkg:   3 w2547733334I  117.2    598  5832  0.875  0.036
   3 w2547733334I   17574.3  1.00  117.2   10.1 112    598  5832  0.000 0.032 99.00 18.9  0.0000 0.0140 99.00 19.8   621  0.000  3.093 99.00 0.043 
    Sum (T+  7005 to  17693):              59.8         59.8 (est. in src region)   SNR_unwtd_sum:   0.00 0.999999638888889 signif. UL:  19.82
  0   621 547728235   12474.9   5218.5  -5470.2    0.0000   0.0140 99.000 99.000 -99.000
Total wtd_rate (for all exposures so far):  0.000 +/- 0.533 snr:  0.0 mag: 99.00 UL: 15.87
Rebinned Data for sw00831888992uw2_sk.img using a zero point of 16.951:
 No Exposure     t-avg        + / -       net_rate      +/-   mag   +/-     t-avg  sum_rate     +/-   mag   +/-   UL3
  0      196    7104.6     99.9    -99.9    0.0000   0.0245 99.00 99.00    7104.6    0.0000   0.0245 99.00 99.00 19.71
  1      423   14964.8   2728.6  -1175.6    0.0000   0.0170 99.00 99.00   12474.8    0.0000   0.0140 99.00 99.00 20.32
The data range from T+6230.3 s (0.07 d) to T+17693.4 s (0.20 d)
Wrote uvot_fluxes_180511d20h13m19s537887usUT.qdp
Wrote uvot_fluxes_180511d20h13m19s537887usUT.gif
Wrote uvot_fluxes_180511d20h13m19s537887usUT.ps
Wrote uvot_fluxes_180511d20h13m19s537887usUT_vis.qdp
Wrote uvot_fluxes_180511d20h13m19s537887usUT_uv.qdp
Wrote uvot_fluxes_180511d20h13m19s537887usUT_vis.gif
Wrote uvot_fluxes_180511d20h13m19s537887usUT_vis.ps
Wrote uvot_fluxes_180511d20h13m19s537887usUT_uv.gif
Wrote uvot_fluxes_180511d20h13m19s537887usUT_uv.ps
# ================ Make Light Curve for Weighted Filters ==========
Use the following filters with indicated color corrections (mags):
  u (0)  , white (0)  , b (0)  , v (0)  , 
Rebinned Data for All_files using a zero point of 20.290:
 No Exposure     t-avg        + / -       net_rate      +/-   mag   +/-     t-avg  sum_rate     +/-   mag   +/-   UL3
  0     2.14    9249.0   4534.0  -3018.7    0.0000   0.0650 99.00 99.00    9249.0    0.0000   0.0650 99.00 99.00 21.99
The data range from T+6230.3 s (0.07 d) to T+17693.4 s (0.20 d)
Wrote uvot_fluxes_wtd_180511d20h13m19s537887usUT.qdp
Wrote uvot_fluxes_wtd_180511d20h13m19s537887usUT.gif
Wrote uvot_fluxes_wtd_180511d20h13m19s537887usUT.ps
Found 4 exposures with unusual background rate
Normal end of uvot_fluxes_wget.pl vrs. 2018-01-16 fem