/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 6 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 = 7343
number of fields = 27
No RA_SUN column yet. Adding RA_SUN/DEC_SUN columns.
Done.


Performing analysis on: 4FGL_J1018.4+3540_daily_bin290
RA = 154.607, Dec = 35.6802
tmin = 314496001, tmax = 314755201
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='810942', job_status='RUN', time_executed='2021-09-01 17:50:59.328251', time_epoch_executed='1630543859.33' WHERE source_name='4FGL J1018.4+3540' and cadence='daily' and bin_id='290'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/810942

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/810942/ft1_4FGL_J1018.4+3540_daily_bin290.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/810942/ft2_4FGL_J1018.4+3540_daily_bin290.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/810942/ft1_4FGL_J1018.4+3540_daily_bin290.fits outfile=/scratch/kocevski/810942/ft1_filteredMKT_4FGL_J1018.4+3540_daily_bin290.fits ra=154.607 dec=35.6802 rad=12.0 tmin=314496001.0 tmax=314755201.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.56
user 3.27
sys 0.21

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/810942/ft2_4FGL_J1018.4+3540_daily_bin290.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/810942/ft2_4FGL_J1018.4+3540_daily_bin290.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/810942/ft1_filteredMKT_4FGL_J1018.4+3540_daily_bin290.fits evtable="EVENTS" outfile="/scratch/kocevski/810942/ft1_filtered_4FGL_J1018.4+3540_daily_bin290.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.55
user 0.36
sys 0.16

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/810942/ft1_filtered_4FGL_J1018.4+3540_daily_bin290.fits" evtable="EVENTS" scfile=/scratch/kocevski/810942/ft2_4FGL_J1018.4+3540_daily_bin290.fits sctable="SC_DATA" outfile=/scratch/kocevski/810942/ltcube_314496001_314755201_4FGL_J1018.4+3540_daily_bin290.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/810942/ft2_4FGL_J1018.4+3540_daily_bin290.fits
.....................!
real 17.23
user 16.81
sys 0.34

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/810942/ft1_filtered_4FGL_J1018.4+3540_daily_bin290.fits evtable="EVENTS" scfile=/scratch/kocevski/810942/ft2_4FGL_J1018.4+3540_daily_bin290.fits sctable="SC_DATA" expcube=/scratch/kocevski/810942/ltcube_314496001_314755201_4FGL_J1018.4+3540_daily_bin290.fits outfile=/scratch/kocevski/810942/expmap_314496001_314755201_4FGL_J1018.4+3540_daily_bin290.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/810942/ltcube_314496001_314755201_4FGL_J1018.4+3540_daily_bin290.fits
.....................!
real 192.76
user 186.73
sys 4.96

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

Setting source of interest to:
4FGL J1018.4+3540 @ 154.607 35.6802

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/810942/ft1_filtered_4FGL_J1018.4+3540_daily_bin290.fits scfile=/scratch/kocevski/810942/ft2_4FGL_J1018.4+3540_daily_bin290.fits outfile=/scratch/kocevski/810942/cmap_314496001_314755201_4FGL_J1018.4+3540_daily_bin290.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=154.607 yref=35.6802 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.38
sys 0.16

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/810942/ft1_filtered_4FGL_J1018.4+3540_daily_bin290.fits scfile=/scratch/kocevski/810942/ft2_4FGL_J1018.4+3540_daily_bin290.fits outfile=/scratch/kocevski/810942/cmap_HighResolution_314496001_314755201_4FGL_J1018.4+3540_daily_bin290.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=154.607 yref=35.6802 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/810942/ft1_filtered_4FGL_J1018.4+3540_daily_bin290.fits evtable="EVENTS" scfile=/scratch/kocevski/810942/ft2_4FGL_J1018.4+3540_daily_bin290.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/810942/Model_4FGL_J1018.4+3540_daily_bin290.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/810942/ft1_filtered_4FGL_J1018.4+3540_daily_bin290.fits.....................!
real 50.42
user 48.98
sys 1.22

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/810942/ft1_filtered_4FGL_J1018.4+3540_daily_bin290.fits', '/scratch/kocevski/810942/ft2_4FGL_J1018.4+3540_daily_bin290.fits', expMap='/scratch/kocevski/810942/expmap_314496001_314755201_4FGL_J1018.4+3540_daily_bin290.fits', expCube='/scratch/kocevski/810942/ltcube_314496001_314755201_4FGL_J1018.4+3540_daily_bin290.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/810942/Model_4FGL_J1018.4+3540_daily_bin290.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1018.4+3540'

4FGL J1018.4+3540
   Spectrum: PowerLaw
303    Prefactor:  1.799e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-12)
304        Index:  2.590e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
305        Scale:  6.553e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/810942/ft1_filtered_4FGL_J1018.4+3540_daily_bin290.fits
Spacecraft file(s): /scratch/kocevski/810942/ft2_4FGL_J1018.4+3540_daily_bin290.fits
Exposure map: /scratch/kocevski/810942/expmap_314496001_314755201_4FGL_J1018.4+3540_daily_bin290.fits
Exposure cube: /scratch/kocevski/810942/ltcube_314496001_314755201_4FGL_J1018.4+3540_daily_bin290.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/810942/Model_4FGL_J1018.4+3540_daily_bin290.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) = 5592.65348122

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    9.3229       1.0000         .10000E-03   10000.    
     2 'norm      '    .10003E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    4.0084       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10107E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    17.834       1.0000         .10000E-03   10000.    
     6 'Prefactor '    11.326       1.0000         .10000E-03   10000.    
     7 'Prefactor '    2.8362       1.0000         .10000E-03   10000.    
     8 'Prefactor '    1.2402       1.0000         .10000E-03   10000.    
     9 'norm      '    21.238       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .62409       1.0000         .10000E-03   10000.    
    11 'Prefactor '    36.310       1.0000         .10000E-03   10000.    
    12 'Prefactor '    .18621E-03   1.0000         .10000E-03   10000.    
    13 'norm      '    3.0031       1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10030E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .13199E-02   1.0000         .10000E-03   10000.    
    16 'Prefactor '    6.6443       1.0000         .10000E-03   10000.    
    17 'Prefactor '    9.1007       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10009E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    44.338       1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    22 'norm      '    1.0027       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10006E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    25 'norm      '    14.239       1.0000         .10000E-03   10000.    
    26 'Normalizat'    .82565       1.0000         .10000E-01   10.000    
    27 'Prefactor '    .97347       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6140E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   5592.645     FROM MIGRAD    STATUS=CONVERGED   1152 CALLS     3832 TOTAL
                     EDM=   .55E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          9.3231        8.5882        .13125E-03    .29622E-04
   2  norm          .10000E-03    7.2709        .18142E-02** at limit **
   3  Prefactor     4.0081        25.917        .10072E-02   -.10374E-03
   4  Prefactor     .10027E-03    55.685        .48756E-02** at limit **
   5  Prefactor     17.831        27.326        .94841E-04    .78516E-04
   6  Prefactor     11.326        7.7128        .11904E-03   -.54436E-05
   7  Prefactor     2.8362        3.8798        .16823E-03   -.55415E-05
   8  Prefactor     1.2401        1.4465        .95839E-04   -.38908E-04
   9  norm          21.237        9.8880        .86913E-04    .30085E-05
  10  Prefactor     .62317        2.0078        .18765E-03    .46813E-03
  11  Prefactor     36.317        31.035        .66509E-04    .73673E-04
  12  Prefactor     .10000E-03    4.8167        .20352E-02** at limit **
  13  norm          3.0023        7.2204        .23422E-03    .40141E-04
  14  Prefactor     .10000E-03    19.390        .18142E-02** at limit **
  15  Prefactor     .10005E-03    148.70        .56980E-02** at limit **
  16  Prefactor     6.6449        4.7837        .12891E-03    .88191E-06
  17  Prefactor     9.1046        5.6107        .13115E-03    .54169E-03
  18  Prefactor     .10000E-03    9.2032        .18142E-02** at limit **
  19  Prefactor     .10000E-03    15.899        .18142E-02** at limit **
  20  Prefactor     44.366        84.550        .60209E-04    .25566E-04
  21  Prefactor     .10000E-03    2.9859        .12617E-02** at limit **
  22  norm          1.0027        .28611        .20632E-04    .68328E-04
  23  Prefactor     .10000E-03    7.1190        .18142E-02** at limit **
  24  Prefactor     .10000E-03    8.3971        .18142E-02** at limit **
  25  norm          14.239        12.421        .10614E-03    .57838E-05
  26  Normalizat    .82557        .18638        .23023E-03    .27540E-03
  27  Prefactor     .97358        .22035        .26491E-03    .17711E-03
                               ERR DEF=  .500    
Final values: 
  norm       = 9.32314
  norm       = 0.0001
  Prefactor  = 4.00812
  Prefactor  = 0.00010027
  Prefactor  = 17.8315
  Prefactor  = 11.326
  Prefactor  = 2.83624
  Prefactor  = 1.24014
  norm       = 21.2372
  Prefactor  = 0.62317
  Prefactor  = 36.317
  Prefactor  = 0.000100001
  norm       = 3.00232
  Prefactor  = 0.0001
  Prefactor  = 0.000100055
  Prefactor  = 6.64487
  Prefactor  = 9.10457
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 44.3661
  Prefactor  = 0.0001
  norm       = 1.00274
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 14.2386
  Normalizat = 0.825572
  Prefactor  = 0.973579
 **********
 **   18 **HESSE 
 **********

 FCN=   5592.645     FROM HESSE     STATUS=OK           460 CALLS     4292 TOTAL
                     EDM=   .56E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          9.3231        8.5882        .52502E-05   -1.5097    
   2  norm          .10000E-03    7.2715        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     4.0081        25.904        .40286E-04   -1.5308    
   4  Prefactor     .10027E-03    56.796        .97512E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     17.831        27.314        .37936E-05   -1.4863    
   6  Prefactor     11.326        7.7122        .47616E-05   -1.5035    
   7  Prefactor     2.8362        3.8798        .67291E-05   -1.5371    
   8  Prefactor     1.2401        1.4465        .38336E-05   -1.5485    
   9  norm          21.237        9.8882        .34765E-05   -1.4786    
  10  Prefactor     .62317        2.0070        .75062E-05   -1.5550    
  11  Prefactor     36.317        31.038        .26603E-05   -1.4502    
  12  Prefactor     .10000E-03    4.8471        .40703E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  norm          3.0023        7.2189        .93690E-05   -1.5361    
  14  Prefactor     .10000E-03    19.390        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .10005E-03    151.11        .11396E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     6.6449        4.7831        .51564E-05   -1.5192    
  17  Prefactor     9.1046        5.5929        .52460E-05   -1.5104    
  18  Prefactor     .10000E-03    9.2032        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10000E-03    15.900        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     44.366        84.555        .12042E-04   -1.4375    
  21  Prefactor     .10000E-03    2.9860        .25235E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  norm          1.0027        .28610        .82527E-06   -1.5508    
  23  Prefactor     .10000E-03    7.1204        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     .10000E-03    8.3981        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  norm          14.239        12.421        .42457E-05   -1.4953    
  26  Normalizat    .82557        .18652        .46046E-04   -.99127    
  27  Prefactor     .97358        .22053        .10596E-04   -.93615    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 5.63941e-09
Minuit parameter uncertainties:
  1  8.58931
  2  2.33986e-05
  3  20.3915
  4  0.00783379
  5  27.333
  6  7.71286
  7  3.88012
  8  1.44654
  9  9.889
  10  2.00722
  11  31.0522
  12  0.000121079
  13  7.22095
  14  3.63422e-05
  15  0.00575828
  16  4.78338
  17  5.5932
  18  7.99627e-06
  19  3.56798e-05
  20  84.7847
  21  1.13676e-06
  22  0.2861
  23  1.74829e-06
  24  6.31224e-07
  25  12.4233
  26  0.186667
  27  0.220732
Done.

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

Extracting fit parameters...

4FGL J1018.4+3540
   Spectrum: PowerLaw
303    Prefactor:  1.000e-04  1.211e-04  1.000e-04  1.000e+04 ( 1.000e-12)
304        Index:  2.590e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
305        Scale:  6.553e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
611    Prefactor:  9.736e-01  2.207e-01  0.000e+00  1.000e+01 ( 1.000e+00)
612        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
613        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
610   Normalization:  8.256e-01  1.867e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 154.607 35.680
Photon Flux Upper Limit: 5.75e-08 ph cm-2 s-1
Energy Flux Upper Limit: 4.50e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/810942/likelihoodResults_314496001_314755201_4FGL_J1018.4+3540_daily_bin290.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) = 5592.64589257
delta logL = -0.000989579503766

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 5592.64490305
delta logL = -5.8782461565e-08

Fit tolerance = 1e-08

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

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

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

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

 FCN=   5592.645     FROM MIGRAD    STATUS=FAILED        97 CALLS      262 TOTAL
                     EDM=   .32E-06    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10166E-03    46.470        .20766E-02** at limit **
   2  Index         2.4800        8.3293        .50000        .22560E-04
   3  Normalizat    .82557        .11567E-01    .23023E-03   -.15061E-04
   4  Prefactor     .97358        .14426E-01    .26491E-03   -.10900E-04
                               ERR DEF=  .500    
 START SIMPLEX MINIMIZATION.    CONVERGENCE WHEN EDM .LT.   .20E-04
 SIMPLEX MINIMIZATION HAS CONVERGED.

 FCN=   5592.645     FROM SIMPLEX   STATUS=PROGRESS     132 CALLS      394 TOTAL
                     EDM=   .42E-05    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10154E-03    46.470        .25921E-03** at limit **
   2  Index         2.4780        8.3293        .61468E-03    .22560E-04
   3  Normalizat    .82556        .11567E-01    .35466E-05   -.15061E-04
   4  Prefactor     .97357        .14426E-01    .21892E-05   -.10900E-04
                               ERR DEF=  .500    

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   5592.645     FROM MIGRAD    STATUS=CONVERGED     33 CALLS      427 TOTAL
                     EDM=   .16E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10084E-03    203.61        .41532E-03** at limit **
   2  Index         2.4881        5.7690        .50000        .24095E-04
   3  Normalizat    .82556        .25089E-01    .92091E-05   -.37904E-02
   4  Prefactor     .97357        .31290E-01    .10596E-04   -.31573E-02
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000100835
  Index      = 2.4881
  Normalizat = 0.825564
  Prefactor  = 0.973574
 **********
 **   18 **HESSE 
 **********

 FCN=   5592.645     FROM HESSE     STATUS=NOT POSDEF    29 CALLS      456 TOTAL
                     EDM=   .59E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10084E-03    623.71        .83064E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.4881        8.7544        .50000       -.52635    
   3  Normalizat    .82556        .50626E-01    .18418E-05   -.99127    
   4  Prefactor     .97357        .63117E-01    .21193E-05   -.93616    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 5.85539e-08
Minuit parameter uncertainties:
  1  0.0461396
  2  778.83
  3  0.0506287
  4  0.0631218
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/810942': 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) = 5592.64490227
delta logL = 7.25709469407e-07

Extracting fit parameters...

4FGL J1018.4+3540
   Spectrum: PowerLaw
303    Prefactor:  1.008e-04  4.614e-02  1.000e-04  1.000e+04 ( 1.000e-12)
304        Index:  2.488e+00  7.788e+02  0.000e+00  1.000e+01 (-1.000e+00)
305        Scale:  6.553e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
611    Prefactor:  9.736e-01  6.312e-02  0.000e+00  1.000e+01 ( 1.000e+00)
612        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
613        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
610   Normalization:  8.256e-01  5.063e-02  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 154.607 35.680

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/810942/cmap_HighResolution_314496001_314755201_4FGL_J1018.4+3540_daily_bin290.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='4.50e-03', job_status='DONE', photon_flux_upper_limit='5.75e-08', time_completed='2021-09-01 18:04:43.039549', job_id='810942', GAL2='0.97', fit_tolerance='1e-08', EG2='0.83', EG='0.83', time_epoch_completed='1630544683.04', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.97', dlogl='7.26e-07', ts2='-0.00', photon_index_error='0.00', photon_index='2.59' WHERE bin_id='290' AND source_name='4FGL J1018.4+3540' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Wed Sep  1 18:04:43 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0276>
Subject: Job 810942: <4FGL_J1018.4+3540_daily_bin290> in cluster <slac> Done

Job <4FGL_J1018.4+3540_daily_bin290> was submitted from host <rhel6-64h> by user <kocevski> in cluster <slac> at Wed Sep  1 17:50:34 2021
Job was executed on host(s) <bullet0276>, in queue <medium>, as user <kocevski> in cluster <slac> at Wed Sep  1 17:50:44 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Wed Sep  1 17:50:44 2021
Terminated at Wed Sep  1 18:04:43 2021
Results reported at Wed Sep  1 18:04:43 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1018.4+3540_daily_bin290 154.607 35.6802 314496001 314755201 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1018.4+3540 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   822.00 sec.
    Max Memory :                                 1094 MB
    Average Memory :                             330.39 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   839 sec.
    Turnaround time :                            849 sec.

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

