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


Performing analysis on: 4FGL_J1040.5+0617_daily_bin532
RA = 160.15, Dec = 6.2848
tmin = 377222401, tmax = 377481601
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='64461', job_status='RUN', time_executed='2021-09-02 08:22:19.459507', time_epoch_executed='1630596139.46' WHERE source_name='4FGL J1040.5+0617' and cadence='daily' and bin_id='532'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/64461

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/64461/ft1_4FGL_J1040.5+0617_daily_bin532.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/64461/ft2_4FGL_J1040.5+0617_daily_bin532.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/64461/ft1_4FGL_J1040.5+0617_daily_bin532.fits outfile=/scratch/kocevski/64461/ft1_filteredMKT_4FGL_J1040.5+0617_daily_bin532.fits ra=160.15 dec=6.2848 rad=12.0 tmin=377222401.0 tmax=377481601.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 3.46
user 3.24
sys 0.19

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/64461/ft2_4FGL_J1040.5+0617_daily_bin532.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/64461/ft2_4FGL_J1040.5+0617_daily_bin532.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/64461/ft1_filteredMKT_4FGL_J1040.5+0617_daily_bin532.fits evtable="EVENTS" outfile="/scratch/kocevski/64461/ft1_filtered_4FGL_J1040.5+0617_daily_bin532.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.51
user 0.36
sys 0.14

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/64461/ft1_filtered_4FGL_J1040.5+0617_daily_bin532.fits" evtable="EVENTS" scfile=/scratch/kocevski/64461/ft2_4FGL_J1040.5+0617_daily_bin532.fits sctable="SC_DATA" outfile=/scratch/kocevski/64461/ltcube_377222401_377481601_4FGL_J1040.5+0617_daily_bin532.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/64461/ft2_4FGL_J1040.5+0617_daily_bin532.fits
.....................!
real 14.31
user 13.93
sys 0.30

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/64461/ft1_filtered_4FGL_J1040.5+0617_daily_bin532.fits evtable="EVENTS" scfile=/scratch/kocevski/64461/ft2_4FGL_J1040.5+0617_daily_bin532.fits sctable="SC_DATA" expcube=/scratch/kocevski/64461/ltcube_377222401_377481601_4FGL_J1040.5+0617_daily_bin532.fits outfile=/scratch/kocevski/64461/expmap_377222401_377481601_4FGL_J1040.5+0617_daily_bin532.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/64461/ltcube_377222401_377481601_4FGL_J1040.5+0617_daily_bin532.fits
.....................!
real 190.56
user 185.97
sys 3.98

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

Setting source of interest to:
4FGL J1040.5+0617 @ 160.15 6.2848

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/64461/ft1_filtered_4FGL_J1040.5+0617_daily_bin532.fits scfile=/scratch/kocevski/64461/ft2_4FGL_J1040.5+0617_daily_bin532.fits outfile=/scratch/kocevski/64461/cmap_377222401_377481601_4FGL_J1040.5+0617_daily_bin532.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=160.15 yref=6.2848 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.38
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/64461/ft1_filtered_4FGL_J1040.5+0617_daily_bin532.fits scfile=/scratch/kocevski/64461/ft2_4FGL_J1040.5+0617_daily_bin532.fits outfile=/scratch/kocevski/64461/cmap_HighResolution_377222401_377481601_4FGL_J1040.5+0617_daily_bin532.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=160.15 yref=6.2848 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.59
user 0.42
sys 0.14

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/64461/ft1_filtered_4FGL_J1040.5+0617_daily_bin532.fits evtable="EVENTS" scfile=/scratch/kocevski/64461/ft2_4FGL_J1040.5+0617_daily_bin532.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/64461/Model_4FGL_J1040.5+0617_daily_bin532.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/64461/ft1_filtered_4FGL_J1040.5+0617_daily_bin532.fits.....................!
real 66.44
user 65.06
sys 1.14

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/64461/ft1_filtered_4FGL_J1040.5+0617_daily_bin532.fits', '/scratch/kocevski/64461/ft2_4FGL_J1040.5+0617_daily_bin532.fits', expMap='/scratch/kocevski/64461/expmap_377222401_377481601_4FGL_J1040.5+0617_daily_bin532.fits', expCube='/scratch/kocevski/64461/ltcube_377222401_377481601_4FGL_J1040.5+0617_daily_bin532.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/64461/Model_4FGL_J1040.5+0617_daily_bin532.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1040.5+0617'

4FGL J1040.5+0617
   Spectrum: PowerLaw
216    Prefactor:  2.877e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-12)
217        Index:  2.368e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
218        Scale:  8.643e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/64461/ft1_filtered_4FGL_J1040.5+0617_daily_bin532.fits
Spacecraft file(s): /scratch/kocevski/64461/ft2_4FGL_J1040.5+0617_daily_bin532.fits
Exposure map: /scratch/kocevski/64461/expmap_377222401_377481601_4FGL_J1040.5+0617_daily_bin532.fits
Exposure cube: /scratch/kocevski/64461/ltcube_377222401_377481601_4FGL_J1040.5+0617_daily_bin532.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/64461/Model_4FGL_J1040.5+0617_daily_bin532.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) = 6900.1754367

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    9.0886       1.0000         .10000E-03   10000.    
     2 'Prefactor '    14.325       1.0000         .10000E-03   10000.    
     3 'norm      '    8.2294       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .11169E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    17.516       1.0000         .10000E-03   10000.    
     6 'Prefactor '    54.780       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .11845E-03   1.0000         .10000E-03   10000.    
     8 'norm      '    1.7030       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    4.2212       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10007E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    12.611       1.0000         .10000E-03   10000.    
    13 'norm      '    1.1909       1.0000         .10000E-03   10000.    
    14 'Prefactor '    11.160       1.0000         .10000E-03   10000.    
    15 'norm      '    1.2282       1.0000         .10000E-03   10000.    
    16 'Prefactor '    9.7320       1.0000         .10000E-03   10000.    
    17 'norm      '    15.685       1.0000         .10000E-03   10000.    
    18 'Normalizat'    1.1052       1.0000         .10000E-01   10.000    
    19 'Prefactor '    .91580       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5360E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   6900.160     FROM MIGRAD    STATUS=CONVERGED    366 CALLS     1857 TOTAL
                     EDM=   .62E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .2%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     9.0863        12.591        .32092E-06    .72450E-04
   2  Prefactor     14.325        25.088       -.10970E-05    .46127E-05
   3  norm          8.2307        13.734        .91713E-05    .92320E-04
   4  Prefactor     .10000E-03    6.7341        .40948E-06** at limit **
   5  Prefactor     17.470        37.820       -.98640E-04    .20448E-05
   6  Prefactor     54.784        41.604        .66084E-05    .28011E-04
   7  Prefactor     .10000E-03    13.553        .12021E-05** at limit **
   8  norm          1.7030        1.1956       -.12744E-06   -.10290E-03
   9  Prefactor     .10000E-03    1.5810       -.10918E-06** at limit **
  10  Prefactor     4.2210        2.8068       -.38537E-07    .73565E-04
  11  Prefactor     .10000E-03    3.7326        .32464E-07** at limit **
  12  Prefactor     12.608        10.151       -.14935E-05    .32995E-04
  13  norm          1.1909        .62812       -.73359E-07   -.15536E-03
  14  Prefactor     11.159        10.252       -.27974E-06   -.17363E-04
  15  norm          1.2281        1.5056       -.63165E-06   -.10468E-02
  16  Prefactor     9.7302        21.272       -.49132E-05    .15389E-04
  17  norm          15.685        11.572       -.94356E-06    .47749E-04
  18  Normalizat    1.1054        .18783        .76470E-05   -.20723E-03
  19  Prefactor     .91570        .15156       -.91178E-06    .39630E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 9.08632
  Prefactor  = 14.3247
  norm       = 8.23069
  Prefactor  = 0.000100001
  Prefactor  = 17.4703
  Prefactor  = 54.784
  Prefactor  = 0.0001
  norm       = 1.70297
  Prefactor  = 0.0001
  Prefactor  = 4.22103
  Prefactor  = 0.0001
  Prefactor  = 12.6085
  norm       = 1.19095
  Prefactor  = 11.1592
  norm       = 1.22813
  Prefactor  = 9.73021
  norm       = 15.6849
  Normalizat = 1.10538
  Prefactor  = 0.915698
 **********
 **   18 **HESSE 
 **********

 FCN=   6900.160     FROM HESSE     STATUS=OK           274 CALLS     2131 TOTAL
                     EDM=   .16E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     9.0863        12.586        .13294E-03   -1.5105    
   2  Prefactor     14.325        25.084        .10582E-03   -1.4951    
   3  norm          8.2307        13.706        .13975E-03   -1.5134    
   4  Prefactor     .10000E-03    6.7510        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     17.470        37.842        .95697E-04   -1.4872    
   6  Prefactor     54.784        41.394        .54195E-04   -1.4226    
   7  Prefactor     .10000E-03    13.609        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          1.7030        1.1904        .73012E-04   -1.5447    
   9  Prefactor     .10000E-03    1.5864        .10199E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     4.2210        2.8035        .10704E-03   -1.5297    
  11  Prefactor     .10000E-03    3.7626        .15663E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     12.608        10.131        .11280E-03   -1.4998    
  13  norm          1.1909        .63297        .40909E-04   -1.5490    
  14  Prefactor     11.159        10.390        .11993E-03   -1.5040    
  15  norm          1.2281        1.4863        .10458E-03   -1.5486    
  16  Prefactor     9.7302        21.248        .12845E-03   -1.5084    
  17  norm          15.685        11.558        .10113E-03   -1.4916    
  18  Normalizat    1.1054        .22142        .26337E-03   -.89579    
  19  Prefactor     .91570        .17868        .24313E-03   -.95595    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.64799e-09
Minuit parameter uncertainties:
  1  12.5896
  2  25.1021
  3  13.7108
  4  0.000117034
  5  37.8944
  6  41.4155
  7  0.000123414
  8  1.19039
  9  5.76205e-06
  10  2.8036
  11  2.40695e-05
  12  10.1319
  13  0.632978
  14  10.3912
  15  1.48633
  16  21.2646
  17  11.5595
  18  0.221601
  19  0.178798
Done.

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

Extracting fit parameters...

4FGL J1040.5+0617
   Spectrum: PowerLaw
216    Prefactor:  4.221e+00  2.804e+00  1.000e-04  1.000e+04 ( 1.000e-12)
217        Index:  2.368e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
218        Scale:  8.643e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
533    Prefactor:  9.157e-01  1.788e-01  0.000e+00  1.000e+01 ( 1.000e+00)
534        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
535        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
532   Normalization:  1.105e+00  2.216e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 8.68
Ra Dec: 160.150 6.285
Photon Index (Fixed Index): 2.37 +/- 0.00
Photon Flux (Fixed Index): 5.10e-08 +/- 3.38e-08
Energy Flux (Fixed Index): 1.75e-05 +/- 1.16e-05

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) = 6899.80432556
delta logL = 0.356046460753

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 6899.7982674
delta logL = 0.362104618812

Fit tolerance = 1e-08

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

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

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   6899.798     FROM MIGRAD    STATUS=CONVERGED     55 CALLS      208 TOTAL
                     EDM=   .53E-10    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     4.0468        4.7892        .50100E-02    .27747E-04
   2  Index         1.8434        .66702        .25492       -.38985E-04
   3  Normalizat    1.1320        .17977        .58975E-01    .10461E-04
   4  Prefactor     .90448        .15163        .45062E-01    .12767E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 4.04685
  Index      = 1.84338
  Normalizat = 1.13197
  Prefactor  = 0.904483
 **********
 **   18 **HESSE 
 **********

 FCN=   6899.798     FROM HESSE     STATUS=OK            33 CALLS      241 TOTAL
                     EDM=   .60E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     4.0468        3.4379        .12289E-03   -1.5306    
   2  Index         1.8434        .60621        .88119E-02   -.68326    
   3  Normalizat    1.1320        .20892        .26082E-03   -.88732    
   4  Prefactor     .90448        .17715        .24459E-03   -.95985    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 5.99606e-10
Minuit parameter uncertainties:
  1  3.43806
  2  0.608702
  3  0.209074
  4  0.17726
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/64461': 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) = 6899.79826632
delta logL = 0.362105705736

Extracting fit parameters...

4FGL J1040.5+0617
   Spectrum: PowerLaw
216    Prefactor:  4.047e+00  3.438e+00  1.000e-04  1.000e+04 ( 1.000e-12)
217        Index:  1.843e+00  6.087e-01  0.000e+00  1.000e+01 (-1.000e+00)
218        Scale:  8.643e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
533    Prefactor:  9.045e-01  1.773e-01  0.000e+00  1.000e+01 ( 1.000e+00)
534        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
535        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
532   Normalization:  1.132e+00  2.091e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 9.40
Ra Dec: 160.150 6.285
Photon Index (Free Index): 1.84 +/- 0.61
Photon Flux (Free Index): 2.55e-08 +/- 3.17e-08
Energy Flux (Free Index): 2.69e-05 +/- 2.91e-05

Creating a high resolution counts map...
INFO: Auto-setting vmin to -2.500e-04 [aplpy.core]
INFO: Auto-setting vmax to  2.775e-03 [aplpy.core]
Saving /scratch/kocevski/64461/cmap_HighResolution_377222401_377481601_4FGL_J1040.5+0617_daily_bin532.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET comment='SUCCESS', photon_flux='5.10e-08', energy_flux2='2.69e-05', photon_flux_error='3.38e-08', dlogl='3.62e-01', energy_flux='1.75e-05', photon_flux2='2.55e-08', job_status='DONE', time_completed='2021-09-02 08:31:35.615562', photon_index_error2='0.61', photon_index2='1.84', ts='8.68', fit_tolerance='1e-08', GAL='0.92', photon_index_error='0.00', energy_flux_error2='2.91e-05', EG='1.11', time_epoch_completed='1630596695.62', return_code='0', job_id='64461', GAL2='0.90', EG2='1.13', return_code2='0', energy_flux_error='1.16e-05', photon_flux_error2='3.17e-08', ts2='9.40', photon_index='2.37' WHERE bin_id='532' AND source_name='4FGL J1040.5+0617' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Sep  2 08:31:35 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0191>
Subject: Job 64461: <4FGL_J1040.5+0617_daily_bin532> in cluster <slac> Done

Job <4FGL_J1040.5+0617_daily_bin532> was submitted from host <rhel6-64p> by user <kocevski> in cluster <slac> at Thu Sep  2 08:16:36 2021
Job was executed on host(s) <bullet0191>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Sep  2 08:19:16 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Thu Sep  2 08:19:16 2021
Terminated at Thu Sep  2 08:31:36 2021
Results reported at Thu Sep  2 08:31:36 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1040.5+0617_daily_bin532 160.15 6.2848 377222401 377481601 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1040.5+0617 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   553.40 sec.
    Max Memory :                                 1094 MB
    Average Memory :                             243.71 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   739 sec.
    Turnaround time :                            900 sec.

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

