/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 179 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 = 7553
number of fields = 30
RA_SUN column already exists. File will not be modified.
Done.


Performing analysis on: 4FGL_J1245.1+5709_daily_bin749
RA = 191.288, Dec = 57.158
tmin = 433468801, tmax = 433728001
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='891469', job_status='RUN', time_executed='2021-09-06 04:14:10.478000', time_epoch_executed='1630926850.48' WHERE source_name='4FGL J1245.1+5709' and cadence='daily' and bin_id='749'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/891469

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/891469/ft1_4FGL_J1245.1+5709_daily_bin749.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/891469/ft2_4FGL_J1245.1+5709_daily_bin749.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/891469/ft1_4FGL_J1245.1+5709_daily_bin749.fits outfile=/scratch/kocevski/891469/ft1_filteredMKT_4FGL_J1245.1+5709_daily_bin749.fits ra=191.288 dec=57.158 rad=12.0 tmin=433468801.0 tmax=433728001.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 6.17
user 5.90
sys 0.23

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/891469/ft2_4FGL_J1245.1+5709_daily_bin749.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/891469/ft2_4FGL_J1245.1+5709_daily_bin749.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/891469/ft1_filteredMKT_4FGL_J1245.1+5709_daily_bin749.fits evtable="EVENTS" outfile="/scratch/kocevski/891469/ft1_filtered_4FGL_J1245.1+5709_daily_bin749.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.50
user 0.32
sys 0.16

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/891469/ft1_filtered_4FGL_J1245.1+5709_daily_bin749.fits" evtable="EVENTS" scfile=/scratch/kocevski/891469/ft2_4FGL_J1245.1+5709_daily_bin749.fits sctable="SC_DATA" outfile=/scratch/kocevski/891469/ltcube_433468801_433728001_4FGL_J1245.1+5709_daily_bin749.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/891469/ft2_4FGL_J1245.1+5709_daily_bin749.fits
.....................!
real 13.39
user 13.04
sys 0.32

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/891469/ft1_filtered_4FGL_J1245.1+5709_daily_bin749.fits evtable="EVENTS" scfile=/scratch/kocevski/891469/ft2_4FGL_J1245.1+5709_daily_bin749.fits sctable="SC_DATA" expcube=/scratch/kocevski/891469/ltcube_433468801_433728001_4FGL_J1245.1+5709_daily_bin749.fits outfile=/scratch/kocevski/891469/expmap_433468801_433728001_4FGL_J1245.1+5709_daily_bin749.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/891469/ltcube_433468801_433728001_4FGL_J1245.1+5709_daily_bin749.fits
.....................!
real 189.68
user 184.95
sys 4.39

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 217 point sources and 0 extended sources

Setting source of interest to:
4FGL J1245.1+5709 @ 191.288 57.158

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/891469/ft1_filtered_4FGL_J1245.1+5709_daily_bin749.fits scfile=/scratch/kocevski/891469/ft2_4FGL_J1245.1+5709_daily_bin749.fits outfile=/scratch/kocevski/891469/cmap_433468801_433728001_4FGL_J1245.1+5709_daily_bin749.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=191.288 yref=57.158 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.54
user 0.37
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/891469/ft1_filtered_4FGL_J1245.1+5709_daily_bin749.fits scfile=/scratch/kocevski/891469/ft2_4FGL_J1245.1+5709_daily_bin749.fits outfile=/scratch/kocevski/891469/cmap_HighResolution_433468801_433728001_4FGL_J1245.1+5709_daily_bin749.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=191.288 yref=57.158 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.54
user 0.38
sys 0.16

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/891469/ft1_filtered_4FGL_J1245.1+5709_daily_bin749.fits evtable="EVENTS" scfile=/scratch/kocevski/891469/ft2_4FGL_J1245.1+5709_daily_bin749.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/891469/Model_4FGL_J1245.1+5709_daily_bin749.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/891469/ft1_filtered_4FGL_J1245.1+5709_daily_bin749.fits......................!
real 29.20
user 27.86
sys 1.21

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/891469/ft1_filtered_4FGL_J1245.1+5709_daily_bin749.fits', '/scratch/kocevski/891469/ft2_4FGL_J1245.1+5709_daily_bin749.fits', expMap='/scratch/kocevski/891469/expmap_433468801_433728001_4FGL_J1245.1+5709_daily_bin749.fits', expCube='/scratch/kocevski/891469/ltcube_433468801_433728001_4FGL_J1245.1+5709_daily_bin749.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/891469/Model_4FGL_J1245.1+5709_daily_bin749.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1245.1+5709'

4FGL J1245.1+5709
   Spectrum: PowerLaw
355    Prefactor:  1.104e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
356        Index:  2.128e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
357        Scale:  1.843e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/891469/ft1_filtered_4FGL_J1245.1+5709_daily_bin749.fits
Spacecraft file(s): /scratch/kocevski/891469/ft2_4FGL_J1245.1+5709_daily_bin749.fits
Exposure map: /scratch/kocevski/891469/expmap_433468801_433728001_4FGL_J1245.1+5709_daily_bin749.fits
Exposure cube: /scratch/kocevski/891469/ltcube_433468801_433728001_4FGL_J1245.1+5709_daily_bin749.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/891469/Model_4FGL_J1245.1+5709_daily_bin749.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) = 2148.34276549

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    9.0898       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10046E-03   1.0000         .10000E-03   10000.    
     3 'norm      '    10.626       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .11372E-03   1.0000         .10000E-03   10000.    
     5 'norm      '    .10006E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10022E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10027E-03   1.0000         .10000E-03   10000.    
     9 'norm      '    1.5347       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10600E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10157E-03   1.0000         .10000E-03   10000.    
    12 'norm      '    .10435E-03   1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10806E-03   1.0000         .10000E-03   10000.    
    15 'norm      '    5.2780       1.0000         .10000E-03   10000.    
    16 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    7.3692       1.0000         .10000E-03   10000.    
    18 'Prefactor '    907.51       1.0000         .10000E-03   10000.    
    19 'Prefactor '    43.345       1.0000         .10000E-03   10000.    
    20 'norm      '    .99269       1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    21.255       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    24 'norm      '    6.6186       1.0000         .10000E-03   10000.    
    25 'Prefactor '    .10022E-03   1.0000         .10000E-03   10000.    
    26 'Prefactor '    4.6888       1.0000         .10000E-03   10000.    
    27 'Prefactor '    341.35       1.0000         .10000E-03   10000.    
    28 'Prefactor '    .10037E-03   1.0000         .10000E-03   10000.    
    29 'norm      '    .10452E-03   1.0000         .10000E-03   10000.    
    30 'norm      '    .10149E-03   1.0000         .10000E-03   10000.    
    31 'Prefactor '    170.99       1.0000         .10000E-03   10000.    
    32 'Normalizat'    .85572       1.0000         .10000E-01   10.000    
    33 'Prefactor '    .65060       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6920E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   2148.321     FROM MIGRAD    STATUS=CONVERGED    910 CALLS     5304 TOTAL
                     EDM=   .21E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  2.6%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     9.0866        8.5240       -.26865E-06    .21153E-04
   2  Prefactor     .10000E-03    25.546        .24267E-06** at limit **
   3  norm          10.632        18.500       -.62074E-06   -.31215E-05
   4  Prefactor     .10002E-03    3.2717        .12831E-05** at limit **
   5  norm          .10000E-03    9.4316        .11927E-06** at limit **
   6  Prefactor     .10000E-03    111.14       -.68174E-05** at limit **
   7  Prefactor     .10000E-03    5.0144        .39224E-07** at limit **
   8  Prefactor     .10000E-03    10.319        .39673E-07** at limit **
   9  norm          1.5341        4.1906       -.83690E-06   -.34583E-04
  10  Prefactor     .10000E-03    78.086        .38037E-05** at limit **
  11  Prefactor     .10000E-03    61.191        .83204E-06** at limit **
  12  norm          .10000E-03    47.447        .12722E-04** at limit **
  13  Prefactor     .10000E-03    16.017       -.34545E-06** at limit **
  14  Prefactor     .10001E-03    65.373        .44799E-06** at limit **
  15  norm          5.2749        5.7353        .46609E-06   -.15957E-03
  16  Prefactor     .10000E-03    17.085        .10417E-05** at limit **
  17  norm          7.3684        4.9783        .62379E-07    .60550E-04
  18  Prefactor     907.46        401.00        .12127E-05   -.27392E-05
  19  Prefactor     43.339        35.343        .32746E-06   -.31775E-04
  20  norm          .99285        12.245       -.35912E-05    .67852E-04
  21  Prefactor     .10000E-03    30.199        .13699E-05** at limit **
  22  Prefactor     21.261        58.832        .13119E-05    .46093E-04
  23  Prefactor     .10000E-03    18.754       -.40413E-06** at limit **
  24  norm          6.6187        6.1860        .13103E-07    .10279E-03
  25  Prefactor     .10000E-03    104.85       -.23823E-05** at limit **
  26  Prefactor     4.6886        6.3348        .10286E-06    .31440E-04
  27  Prefactor     341.39        194.97       -.23283E-05   -.34284E-05
  28  Prefactor     .10000E-03    7.1449        .19764E-07** at limit **
  29  norm          .10000E-03    302.09        .55765E-05** at limit **
  30  norm          .10000E-03    24.089       -.16373E-05** at limit **
  31  Prefactor     171.28        2119.0       -.23614E-04   -.22463E-05
  32  Normalizat    .85595        .24297        .15314E-05    .18506E-03
  33  Prefactor     .65029        .27968        .12636E-05    .11829E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 9.08658
  Prefactor  = 0.0001
  norm       = 10.6317
  Prefactor  = 0.000100016
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 1.53414
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.000100007
  norm       = 5.27492
  Prefactor  = 0.0001
  norm       = 7.36839
  Prefactor  = 907.46
  Prefactor  = 43.3385
  norm       = 0.992848
  Prefactor  = 0.0001
  Prefactor  = 21.261
  Prefactor  = 0.0001
  norm       = 6.61869
  Prefactor  = 0.0001
  Prefactor  = 4.68863
  Prefactor  = 341.394
  Prefactor  = 0.0001
  norm       = 0.000100002
  norm       = 0.0001
  Prefactor  = 171.281
  Normalizat = 0.855951
  Prefactor  = 0.65029
 **********
 **   18 **HESSE 
 **********

 FCN=   2148.321     FROM HESSE     STATUS=OK           687 CALLS     5991 TOTAL
                     EDM=   .96E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     9.0866        8.6094        .12194E-03   -1.5105    
   2  Prefactor     .10000E-03    25.620        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm          10.632        18.614        .12291E-03   -1.5056    
   4  Prefactor     .10002E-03    24.530        .14984E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  norm          .10000E-03    9.6873        .27686E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    114.95        .36285E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10000E-03    5.0206        .10136E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .10000E-03    10.321        .14544E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  norm          1.5341        4.1889        .13956E-03   -1.5460    
  10  Prefactor     .10000E-03    78.291        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .10000E-03    61.216        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  norm          .10000E-03    47.177        .27830E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     .10000E-03    16.045        .18122E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     .10001E-03    66.608        .36285E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  norm          5.2749        5.7000        .10781E-03   -1.5249    
  16  Prefactor     .10000E-03    17.144        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          7.3684        4.9792        .82151E-04   -1.5165    
  18  Prefactor     907.46        400.31        .69625E-04   -.95881    
  19  Prefactor     43.339        35.370        .60892E-04   -1.4390    
  20  norm          .99285        12.647        .30235E-03   -1.5509    
  21  Prefactor     .10000E-03    30.279        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     21.261        58.603        .86878E-04   -1.4785    
  23  Prefactor     .10000E-03    18.781        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  norm          6.6187        6.1840        .10754E-03   -1.5193    
  25  Prefactor     .10000E-03    105.05        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  Prefactor     4.6886        6.3323        .13221E-03   -1.5275    
  27  Prefactor     341.39        195.24        .11015E-03   -1.1991    
  28  Prefactor     .10000E-03    7.1454        .12101E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  29  norm          .10000E-03    304.27        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  30  norm          .10000E-03    24.757        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  31  Prefactor     171.28        2143.2        .15427E-03   -1.3083    
  32  Normalizat    .85595        .28328        .20972E-03   -.98026    
  33  Prefactor     .65029        .32652        .28768E-03   -1.0551    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 9.58414e-10
Minuit parameter uncertainties:
  1  8.61054
  2  2.95925e-05
  3  18.6238
  4  0.00126711
  5  5.43706e-05
  6  0.000322072
  7  8.41853e-06
  8  8.76342e-06
  9  4.18966
  10  0.000232952
  11  6.91992e-06
  12  1.25308e-05
  13  2.99626e-05
  14  0.00138621
  15  5.70054
  16  5.56613e-05
  17  4.97947
  18  401.621
  19  35.3867
  20  7.08845
  21  8.79991e-05
  22  58.7619
  23  1.60572e-05
  24  6.18455
  25  0.000216181
  26  6.33325
  27  195.619
  28  1.84753e-06
  29  0.00151917
  30  3.0279e-05
  31  1272.88
  32  0.283774
  33  0.327479
Done.

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

Extracting fit parameters...

4FGL J1245.1+5709
   Spectrum: PowerLaw
355    Prefactor:  1.000e-04  1.386e-03  1.000e-04  1.000e+04 ( 1.000e-13)
356        Index:  2.128e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
357        Scale:  1.843e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
689    Prefactor:  6.503e-01  3.275e-01  0.000e+00  1.000e+01 ( 1.000e+00)
690        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
691        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
688   Normalization:  8.560e-01  2.838e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 191.288 57.158
Photon Flux Upper Limit: 1.86e-07 ph cm-2 s-1
Energy Flux Upper Limit: 1.41e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/891469/likelihoodResults_433468801_433728001_4FGL_J1245.1+5709_daily_bin749.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): 102
logL (Free Index) = 2148.32062447
delta logL = -7.12506334821e-05

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 2148.10922122
delta logL = 0.211331996853

Fit tolerance = 1e-08

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

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

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   2148.109     FROM MIGRAD    STATUS=CONVERGED     54 CALLS      274 TOTAL
                     EDM=   .16E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .55908        25.863        .11511E-01    .47245E-03
   2  Index         3.5433        3.7420        .92270E-01    .67432E-04
   3  Normalizat    .81581        .50556E-01    .43816E-01    .27864E-05
   4  Prefactor     .67514        .61440E-01    .63810E-01    .61140E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.559079
  Index      = 3.54333
  Normalizat = 0.815808
  Prefactor  = 0.675143
 **********
 **   18 **HESSE 
 **********

 FCN=   2148.109     FROM HESSE     STATUS=NOT POSDEF    33 CALLS      307 TOTAL
                     EDM=   .45E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .55908        79.023        .56874E-04   -1.5558    
   2  Index         3.5433        6.1653        .50205E-02   -.29562    
   3  Normalizat    .81581        .23923        .21371E-03   -.99485    
   4  Prefactor     .67514        .28606        .28230E-03   -1.0451    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 4.48704e-10
Minuit parameter uncertainties:
  1  13.3104
  2  9.50185
  3  0.239535
  4  0.28668
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/891469': 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): 102
logL (Free Index) = 2148.1092212
delta logL = 0.21133201766

Extracting fit parameters...

4FGL J1245.1+5709
   Spectrum: PowerLaw
355    Prefactor:  5.591e-01  1.331e+01  1.000e-04  1.000e+04 ( 1.000e-13)
356        Index:  3.543e+00  9.502e+00  0.000e+00  1.000e+01 (-1.000e+00)
357        Scale:  1.843e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
689    Prefactor:  6.751e-01  2.867e-01  0.000e+00  1.000e+01 ( 1.000e+00)
690        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
691        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
688   Normalization:  8.158e-01  2.395e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 191.288 57.158

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/891469/cmap_HighResolution_433468801_433728001_4FGL_J1245.1+5709_daily_bin749.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='1.41e-02', job_status='DONE', photon_flux_upper_limit='1.86e-07', time_completed='2021-09-06 04:24:31.093857', job_id='891469', GAL2='0.68', fit_tolerance='1e-08', EG2='0.82', EG='0.86', time_epoch_completed='1630927471.09', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.65', dlogl='2.11e-01', ts2='0.44', photon_index_error='0.00', photon_index='2.13' WHERE bin_id='749' AND source_name='4FGL J1245.1+5709' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 04:24:31 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0103>
Subject: Job 891469: <4FGL_J1245.1+5709_daily_bin749> in cluster <slac> Done

Job <4FGL_J1245.1+5709_daily_bin749> was submitted from host <rhel6-64a> by user <kocevski> in cluster <slac> at Mon Sep  6 04:10:54 2021
Job was executed on host(s) <bullet0103>, in queue <medium>, as user <kocevski> in cluster <slac> at Mon Sep  6 04:10:56 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Mon Sep  6 04:10:56 2021
Terminated at Mon Sep  6 04:24:34 2021
Results reported at Mon Sep  6 04:24:34 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1245.1+5709_daily_bin749 191.288 57.158 433468801 433728001 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1245.1+5709 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   618.23 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             232.20 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   815 sec.
    Turnaround time :                            820 sec.

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

