/nfs/farm/g/glast/g/LCRepository/bin/miniconda2/envs/fermitools_v1.0.5/lib/python2.7/site-packages/pyfits/__init__.py:22: PyFITSDeprecationWarning: PyFITS is deprecated, please use astropy.io.fits
  PyFITSDeprecationWarning)  # noqa

Likelihood Analysis Tool
Support Contact: Daniel Kocevski (daniel.kocevski@nasa.gov)


Waiting 4 seconds before starting...
Proceeding.

Importing modules...
This is make3FGLxml version 01r0.
The default diffuse model files and names are for pass 8 and assume you have v10r00p05 of the Fermi Science Tools or higher.
This is make4FGLxml version 01r04.
The default diffuse model files and names are for pass 8 and 4FGL and assume you have v11r5p3 of the Fermi Science Tools or higher.

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

/nfs/farm/g/glast/g/LCRepository/bin/miniconda2/envs/fermitools_v1.0.5/lib/python2.7/site-packages/matplotlib/cbook/deprecation.py:106: MatplotlibDeprecationWarning: The mpl_toolkits.axes_grid module was deprecated in version 2.1. Use mpl_toolkits.axes_grid1 and mpl_toolkits.axisartist provies the same functionality instead.
  warnings.warn(message, mplDeprecation, stacklevel=1)

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

number of points = 7487
number of fields = 22
No RA_SUN column yet. Adding RA_SUN/DEC_SUN columns.
Done.


Performing analysis on: 4FGL_J1606.9+5919_daily_bin37
RA = 241.734, Dec = 59.3201
tmin = 248918401, tmax = 249177601
emin = 100.0, emax = 100000.0
irfs = P8R3_SOURCE_V2
ROI = 12
zmax = 90

Fitting strategies:
Fix sources to their catalog values = True
Leave variable source normalizations free = True
Perform pre-fit where ALL sources are frozen to catalog values = False
Perform secondary fit with a free spectral index = True
Remove all catalog sources = False
Remove weak (TS < 2) catalog sources = False
Freeze Galactic component = False

Likelihood fit parameters:
Statistic: UNBINNED
Optimizer: MINUIT

Catalog: 4FGL

Repository Job = True

LAT data Source:
Data catalog

Updating database...

UPDATE lightcurve_data_v2 SET job_id='18558', job_status='RUN', time_executed='2021-09-13 07:41:08.481304', time_epoch_executed='1631544068.48' WHERE source_name='4FGL J1606.9+5919' and cadence='daily' and bin_id='37'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/18558

Creating custom pfile directory:
/scratch/kocevski/18558/pfiles/

Retrieving the FT1 file...

Issuing command:
/afs/slac.stanford.edu/g/glast/ground/bin/datacat find --group FT1 --filter 'nMetStop>=248918401.0 && nMetStart<249177601.0' /Data/Flight/Reprocess/P305

Issuing command:
/afs/slac.stanford.edu/g/glast/ground/bin/datacat find --group FT1 --filter 'nMetStart>564945418 && nMetStop>=248918401.0 && nMetStart<249177601.0' /Data/Flight/Level1/LPA

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/18558/ft1_4FGL_J1606.9+5919_daily_bin37.fits


Retrieving the FT1 file...

Issuing command:
/afs/slac.stanford.edu/g/glast/ground/bin/datacat find --group FT2 --filter 'nMetStop>=248918401.0 && nMetStart<249177601.0' /Data/Flight/Level1/LPA

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/18558/ft2_4FGL_J1606.9+5919_daily_bin37.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/18558/ft1_4FGL_J1606.9+5919_daily_bin37.fits outfile=/scratch/kocevski/18558/ft1_filteredMKT_4FGL_J1606.9+5919_daily_bin37.fits ra=241.734 dec=59.3201 rad=12.0 tmin=248918401.0 tmax=249177601.0 emin=100.0 emax=100000.0 zmin=0.0 zmax=90.0 evclass=128 evtype="INDEF" convtype=-1 phasemin=0.0 phasemax=1.0 evtable="EVENTS" chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

Done.
real 1.96
user 1.78
sys 0.16

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/18558/ft2_4FGL_J1606.9+5919_daily_bin37.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/18558/ft2_4FGL_J1606.9+5919_daily_bin37.fits sctable="SC_DATA" filter="IN_SAA!=T && LIVETIME>0 && gtifilter('/nfs/farm/g/glast/g/LCRepository/Likelihood/GTIs/nogrb.gti',(START+STOP)/2) && (angsep(RA_SUN,DEC_SUN,RA_ZENITH,DEC_ZENITH)>115 || gtifilter('/nfs/farm/g/glast/g/LCRepository/Likelihood/GTIs/nosolarflares.gti',(START+STOP)/2))" roicut=no evfile=/scratch/kocevski/18558/ft1_filteredMKT_4FGL_J1606.9+5919_daily_bin37.fits evtable="EVENTS" outfile="/scratch/kocevski/18558/ft1_filtered_4FGL_J1606.9+5919_daily_bin37.fits" apply_filter=yes overwrite=yes header_obstimes=yes tstart=0.0 tstop=0.0 gtifile="default" chatter=3 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

This is gtmktime version HEAD
Applying GTI filter:
IN_SAA!=T && LIVETIME>0 && gtifilter('/nfs/farm/g/glast/g/LCRepository/Likelihood/GTIs/nogrb.gti',(START+STOP)/2) && (angsep(RA_SUN,DEC_SUN,RA_ZENITH,DEC_ZENITH)>115 || gtifilter('/nfs/farm/g/glast/g/LCRepository/Likelihood/GTIs/nosolarflares.gti',(START+STOP)/2))
real 0.49
user 0.33
sys 0.14

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/18558/ft1_filtered_4FGL_J1606.9+5919_daily_bin37.fits" evtable="EVENTS" scfile=/scratch/kocevski/18558/ft2_4FGL_J1606.9+5919_daily_bin37.fits sctable="SC_DATA" outfile=/scratch/kocevski/18558/ltcube_248918401_249177601_4FGL_J1606.9+5919_daily_bin37.fits dcostheta=0.025 binsz=1.0 phibins=0 tmin=0.0 tmax=0.0 file_version="1" zmin=0.0 zmax=90.0 chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

Working on file /scratch/kocevski/18558/ft2_4FGL_J1606.9+5919_daily_bin37.fits
.....................!
real 14.19
user 13.77
sys 0.29

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/18558/ft1_filtered_4FGL_J1606.9+5919_daily_bin37.fits evtable="EVENTS" scfile=/scratch/kocevski/18558/ft2_4FGL_J1606.9+5919_daily_bin37.fits sctable="SC_DATA" expcube=/scratch/kocevski/18558/ltcube_248918401_249177601_4FGL_J1606.9+5919_daily_bin37.fits outfile=/scratch/kocevski/18558/expmap_248918401_249177601_4FGL_J1606.9+5919_daily_bin37.fits irfs="P8R3_SOURCE_V2" evtype="INDEF" srcrad=30.0 nlong=88 nlat=88 nenergies=10 submap=no nlongmin=0 nlongmax=0 nlatmin=0 nlatmax=0 chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

The exposure maps generated by this tool are meant
to be used for *unbinned* likelihood analysis only.
Do not use them for binned analyses.
Computing the ExposureMap using /scratch/kocevski/18558/ltcube_248918401_249177601_4FGL_J1606.9+5919_daily_bin37.fits
.....................!
real 191.45
user 186.33
sys 4.60

Generating the xml model:
radLim = 0.001
maxRad = 12
normsOnly = True
freeVariableSources = True
Fixing all sources to their catalog values, except variable sources
Creating file and adding sources from 4FGL
Added 221 point sources and 0 extended sources

Setting source of interest to:
4FGL J1606.9+5919 @ 241.734 59.3201

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/18558/ft1_filtered_4FGL_J1606.9+5919_daily_bin37.fits scfile=/scratch/kocevski/18558/ft2_4FGL_J1606.9+5919_daily_bin37.fits outfile=/scratch/kocevski/18558/cmap_248918401_249177601_4FGL_J1606.9+5919_daily_bin37.fits algorithm="CMAP" ebinalg="LOG" emin=30.0 emax=200000.0 ebinfile=NONE tbinalg="LIN" tbinfile=NONE nxpix=160 nypix=160 binsz=0.25 coordsys="CEL" xref=241.734 yref=59.3201 axisrot=0.0 rafield="RA" decfield="DEC" proj="AIT" hpx_ordering_scheme="RING" hpx_order=3 hpx_ebin=yes hpx_region="" evtable="EVENTS" sctable="SC_DATA" efield="ENERGY" tfield="TIME" chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

This is gtbin version HEAD
real 0.61
user 0.37
sys 0.16

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/18558/ft1_filtered_4FGL_J1606.9+5919_daily_bin37.fits scfile=/scratch/kocevski/18558/ft2_4FGL_J1606.9+5919_daily_bin37.fits outfile=/scratch/kocevski/18558/cmap_HighResolution_248918401_249177601_4FGL_J1606.9+5919_daily_bin37.fits algorithm="CMAP" ebinalg="LOG" emin=30.0 emax=200000.0 ebinfile=NONE tbinalg="LIN" tbinfile=NONE nxpix=500 nypix=500 binsz=0.1 coordsys="CEL" xref=241.734 yref=59.3201 axisrot=0.0 rafield="RA" decfield="DEC" proj="AIT" hpx_ordering_scheme="RING" hpx_order=3 hpx_ebin=yes hpx_region="" evtable="EVENTS" sctable="SC_DATA" efield="ENERGY" tfield="TIME" chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

This is gtbin version HEAD
real 0.55
user 0.40
sys 0.14

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/18558/ft1_filtered_4FGL_J1606.9+5919_daily_bin37.fits evtable="EVENTS" scfile=/scratch/kocevski/18558/ft2_4FGL_J1606.9+5919_daily_bin37.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/18558/Model_4FGL_J1606.9+5919_daily_bin37.xml irfs="P8R3_SOURCE_V2" evclsmin=0 evclass="INDEF" evtype="INDEF" convert=yes chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

adding source EG_v02
adding source GAL_V02
Working on...
/scratch/kocevski/18558/ft1_filtered_4FGL_J1606.9+5919_daily_bin37.fits.....................!
real 46.96
user 45.60
sys 1.21

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/18558/ft1_filtered_4FGL_J1606.9+5919_daily_bin37.fits', '/scratch/kocevski/18558/ft2_4FGL_J1606.9+5919_daily_bin37.fits', expMap='/scratch/kocevski/18558/expmap_248918401_249177601_4FGL_J1606.9+5919_daily_bin37.fits', expCube='/scratch/kocevski/18558/ltcube_248918401_249177601_4FGL_J1606.9+5919_daily_bin37.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/18558/Model_4FGL_J1606.9+5919_daily_bin37.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1606.9+5919'

4FGL J1606.9+5919
   Spectrum: PowerLaw
329    Prefactor:  2.197e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-14)
330        Index:  2.114e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
331        Scale:  2.350e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/18558/ft1_filtered_4FGL_J1606.9+5919_daily_bin37.fits
Spacecraft file(s): /scratch/kocevski/18558/ft2_4FGL_J1606.9+5919_daily_bin37.fits
Exposure map: /scratch/kocevski/18558/expmap_248918401_249177601_4FGL_J1606.9+5919_daily_bin37.fits
Exposure cube: /scratch/kocevski/18558/ltcube_248918401_249177601_4FGL_J1606.9+5919_daily_bin37.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/18558/Model_4FGL_J1606.9+5919_daily_bin37.xml
Optimizer: MINUIT
Statistic: UNBINNED

Performing an iterative likelihood fit...

Fit tolerance = 1

Performing likelihood fit...
Done.

MINUIT Return Code (Fixed Index): 0
logL (Fixed Index) = 5272.88222118

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Fixed Index): 0
logL (Fixed Index) = 5272.81953605

Fit tolerance = 1e-08

Performing likelihood fit...
 **********
 **   14 **SET NOWARN 
 **********

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    12.416       1.0000         .10000E-03   10000.    
     4 'Prefactor '    35.906       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10085E-03   1.0000         .10000E-03   10000.    
     6 'norm      '    4.7698       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    22.657       1.0000         .10000E-03   10000.    
     9 'norm      '    .10006E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    16.451       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    .62293       1.0000         .10000E-03   10000.    
    13 'norm      '    28.785       1.0000         .10000E-03   10000.    
    14 'Prefactor '    .19198E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10016E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    9.5100       1.0000         .10000E-03   10000.    
    17 'Prefactor '    1.4480       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10165E-02   1.0000         .10000E-03   10000.    
    19 'Prefactor '    24.323       1.0000         .10000E-03   10000.    
    20 'norm      '    .45279       1.0000         .10000E-03   10000.    
    21 'Prefactor '    2.9481       1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10015E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    .15147E-01   1.0000         .10000E-03   10000.    
    24 'Prefactor '    1.6285       1.0000         .10000E-03   10000.    
    25 'Prefactor '    .10131E-03   1.0000         .10000E-03   10000.    
    26 'Normalizat'    .96300       1.0000         .10000E-01   10.000    
    27 'Prefactor '    .98550       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .7060E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   5272.819     FROM MIGRAD    STATUS=CONVERGED    679 CALLS     2902 TOTAL
                     EDM=   .69E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  4.4%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    22.045       -.19751E-06** at limit **
   2  Prefactor     .10000E-03    21.281        .94003E-06** at limit **
   3  Prefactor     12.424        10.762        .42319E-06    .14738E-03
   4  Prefactor     35.910        25.724       -.79774E-08   -.27696E-05
   5  Prefactor     .10000E-03    23.127        .20541E-07** at limit **
   6  norm          4.7704        3.7174        .61832E-07    .44254E-04
   7  Prefactor     .10000E-03    47.871       -.13295E-05** at limit **
   8  Prefactor     22.659        11.054        .55991E-07   -.39999E-04
   9  norm          .10000E-03    2.8115        .11687E-07** at limit **
  10  Prefactor     16.451        25.128        .13671E-06   -.13527E-04
  11  Prefactor     .10000E-03    24.360        .82207E-06** at limit **
  12  Prefactor     .62265        4.0419       -.48556E-07   -.95244E-04
  13  norm          28.784        21.303        .23675E-06   -.13892E-04
  14  Prefactor     .10005E-03    8.7840        .21557E-05** at limit **
  15  Prefactor     .10000E-03    81.677        .70710E-07** at limit **
  16  norm          9.5109        10.567        .49770E-06    .10451E-04
  17  Prefactor     1.4467        3.5769        .17663E-06   -.35078E-04
  18  Prefactor     .10001E-03    6.9993        .45626E-06** at limit **
  19  Prefactor     24.340        20.772        .98064E-06    .33597E-04
  20  norm          .45230        .87990       -.19771E-06   -.93470E-03
  21  Prefactor     2.9543        9.7519       -.26232E-05   -.29744E-03
  22  Prefactor     .10000E-03    20.935       -.22841E-05** at limit **
  23  Prefactor     .10001E-03    115.83        .43371E-05** at limit **
  24  Prefactor     1.6286        19.005       -.69549E-06   -.12632E-03
  25  Prefactor     .10001E-03    398.86        .80883E-05** at limit **
  26  Normalizat    .96271        .21877        .10590E-05   -.35967E-03
  27  Prefactor     .98579        .19080       -.12036E-05   -.34449E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 12.4237
  Prefactor  = 35.9105
  Prefactor  = 0.0001
  norm       = 4.77041
  Prefactor  = 0.0001
  Prefactor  = 22.6585
  norm       = 0.0001
  Prefactor  = 16.4512
  Prefactor  = 0.0001
  Prefactor  = 0.622653
  norm       = 28.7841
  Prefactor  = 0.000100049
  Prefactor  = 0.0001
  norm       = 9.51088
  Prefactor  = 1.44668
  Prefactor  = 0.00010001
  Prefactor  = 24.3399
  norm       = 0.452301
  Prefactor  = 2.95427
  Prefactor  = 0.000100001
  Prefactor  = 0.000100009
  Prefactor  = 1.62859
  Prefactor  = 0.000100007
  Normalizat = 0.962708
  Prefactor  = 0.985788
 **********
 **   18 **HESSE 
 **********

 FCN=   5272.819     FROM HESSE     STATUS=OK           502 CALLS     3404 TOTAL
                     EDM=   .16E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    22.295        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     .10000E-03    21.582        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     12.424        10.842        .11368E-03   -1.5003    
   4  Prefactor     35.910        25.781        .66880E-04   -1.4509    
   5  Prefactor     .10000E-03    23.138        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  norm          4.7704        3.7145        .11868E-03   -1.5271    
   7  Prefactor     .10000E-03    47.944        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     22.659        11.071        .84150E-04   -1.4756    
   9  norm          .10000E-03    2.8146        .11886E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     16.451        25.124        .98746E-04   -1.4897    
  11  Prefactor     .10000E-03    24.387        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .62265        17.723        .26645E-02   -1.5550    
  13  norm          28.784        21.374        .37337E-03   -1.4634    
  14  Prefactor     .10005E-03    19.196        .32450E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .10000E-03    82.002        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          9.5109        10.571        .12995E-03   -1.5091    
  17  Prefactor     1.4467        3.5334        .20392E-03   -1.5467    
  18  Prefactor     .10001E-03    30.861        .35806E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     24.340        20.806        .81223E-04   -1.4721    
  20  norm          .45230        .86615        .84387E-04   -1.5573    
  21  Prefactor     2.9543        9.8368        .23654E-03   -1.5364    
  22  Prefactor     .10000E-03    20.858        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .10001E-03    10.887        .51404E-01   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     1.6286        21.686        .16572E-02   -1.5453    
  25  Prefactor     .10001E-03    401.73        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  Normalizat    .96271        .25568        .25652E-03   -.94290    
  27  Prefactor     .98579        .22325        .23945E-03   -.93205    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.62945e-08
Minuit parameter uncertainties:
  1  9.68342e-06
  2  0.00010832
  3  10.8436
  4  25.7888
  5  3.90923e-06
  6  3.71467
  7  0.000250035
  8  11.0718
  9  1.61152e-06
  10  25.14
  11  0.000106245
  12  6.64559
  13  21.3796
  14  0.00193292
  15  7.27042e-05
  16  10.5726
  17  3.53395
  18  0.00112628
  19  20.8121
  20  0.866175
  21  9.84214
  22  0.000222995
  23  0.000622601
  24  11.8905
  25  0.0034891
  26  0.256006
  27  0.223459
Done.

MINUIT Return Code (Fixed Index): 0
logL (Fixed Index) = 5272.81945182

Extracting fit parameters...

4FGL J1606.9+5919
   Spectrum: PowerLaw
329    Prefactor:  1.645e+01  2.514e+01  1.000e-04  1.000e+04 ( 1.000e-14)
330        Index:  2.114e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
331        Scale:  2.350e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
703    Prefactor:  9.858e-01  2.235e-01  0.000e+00  1.000e+01 ( 1.000e+00)
704        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
705        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
702   Normalization:  9.627e-01  2.560e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.77
Ra Dec: 241.734 59.320
Photon Flux Upper Limit: 7.07e-08 ph cm-2 s-1
Energy Flux Upper Limit: 5.35e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/18558/likelihoodResults_248918401_249177601_4FGL_J1606.9+5919_daily_bin37.txt

Performing a free index iterative likelihood fit...

Freezing all point sources, except source of interest...

Done.

Freeing candidate source...
Done.

Fit tolerance = 1

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 5272.75035022
delta logL = 0.0691016017727

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 5272.74982225
delta logL = 0.0696295763146

Fit tolerance = 1e-08

Performing likelihood fit...
 **********
 **   14 **SET NOWARN 
 **********

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    7.4554       1.0000         .10000E-03   10000.    
     2 'Index     '    2.7098       1.0000          .0000       10.000    
     3 'Normalizat'    .94792       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .99460       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .7060E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.
 MACHINE ACCURACY LIMITS FURTHER IMPROVEMENT.

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.
 MIGRAD TERMINATED WITHOUT CONVERGENCE.

 FCN=   5272.750     FROM MIGRAD    STATUS=FAILED       106 CALLS      313 TOTAL
                     EDM=   .98E-06    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     7.4139        700.85        .73442E-03   -.48885E-04
   2  Index         2.7141        5.4809        .85866E-02    .40233E-03
   3  Normalizat    .94775        .34988        .25831E-03   -.36046E-04
   4  Prefactor     .99473        .26743        .23849E-03   -.40900E-04
                               ERR DEF=  .500    
 START SIMPLEX MINIMIZATION.    CONVERGENCE WHEN EDM .LT.   .20E-04
 SIMPLEX MINIMIZATION HAS CONVERGED.

 FCN=   5272.750     FROM SIMPLEX   STATUS=UNCHANGED     89 CALLS      402 TOTAL
                     EDM=   .18E-04    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     7.4139        700.85        .36484E-03   -.48885E-04
   2  Index         2.7141        5.4809        .21265E-02    .40233E-03
   3  Normalizat    .94775        .34988        .12840E-03   -.36046E-04
   4  Prefactor     .99473        .26743        .14973E-03   -.40900E-04
                               ERR DEF=  .500    

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   5272.750     FROM MIGRAD    STATUS=CONVERGED     36 CALLS      438 TOTAL
                     EDM=   .41E-11    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     7.4139        26.634        .29377E-04   -.44195E-04
   2  Index         2.7141        1.8884        .17173E-02   -.10486E-04
   3  Normalizat    .94775        .23553        .10332E-04   -.34109E-04
   4  Prefactor     .99473        .21840        .95396E-05   -.38612E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 7.4139
  Index      = 2.71409
  Normalizat = 0.947753
  Prefactor  = 0.994732
 **********
 **   18 **HESSE 
 **********

 FCN=   5272.750     FROM HESSE     STATUS=OK            23 CALLS      461 TOTAL
                     EDM=   .44E-11    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     7.4139        24.268        .58753E-05   -1.5163    
   2  Index         2.7141        1.7286        .68693E-04   -.47482    
   3  Normalizat    .94775        .23391        .20665E-05   -.94802    
   4  Prefactor     .99473        .21748        .19079E-05   -.92905    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 4.36096e-12
Minuit parameter uncertainties:
  1  24.3007
  2  1.77544
  3  0.234164
  4  0.217669
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/18558': No such file or directory
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 5272.74981855
delta logL = 0.0696332770858

Extracting fit parameters...

4FGL J1606.9+5919
   Spectrum: PowerLaw
329    Prefactor:  7.414e+00  2.430e+01  1.000e-04  1.000e+04 ( 1.000e-14)
330        Index:  2.714e+00  1.775e+00  0.000e+00  1.000e+01 (-1.000e+00)
331        Scale:  2.350e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
703    Prefactor:  9.947e-01  2.177e-01  0.000e+00  1.000e+01 ( 1.000e+00)
704        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
705        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
702   Normalization:  9.478e-01  2.342e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 0.77
Ra Dec: 241.734 59.320

Creating a high resolution counts map...
INFO: Auto-setting vmin to  0.000e+00 [aplpy.core]
INFO: Auto-setting vmax to  0.000e+00 [aplpy.core]
Saving /scratch/kocevski/18558/cmap_HighResolution_248918401_249177601_4FGL_J1606.9+5919_daily_bin37.png

Cleaning up...

** Nuclear option initiated! **
rmdir /scratch/kocevski/18558

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='5.35e-03', job_status='DONE', photon_flux_upper_limit='7.07e-08', time_completed='2021-09-13 07:53:55.961376', job_id='18558', GAL2='0.99', fit_tolerance='1e-08', EG2='0.95', EG='0.96', time_epoch_completed='1631544835.96', return_code2='0', ts='0.77', comment='SUCCESS', return_code='0', GAL='0.99', dlogl='6.96e-02', ts2='0.92', photon_index_error='0.00', photon_index='2.11' WHERE bin_id='37' AND source_name='4FGL J1606.9+5919' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep 13 07:53:55 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0280>
Subject: Job 18558: <4FGL_J1606.9+5919_daily_bin37> in cluster <slac> Done

Job <4FGL_J1606.9+5919_daily_bin37> was submitted from host <rhel6-64e> by user <kocevski> in cluster <slac> at Mon Sep 13 07:40:27 2021
Job was executed on host(s) <bullet0280>, in queue <medium>, as user <kocevski> in cluster <slac> at Mon Sep 13 07:40:51 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Mon Sep 13 07:40:51 2021
Terminated at Mon Sep 13 07:53:56 2021
Results reported at Mon Sep 13 07:53:56 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1606.9+5919_daily_bin37 241.734 59.3201 248918401 249177601 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1606.9+5919 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   764.03 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             338.04 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   785 sec.
    Turnaround time :                            809 sec.

The output (if any) is above this job summary.

