/nfs/farm/g/glast/g/LCRepository/bin/miniconda2/envs/fermitools_v1.0.5/lib/python2.7/site-packages/matplotlib/font_manager.py:281: UserWarning: Matplotlib is building the font cache using fc-list. This may take a moment.
  'Matplotlib is building the font cache using fc-list. '
/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 55 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 = 7366
number of fields = 30
RA_SUN column already exists. File will not be modified.
Done.


Performing analysis on: 4FGL_J1040.5+0617_daily_bin1125
RA = 160.15, Dec = 6.2848
tmin = 530928001, tmax = 531187201
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='68067', job_status='RUN', time_executed='2021-09-02 08:34:29.139642', time_epoch_executed='1630596869.14' WHERE source_name='4FGL J1040.5+0617' and cadence='daily' and bin_id='1125'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/68067

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/68067/ft1_4FGL_J1040.5+0617_daily_bin1125.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/68067/ft2_4FGL_J1040.5+0617_daily_bin1125.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/68067/ft1_4FGL_J1040.5+0617_daily_bin1125.fits outfile=/scratch/kocevski/68067/ft1_filteredMKT_4FGL_J1040.5+0617_daily_bin1125.fits ra=160.15 dec=6.2848 rad=12.0 tmin=530928001.0 tmax=531187201.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 4.52
user 3.44
sys 0.24

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/68067/ft2_4FGL_J1040.5+0617_daily_bin1125.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/68067/ft1_filteredMKT_4FGL_J1040.5+0617_daily_bin1125.fits evtable="EVENTS" outfile="/scratch/kocevski/68067/ft1_filtered_4FGL_J1040.5+0617_daily_bin1125.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.52
user 0.33
sys 0.15

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/68067/ft1_filtered_4FGL_J1040.5+0617_daily_bin1125.fits" evtable="EVENTS" scfile=/scratch/kocevski/68067/ft2_4FGL_J1040.5+0617_daily_bin1125.fits sctable="SC_DATA" outfile=/scratch/kocevski/68067/ltcube_530928001_531187201_4FGL_J1040.5+0617_daily_bin1125.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/68067/ft2_4FGL_J1040.5+0617_daily_bin1125.fits
.....................!
real 13.25
user 12.87
sys 0.33

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/68067/ft1_filtered_4FGL_J1040.5+0617_daily_bin1125.fits evtable="EVENTS" scfile=/scratch/kocevski/68067/ft2_4FGL_J1040.5+0617_daily_bin1125.fits sctable="SC_DATA" expcube=/scratch/kocevski/68067/ltcube_530928001_531187201_4FGL_J1040.5+0617_daily_bin1125.fits outfile=/scratch/kocevski/68067/expmap_530928001_531187201_4FGL_J1040.5+0617_daily_bin1125.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/68067/ltcube_530928001_531187201_4FGL_J1040.5+0617_daily_bin1125.fits
.....................!
real 190.68
user 185.10
sys 5.16

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/68067/ft1_filtered_4FGL_J1040.5+0617_daily_bin1125.fits scfile=/scratch/kocevski/68067/ft2_4FGL_J1040.5+0617_daily_bin1125.fits outfile=/scratch/kocevski/68067/cmap_530928001_531187201_4FGL_J1040.5+0617_daily_bin1125.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.57
user 0.38
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/68067/ft1_filtered_4FGL_J1040.5+0617_daily_bin1125.fits scfile=/scratch/kocevski/68067/ft2_4FGL_J1040.5+0617_daily_bin1125.fits outfile=/scratch/kocevski/68067/cmap_HighResolution_530928001_531187201_4FGL_J1040.5+0617_daily_bin1125.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.56
user 0.40
sys 0.15

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

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/68067/ft1_filtered_4FGL_J1040.5+0617_daily_bin1125.fits', '/scratch/kocevski/68067/ft2_4FGL_J1040.5+0617_daily_bin1125.fits', expMap='/scratch/kocevski/68067/expmap_530928001_531187201_4FGL_J1040.5+0617_daily_bin1125.fits', expCube='/scratch/kocevski/68067/ltcube_530928001_531187201_4FGL_J1040.5+0617_daily_bin1125.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/68067/Model_4FGL_J1040.5+0617_daily_bin1125.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/68067/ft1_filtered_4FGL_J1040.5+0617_daily_bin1125.fits
Spacecraft file(s): /scratch/kocevski/68067/ft2_4FGL_J1040.5+0617_daily_bin1125.fits
Exposure map: /scratch/kocevski/68067/expmap_530928001_531187201_4FGL_J1040.5+0617_daily_bin1125.fits
Exposure cube: /scratch/kocevski/68067/ltcube_530928001_531187201_4FGL_J1040.5+0617_daily_bin1125.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/68067/Model_4FGL_J1040.5+0617_daily_bin1125.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) = 6221.87480707

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    4.0679       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .31273       1.0000         .10000E-03   10000.    
     3 'norm      '    .10007E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10752E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    138.63       1.0000         .10000E-03   10000.    
     6 'Prefactor '    .14311E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10327E-03   1.0000         .10000E-03   10000.    
     8 'norm      '    .10003E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    17.391       1.0000         .10000E-03   10000.    
    10 'Prefactor '    1.5844       1.0000         .10000E-03   10000.    
    11 'Prefactor '    15.361       1.0000         .10000E-03   10000.    
    12 'Prefactor '    .53318       1.0000         .10000E-03   10000.    
    13 'norm      '    1.1537       1.0000         .10000E-03   10000.    
    14 'Prefactor '    5.0240       1.0000         .10000E-03   10000.    
    15 'norm      '    1.6085       1.0000         .10000E-03   10000.    
    16 'Prefactor '    .10332E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    1.8485       1.0000         .10000E-03   10000.    
    18 'Normalizat'    .77272       1.0000         .10000E-01   10.000    
    19 'Prefactor '    1.1966       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=   6221.848     FROM MIGRAD    STATUS=CONVERGED    427 CALLS     2050 TOTAL
                     EDM=   .93E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.0%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     4.0386        14.461        .16941E-05   -.73115E-04
   2  Prefactor     .85085E-01    35.695       -.15369E-05   -.80870E-05
   3  norm          .10000E-03    5.8380        .30321E-06** at limit **
   4  Prefactor     .10000E-03    4.1326       -.58912E-06** at limit **
   5  Prefactor     138.57        67.376       -.13924E-05    .29104E-04
   6  Prefactor     .10000E-03    24.930       -.34126E-06** at limit **
   7  Prefactor     .10000E-03    4.7665       -.58189E-07** at limit **
   8  norm          .10000E-03    .54250        .26250E-07** at limit **
   9  Prefactor     17.398        8.8483        .16055E-05    .77023E-04
  10  Prefactor     1.5860        3.6141        .82012E-07   -.48474E-03
  11  Prefactor     15.368        9.3591        .34050E-05    .81448E-05
  12  Prefactor     .56446        5.3614       -.18619E-05    .53821E-03
  13  norm          1.1536        .61835       -.63549E-07    .11965E-02
  14  Prefactor     5.0218        8.2864        .14427E-05   -.47770E-05
  15  norm          1.6081        1.4340       -.56501E-07   -.30880E-03
  16  Prefactor     .10000E-03    24.600       -.17807E-05** at limit **
  17  norm          1.8416        13.530       -.10292E-04   -.24385E-03
  18  Normalizat    .77166        .20445       -.12463E-05    .34038E-03
  19  Prefactor     1.1974        .16275        .46847E-06    .34041E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 4.03856
  Prefactor  = 0.0850851
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 138.573
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 17.3981
  Prefactor  = 1.58598
  Prefactor  = 15.3685
  Prefactor  = 0.564463
  norm       = 1.1536
  Prefactor  = 5.02178
  norm       = 1.60811
  Prefactor  = 0.0001
  norm       = 1.84161
  Normalizat = 0.77166
  Prefactor  = 1.19741
 **********
 **   18 **HESSE 
 **********

 FCN=   6221.848     FROM HESSE     STATUS=OK           282 CALLS     2332 TOTAL
                     EDM=   .54E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     4.0386        14.347        .19991E-03   -1.5306    
   2  Prefactor     .85085E-01    38.384        .14039       -1.5650    
   3  norm          .10000E-03    5.8388        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    4.1441        .15650E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     138.57        67.562        .34211E-04   -1.3348    
   6  Prefactor     .10000E-03    24.971        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10000E-03    4.7690        .16818E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          .10000E-03    .81888        .11179E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     17.398        8.7600        .96040E-04   -1.4874    
  10  Prefactor     1.5860        3.5573        .20126E-03   -1.5456    
  11  Prefactor     15.368        9.1843        .10219E-03   -1.4924    
  12  Prefactor     .56446        32.146        .31232E-02   -1.5558    
  13  norm          1.1536        .63100        .38451E-04   -1.5493    
  14  Prefactor     5.0218        8.4502        .17940E-03   -1.5260    
  15  norm          1.6081        1.4166        .83990E-04   -1.5454    
  16  Prefactor     .10000E-03    24.954        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          1.8416        14.910        .30668E-03   -1.5437    
  18  Normalizat    .77166        .23886        .30620E-03   -1.0113    
  19  Prefactor     1.1974        .19203        .21931E-03   -.86411    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 5.4353e-09
Minuit parameter uncertainties:
  1  14.3591
  2  3.61455
  3  1.16099e-06
  4  2.96418e-06
  5  67.5999
  6  1.80416e-05
  7  2.1732e-06
  8  1.45109e-05
  9  8.76064
  10  3.55778
  11  9.18512
  12  8.52346
  13  0.631006
  14  8.45217
  15  1.41664
  16  6.12826e-05
  17  10.4833
  18  0.239188
  19  0.192142
Done.

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

Extracting fit parameters...

4FGL J1040.5+0617
   Spectrum: PowerLaw
216    Prefactor:  1.586e+00  3.558e+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:  1.197e+00  1.921e-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:  7.717e-01  2.392e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.25
Ra Dec: 160.150 6.285
Photon Flux Upper Limit: 1.12e-07 ph cm-2 s-1
Energy Flux Upper Limit: 8.65e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/68067/likelihoodResults_530928001_531187201_4FGL_J1040.5+0617_daily_bin1125.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) = 6220.95301075
delta logL = 0.895102180733

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 6220.91362325
delta logL = 0.934489684917

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .11410       1.0000         .10000E-03   10000.    
     2 'Index     '    4.8182       1.0000          .0000       10.000    
     3 'Normalizat'    .65927       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.2653       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=   6220.914     FROM MIGRAD    STATUS=CONVERGED     57 CALLS      249 TOTAL
                     EDM=   .31E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .11220        1.0906        .41197E-02    .58474E-02
   2  Index         4.8274        2.4682        .12873        .20418E-03
   3  Normalizat    .65966        .44793E-01    .74358E-01    .47935E-04
   4  Prefactor     1.2649        .39258E-01    .48447E-01   -.55654E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.112199
  Index      = 4.8274
  Normalizat = 0.659655
  Prefactor  = 1.2649
 **********
 **   18 **HESSE 
 **********

 FCN=   6220.914     FROM HESSE     STATUS=NOT POSDEF    35 CALLS      284 TOTAL
                     EDM=   .12E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .11220        2.7818        .18658E-03   -1.5641    
   2  Index         4.8274        7.1224        .46146E-02   -.34528E-01
   3  Normalizat    .65966        .17493        .32917E-03   -1.0551    
   4  Prefactor     1.2649        .15014        .21416E-03   -.84357    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 1.1922e-09
Minuit parameter uncertainties:
  1  1.11691
  2  5.24037
  3  0.175073
  4  0.150189
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/68067': 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) = 6220.91361012
delta logL = 0.934502813642

Extracting fit parameters...

4FGL J1040.5+0617
   Spectrum: PowerLaw
216    Prefactor:  1.122e-01  1.117e+00  1.000e-04  1.000e+04 ( 1.000e-12)
217        Index:  4.827e+00  5.240e+00  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:  1.265e+00  1.502e-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:  6.597e-01  1.751e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 2.41
Ra Dec: 160.150 6.285
Photon Index (Free Index): 4.83 +/- 5.24
Photon Flux (Free Index): 9.80e-08 +/- 6.94e-08
Energy Flux (Free Index): 1.32e-05 +/- 1.13e-05

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/68067/cmap_HighResolution_530928001_531187201_4FGL_J1040.5+0617_daily_bin1125.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='8.65e-03', comment='SUCCESS', energy_flux2='1.32e-05', dlogl='9.35e-01', photon_flux2='9.80e-08', job_status='DONE', time_completed='2021-09-02 08:44:27.046535', photon_index_error2='5.24', photon_index2='4.83', ts='0.25', fit_tolerance='1e-08', GAL='1.20', photon_index_error='0.00', photon_flux_upper_limit='1.12e-07', energy_flux_error2='1.13e-05', EG='0.77', time_epoch_completed='1630597467.05', return_code='0', job_id='68067', GAL2='1.26', EG2='0.66', return_code2='102', photon_flux_error2='6.94e-08', ts2='2.41', photon_index='2.37' WHERE bin_id='1125' AND source_name='4FGL J1040.5+0617' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Sep  2 08:44:27 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0254>
Subject: Job 68067: <4FGL_J1040.5+0617_daily_bin1125> in cluster <slac> Done

Job <4FGL_J1040.5+0617_daily_bin1125> was submitted from host <rhel6-64j> by user <kocevski> in cluster <slac> at Thu Sep  2 08:31:33 2021
Job was executed on host(s) <bullet0254>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Sep  2 08:33:15 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:33:15 2021
Terminated at Thu Sep  2 08:44:27 2021
Results reported at Thu Sep  2 08:44:27 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1040.5+0617_daily_bin1125 160.15 6.2848 530928001 531187201 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 :                                   589.00 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             331.95 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   672 sec.
    Turnaround time :                            774 sec.

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

