# uvot_fluxes_wget.pl vrs. 2018-11-07 fem at 200924d04h48m36s695377usUT
# /Home/eud/uvot_tdrss/perl/uvot_fluxes_wget.pl -seq=00021033002 -use_uvot -rebin -plot_mag -sens_corr -search_src_reg -wrk_dir=/local/home/khamseen/khamseen10/uvot_tdrss/uvot_lc -web -useprev -zp_2011 -gamma=1.0 -use_filter_wtd=white v b u
# Current directory: /local/data/khamseenssd/khamseen/khamseen10/uvot_tdrss/uvot_lc
# ========= GRB200914 ===================
Could not find/read custom source region custom_021033_src.reg
Used archived BAT position of 254.51200 -36.29140
Reference: GCN_FOM_Notice_Mon_14_Sep_20_14:26:40_UT
The position is (16:58:02.88, -36:17:29.0)
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(254.5120,-36.2914,3") # color=red dash=0
Source region spec. is: 254.5120 -36.2914 3"
Region file centered at (254.5120,-36.2914), which is (16:58:02.88, -36:17:29.0)
Could not find/read custom background region custom_021033_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 900.0,
3 sigma should become about 4.8 sigma and 2 sigma should become about 4.2 sigma.
Accordingly confidence limits in the tables have been adjusted from 0.9987 to 0.99999856.
No adjustment has been made for the confidence limits for the rebinned data or the plots.
Subtract UTCF of -25.64826 from uncorrected trigger time of 621780554.21 in BAT summary file
# ============ Reading file sw00021033002uvv_sk.img ================
Use keyword TRIGTIME of 621780535.644 for trigger time.
Long-term sensitivity correction to zero point is -0.295 at 621818930
The processing date in extension 0 is: 2020-09-24T04:34:32
The trigger time is: 621780535.644. The reference is keyword in image file
Using zero point of 17.595 for filter V
Use aperture correction of 1.087 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(254.5120,-36.2914,25")
fk5;-circle(254.5120,-36.2914,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 vv621818929I   38394.3  0.98   78.5  105.7 116   5035  5832  0.000 0.143 99.00 18.0  0.0000 0.1430 99.00 18.0    79  0.000 65.761 99.00 0.002 
    Sum (T+ 38394 to  38474):             100.2        100.2 (est. in src region)   SNR_unwtd_sum:   0.00 0.999998555555556 signif. UL:  18.00
  0    79 621818970   38434.2     39.9    -39.9    0.0000   0.1430 99.000 99.000 -99.000
Total wtd_rate (for all exposures so far):  0.000 +/-65.117 snr:  0.0 mag: 99.00 UL: 11.35
Rebinned Data for sw00021033002uvv_sk.img using a zero point of 17.595:
 No Exposure     t-avg        + / -       net_rate      +/-   mag   +/-     t-avg  sum_rate     +/-   mag   +/-   UL3
  0     76.9   38434.2     39.9    -39.9    0.0000   0.1430 99.00 99.00   38434.2    0.0000   0.1430 99.00 99.00 18.44
=========================================================
================ Start New Filter B ==================
=========================================================
# ============ Reading file sw00021033002ubb_sk.img ================
Use keyword TRIGTIME of 621780535.644 for trigger time.
Long-term sensitivity correction to zero point is -0.168 at 621818520
The processing date in extension 0 is:  2020-09-24T04:34:31
The trigger time is: 621780535.644. The reference is keyword in image file
Using zero point of 18.942 for filter B
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(254.5120,-36.2914,25")
fk5;-circle(254.5120,-36.2914,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 bb621818519I   37984.3  0.95   78.5  241.3 112  12184  5844  0.000 0.229 99.00 18.8  0.0000 0.2293 99.00 18.8    79  0.000 30.159 99.00 0.002 
   2 bb621824209I   43673.7  0.95   78.5  208.7 120  10482  5860  0.000 0.219 99.00 18.9  0.0000 0.1584 99.00 19.2   157  0.000 22.283 99.00 0.002 
    Sum (T+ 37984 to  43753):             448.2        448.2 (est. in src region)   SNR_unwtd_sum:   0.00 0.999998555555556 signif. UL:  19.24
  0   157 621821405   40869.1   2884.4  -2884.8    0.0000   0.1584 99.000 99.000 -99.000
Total wtd_rate (for all exposures so far):  0.000 +/-20.938 snr:  0.0 mag: 99.00 UL: 13.93
Rebinned Data for sw00021033002ubb_sk.img using a zero point of 18.942:
 No Exposure     t-avg        + / -       net_rate      +/-   mag   +/-     t-avg  sum_rate     +/-   mag   +/-   UL3
  0      150   40877.3   2876.1  -2893.0    0.0000   0.1584 99.00 99.00   40877.3    0.0000   0.1584 99.00 99.00 19.68
=========================================================
================ Start New Filter U ==================
=========================================================
# ============ Reading file sw00021033002uuu_sk.img ================
Use keyword TRIGTIME of 621780535.644 for trigger time.
Long-term sensitivity correction to zero point is -0.181 at 621818436
The processing date in extension 0 is:  2020-09-24T04:34:31
The trigger time is: 621780535.644. The reference is keyword in image file
Using zero point of 18.159 for filter U
Use aperture correction of  1.100 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(254.5120,-36.2914,25")
fk5;-circle(254.5120,-36.2914,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 uu621818435I   37899.9  0.98   78.5   93.8 112   5837  5828  0.000 0.153 99.00 18.5  0.0000 0.1535 99.00 18.5    79  0.000 41.469 99.00 0.003 
   2 uu621824124I   43589.3  0.98   78.5  117.8 116   5588  5844  0.000 0.153 99.00 18.5  0.0000 0.1082 99.00 18.9   157  0.000 31.208 99.00 0.002 
    Sum (T+ 37900 to  43669):             223.1        223.1 (est. in src region)   SNR_unwtd_sum:   0.00 0.999998555555556 signif. UL:  18.87
  0   157 621821320   40784.7   2884.4  -2884.8    0.0000   0.1082 99.000 99.000 -99.000
Total wtd_rate (for all exposures so far):  0.000 +/-17.247 snr:  0.0 mag: 99.00 UL: 13.36
Rebinned Data for sw00021033002uuu_sk.img using a zero point of 18.159:
 No Exposure     t-avg        + / -       net_rate      +/-   mag   +/-     t-avg  sum_rate     +/-   mag   +/-   UL3
  0      153   40785.8   2883.2  -2886.0    0.0000   0.1082 99.00 99.00   40785.8    0.0000   0.1082 99.00 99.00 19.30
=========================================================
================ Start New Filter UVW1 ==================
=========================================================
# ============ Reading file sw00021033002uw1_sk.img ================
Use keyword TRIGTIME of 621780535.644 for trigger time.
Long-term sensitivity correction to zero point is -0.538 at 621818271
The processing date in extension 0 is:  2020-09-24T04:34:31
The trigger time is: 621780535.644. The reference is keyword in image file
Using zero point of 16.902 for filter UVW1
Use aperture correction of  1.123 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(254.5120,-36.2914,25")
fk5;-circle(254.5120,-36.2914,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 w1621818271I  157.2   1918  5852  2.084  0.048
   1 w1621818271I   37735.8  1.00  157.2   38.0 108   1918  5852  0.000 0.043 99.00 18.6  0.0000 0.0430 99.00 18.6   157  0.000 36.877 99.00 0.005 
High bkg:   2 w1621823960I  157.2   2119  5860  2.300  0.050
   2 w1621823960I   43425.0  1.00  157.2   43.8 120   2119  5860  0.000 0.048 99.00 18.5  0.0000 0.0321 99.00 18.9   314  0.000 29.025 99.00 0.004 
High bkg:   3 w1621829695I   30.6    383  5856  2.142  0.109
   3 w1621829695I   49159.7  1.00   30.6   12.2 104    383  5856  0.000 0.097 99.00 17.7  0.0000 0.0305 99.00 19.0   345  0.000 28.033 99.00 0.004 
    Sum (T+ 37736 to  49191):              85.6         85.6 (est. in src region)   SNR_unwtd_sum:   0.00 0.999998555555556 signif. UL:  18.98
  0   345 621821950   41414.7   7776.1  -3678.9    0.0000   0.0305 99.000 99.000 -99.000
Total wtd_rate (for all exposures so far):  0.000 +/-14.876 snr:  0.0 mag: 99.00 UL: 12.26
Rebinned Data for sw00021033002uw1_sk.img using a zero point of 16.902:
 No Exposure     t-avg        + / -       net_rate      +/-   mag   +/-     t-avg  sum_rate     +/-   mag   +/-   UL3
  0      344   41413.9   7776.9  -3678.1    0.0000   0.0305 99.00 99.00   41413.9    0.0000   0.0305 99.00 99.00 19.42
=========================================================
================ Start New Filter UVM2 ==================
=========================================================
# ============ Reading file sw00021033002um2_sk.img ================
Use keyword TRIGTIME of 621780535.644 for trigger time.
Long-term sensitivity correction to zero point is -0.493 at 621819015
The processing date in extension 0 is:  2020-09-24T04:34:32
The trigger time is: 621780535.644. The reference is keyword in image file
Using zero point of 16.357 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(254.5120,-36.2914,25")
fk5;-circle(254.5120,-36.2914,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 m2621819014I  695.3   2049  5824  0.506  0.011
   1 m2621819014I   38478.9  1.00  695.3   38.0 108   2049  5824  0.000 0.010 99.00 19.7  0.0000 0.0099 99.00 19.7   695  0.000 14.393 99.00 0.013 
    Sum (T+ 38479 to  39185):              38.0         38.0 (est. in src region)   SNR_unwtd_sum:   0.00 0.999998555555556 signif. UL:  19.66
  0   695 621819368   38832.1    353.2   -353.2    0.0000   0.0099 99.000 99.000 -99.000
Total wtd_rate (for all exposures so far):  0.000 +/-10.217 snr:  0.0 mag: 99.00 UL: 12.13
Rebinned Data for sw00021033002um2_sk.img using a zero point of 16.357:
 No Exposure     t-avg        + / -       net_rate      +/-   mag   +/-     t-avg  sum_rate     +/-   mag   +/-   UL3
  0      695   38832.1    353.2   -353.2    0.0000   0.0099 99.00 99.00   38832.1    0.0000   0.0099 99.00 99.00 20.10
=========================================================
================ Start New Filter UVW2 ==================
=========================================================
# ============ Reading file sw00021033002uw2_sk.img ================
Use keyword TRIGTIME of 621780535.644 for trigger time.
Long-term sensitivity correction to zero point is -0.662 at 621818606
The processing date in extension 0 is:  2020-09-24T04:34:32
The trigger time is: 621780535.644. The reference is keyword in image file
Using zero point of 16.718 for filter UVW2
Use aperture correction of  1.108 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(254.5120,-36.2914,25")
fk5;-circle(254.5120,-36.2914,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 w2621818605I  314.7   1998  5828  1.089  0.024
   1 w2621818605I   38070.0  1.00  314.7   31.8 112   1998  5828  0.000 0.022 99.00 19.2  0.0000 0.0221 99.00 19.2   315  0.000 22.630 99.00 0.008 
High bkg:   2 w2621824294I  163.7   1031  5832  1.081  0.034
   2 w2621824294I   43759.0  1.00  163.7   26.9 116   1031  5832  0.000 0.031 99.00 18.8  0.0000 0.0180 99.00 19.4   478  0.000 19.231 99.00 0.008 
    Sum (T+ 38070 to  43925):              58.9         58.9 (est. in src region)   SNR_unwtd_sum:   0.00 0.999998555555556 signif. UL:  19.37
  0   478 621820686   40149.9   3775.4  -2079.9    0.0000   0.0180 99.000 99.000 -99.000
Total wtd_rate (for all exposures so far):  0.000 +/- 9.016 snr:  0.0 mag: 99.00 UL: 12.62
Rebinned Data for sw00021033002uw2_sk.img using a zero point of 16.718:
 No Exposure     t-avg        + / -       net_rate      +/-   mag   +/-     t-avg  sum_rate     +/-   mag   +/-   UL3
  0      477   40149.9   3775.3  -2079.9    0.0000   0.0180 99.00 99.00   40149.9    0.0000   0.0180 99.00 99.00 19.81
The data range from T+37735.8 s (0.44 d) to T+49190.8 s (0.57 d)
Wrote uvot_fluxes_200924d04h48m36s695377usUT.qdp
Wrote uvot_fluxes_200924d04h48m36s695377usUT.gif
Wrote uvot_fluxes_200924d04h48m36s695377usUT.ps
Wrote uvot_fluxes_200924d04h48m36s695377usUT_vis.qdp
Wrote uvot_fluxes_200924d04h48m36s695377usUT_uv.qdp
Wrote uvot_fluxes_200924d04h48m36s695377usUT_vis.gif
Wrote uvot_fluxes_200924d04h48m36s695377usUT_vis.ps
Wrote uvot_fluxes_200924d04h48m36s695377usUT_uv.gif
Wrote uvot_fluxes_200924d04h48m36s695377usUT_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 0.000746   40512.6   3240.9  -2612.7    0.0000   0.4565 99.00 99.00   40512.6    0.0000   0.4565 99.00 99.00 19.87
The data range from T+37735.8 s (0.44 d) to T+49190.8 s (0.57 d)
Wrote uvot_fluxes_wtd_200924d04h48m36s695377usUT.qdp
Wrote uvot_fluxes_wtd_200924d04h48m36s695377usUT.gif
Wrote uvot_fluxes_wtd_200924d04h48m36s695377usUT.ps
Found 6 exposures with unusual background rate
Normal end of uvot_fluxes_wget.pl vrs. 2018-11-07 fem