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


Performing analysis on: 4FGL_J1018.4+3540_daily_bin502
RA = 154.607, Dec = 35.6802
tmin = 369446401, tmax = 369705601
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='811242', job_status='RUN', time_executed='2021-09-01 17:51:37.077324', time_epoch_executed='1630543897.08' WHERE source_name='4FGL J1018.4+3540' and cadence='daily' and bin_id='502'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/811242

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/811242/ft1_4FGL_J1018.4+3540_daily_bin502.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/811242/ft2_4FGL_J1018.4+3540_daily_bin502.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/811242/ft1_4FGL_J1018.4+3540_daily_bin502.fits outfile=/scratch/kocevski/811242/ft1_filteredMKT_4FGL_J1018.4+3540_daily_bin502.fits ra=154.607 dec=35.6802 rad=12.0 tmin=369446401.0 tmax=369705601.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.44
user 3.20
sys 0.21

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/811242/ft2_4FGL_J1018.4+3540_daily_bin502.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/811242/ft1_filteredMKT_4FGL_J1018.4+3540_daily_bin502.fits evtable="EVENTS" outfile="/scratch/kocevski/811242/ft1_filtered_4FGL_J1018.4+3540_daily_bin502.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/811242/ft1_filtered_4FGL_J1018.4+3540_daily_bin502.fits" evtable="EVENTS" scfile=/scratch/kocevski/811242/ft2_4FGL_J1018.4+3540_daily_bin502.fits sctable="SC_DATA" outfile=/scratch/kocevski/811242/ltcube_369446401_369705601_4FGL_J1018.4+3540_daily_bin502.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/811242/ft2_4FGL_J1018.4+3540_daily_bin502.fits
.....................!
real 14.26
user 13.92
sys 0.31

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/811242/ft1_filtered_4FGL_J1018.4+3540_daily_bin502.fits evtable="EVENTS" scfile=/scratch/kocevski/811242/ft2_4FGL_J1018.4+3540_daily_bin502.fits sctable="SC_DATA" expcube=/scratch/kocevski/811242/ltcube_369446401_369705601_4FGL_J1018.4+3540_daily_bin502.fits outfile=/scratch/kocevski/811242/expmap_369446401_369705601_4FGL_J1018.4+3540_daily_bin502.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/811242/ltcube_369446401_369705601_4FGL_J1018.4+3540_daily_bin502.fits
.....................!
real 191.93
user 186.35
sys 5.13

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/811242/ft1_filtered_4FGL_J1018.4+3540_daily_bin502.fits scfile=/scratch/kocevski/811242/ft2_4FGL_J1018.4+3540_daily_bin502.fits outfile=/scratch/kocevski/811242/cmap_369446401_369705601_4FGL_J1018.4+3540_daily_bin502.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.54
user 0.38
sys 0.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/811242/ft1_filtered_4FGL_J1018.4+3540_daily_bin502.fits scfile=/scratch/kocevski/811242/ft2_4FGL_J1018.4+3540_daily_bin502.fits outfile=/scratch/kocevski/811242/cmap_HighResolution_369446401_369705601_4FGL_J1018.4+3540_daily_bin502.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.55
user 0.40
sys 0.14

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/811242/ft1_filtered_4FGL_J1018.4+3540_daily_bin502.fits evtable="EVENTS" scfile=/scratch/kocevski/811242/ft2_4FGL_J1018.4+3540_daily_bin502.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/811242/Model_4FGL_J1018.4+3540_daily_bin502.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/811242/ft1_filtered_4FGL_J1018.4+3540_daily_bin502.fits.....................!
real 48.37
user 47.00
sys 1.21

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/811242/ft1_filtered_4FGL_J1018.4+3540_daily_bin502.fits', '/scratch/kocevski/811242/ft2_4FGL_J1018.4+3540_daily_bin502.fits', expMap='/scratch/kocevski/811242/expmap_369446401_369705601_4FGL_J1018.4+3540_daily_bin502.fits', expCube='/scratch/kocevski/811242/ltcube_369446401_369705601_4FGL_J1018.4+3540_daily_bin502.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/811242/Model_4FGL_J1018.4+3540_daily_bin502.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/811242/ft1_filtered_4FGL_J1018.4+3540_daily_bin502.fits
Spacecraft file(s): /scratch/kocevski/811242/ft2_4FGL_J1018.4+3540_daily_bin502.fits
Exposure map: /scratch/kocevski/811242/expmap_369446401_369705601_4FGL_J1018.4+3540_daily_bin502.fits
Exposure cube: /scratch/kocevski/811242/ltcube_369446401_369705601_4FGL_J1018.4+3540_daily_bin502.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/811242/Model_4FGL_J1018.4+3540_daily_bin502.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) = 5361.32507743

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
     2 'norm      '    3.2373       1.0000         .10000E-03   10000.    
     3 'Prefactor '    2.8146       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10933E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    2.3868       1.0000         .10000E-03   10000.    
     9 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .35236       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .19654E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    5.3266       1.0000         .10000E-03   10000.    
    13 'norm      '    3.3179       1.0000         .10000E-03   10000.    
    14 'Prefactor '    4.2985       1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10030E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    17 'Prefactor '    .62577       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .13382E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    26.464       1.0000         .10000E-03   10000.    
    20 'Prefactor '    86.169       1.0000         .10000E-03   10000.    
    21 'Prefactor '    8.3612       1.0000         .10000E-03   10000.    
    22 'norm      '    3.1100       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    6.3995       1.0000         .10000E-03   10000.    
    25 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    26 'Normalizat'    1.1807       1.0000         .10000E-01   10.000    
    27 'Prefactor '    .73363       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6140E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   5361.310     FROM MIGRAD    STATUS=CONVERGED    113 CALLS     2829 TOTAL
                     EDM=   .40E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  5.6%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .10000E-03    3.2040        .26379E-06** at limit **
   2  norm          3.2388        1.7620        .69709E-06   -.15432E-02
   3  Prefactor     2.8212        1.1870        .44432E-06   -.14863E-04
   4  Prefactor     .10000E-03    10.818        .19934E-07** at limit **
   5  Prefactor     .10031E-03    47.037        .16923E-04** at limit **
   6  Prefactor     .10000E-03    3.4216       -.55569E-06** at limit **
   7  Prefactor     .10000E-03    23.894        .18754E-06** at limit **
   8  Prefactor     2.3877        2.4888        .44449E-06   -.14332E-03
   9  norm          .10000E-03    3.7658       -.18416E-06** at limit **
  10  Prefactor     .36521        6.4740        .29637E-05    .18259E-03
  11  Prefactor     .11745E-03    77.609        .27656E-05** at limit **
  12  Prefactor     5.3237        4.4833       -.11132E-05   -.25862E-03
  13  norm          3.2853        2.7299       -.17876E-05   -.13993E-02
  14  Prefactor     4.3076        1.8300        .15481E-05   -.78594E-03
  15  Prefactor     .10005E-03    36.279       -.14521E-04** at limit **
  16  Prefactor     .10000E-03    2.6988        .75451E-06** at limit **
  17  Prefactor     .63419        9.7257       -.24247E-04   -.61972E-03
  18  Prefactor     .12820E-03    92.030       -.17662E-04** at limit **
  19  Prefactor     26.468        1.0477        .69059E-08    .17460E-03
  20  Prefactor     86.168        1.0170       -.40676E-07    .51160E-03
  21  Prefactor     8.3614        1.6075        .41200E-06   -.21998E-02
  22  norm          3.1099        .49000        .57226E-07    .13131E-03
  23  Prefactor     .10000E-03    4.6247        .21205E-06** at limit **
  24  Prefactor     6.4007        1.0045        .94764E-08    .29963E-04
  25  norm          .10000E-03    2.8221        .39654E-06** at limit **
  26  Normalizat    1.1805        .19647        .16583E-05   -.53133E-04
  27  Prefactor     .73372        .23206       -.15620E-05   -.35873E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 0.0001
  norm       = 3.23876
  Prefactor  = 2.8212
  Prefactor  = 0.0001
  Prefactor  = 0.00010031
  Prefactor  = 0.0001
  Prefactor  = 0.000100003
  Prefactor  = 2.38773
  norm       = 0.0001
  Prefactor  = 0.365214
  Prefactor  = 0.000117447
  Prefactor  = 5.32366
  norm       = 3.28535
  Prefactor  = 4.30761
  Prefactor  = 0.000100051
  Prefactor  = 0.0001
  Prefactor  = 0.634194
  Prefactor  = 0.000128203
  Prefactor  = 26.4682
  Prefactor  = 86.1678
  Prefactor  = 8.36144
  norm       = 3.10992
  Prefactor  = 0.0001
  Prefactor  = 6.40074
  norm       = 0.0001
  Normalizat = 1.18054
  Prefactor  = 0.73372
 **********
 **   18 **HESSE 
 **********

 FCN=   5361.310     FROM HESSE     STATUS=OK           556 CALLS     3385 TOTAL
                     EDM=   .36E-06    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          .10000E-03    3.1931        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  norm          3.2388        9.2449        .56281E-02   -1.5348    
   3  Prefactor     2.8212        84.261        .60613E-02   -1.5372    
   4  Prefactor     .10000E-03    10.809        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10031E-03    49.635        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    3.3720        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10000E-03    23.149        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     2.3877        2.5131        .66279E-02   -1.5399    
   9  norm          .10000E-03    3.7470        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .36521        3.3500        .38539E-01   -1.5587    
  11  Prefactor     .11745E-03    135.02        .90712E-02   -1.5709    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     5.3237        4.5906        .43534E-02   -1.5246    
  13  norm          3.2853        11.678        .55559E-02   -1.5345    
  14  Prefactor     4.3076        231.11        .48578E-02   -1.5293    
  15  Prefactor     .10005E-03    38.175        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     .10000E-03    2.6530        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  Prefactor     .63419        3.3435        .67654E-01   -1.5549    
  18  Prefactor     .12820E-03    184.24        .90712E-02   -1.5707    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     26.468        26.440        .19468E-02   -1.4679    
  20  Prefactor     86.168        91.581        .10820E-02   -1.3849    
  21  Prefactor     8.3614        9.0272        .34660E-02   -1.5130    
  22  norm          3.1099        .50921        .44523E-02   -1.5355    
  23  Prefactor     .10000E-03    4.6194        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     6.4007        15.416        .39665E-02   -1.5202    
  25  norm          .10000E-03    2.8210        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  Normalizat    1.1805        .17909        .35382E-01   -.87206    
  27  Prefactor     .73372        .20347        .70847E-01   -1.0222    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 3.63518e-07
Minuit parameter uncertainties:
  1  1.16151e-05
  2  9.24896
  3  30.8834
  4  3.82291e-05
  5  0.00784833
  6  1.48955e-05
  7  0.000490951
  8  2.51316
  9  6.41233e-06
  10  2.21208
  11  0.0972917
  12  4.5909
  13  11.6861
  14  63.3629
  15  0.00279301
  16  8.4234e-06
  17  2.91237
  18  0.144612
  19  26.452
  20  91.7317
  21  9.02869
  22  0.509206
  23  4.78207e-06
  24  15.4259
  25  1.00198e-05
  26  0.17918
  27  0.203673
Done.

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

Extracting fit parameters...

4FGL J1018.4+3540
   Spectrum: PowerLaw
303    Prefactor:  5.324e+00  4.591e+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

GAL_V02
   Spectrum: PowerLaw
611    Prefactor:  7.337e-01  2.037e-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:  1.181e+00  1.792e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 3.88
Ra Dec: 154.607 35.680
Photon Index (Fixed Index): 2.59 +/- 0.00
Photon Flux (Fixed Index): 4.36e-08 +/- 3.76e-08
Energy Flux (Fixed Index): 1.16e-05 +/- 9.96e-06

TS (Fixed Index): 3.88
Ra Dec: 154.607 35.680
Photon Flux Upper Limit: 1.22e-07 ph cm-2 s-1
Energy Flux Upper Limit: 9.51e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/811242/likelihoodResults_369446401_369705601_4FGL_J1018.4+3540_daily_bin502.txt

Performing a free index iterative likelihood fit...

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

Done.

Freeing candidate source...
Done.

Fit tolerance = 1

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 5361.15963698
delta logL = 0.150357855466

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 5361.1527646
delta logL = 0.157230234659

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    5.9582       1.0000         .10000E-03   10000.    
     2 'Index     '    2.1629       1.0000          .0000       10.000    
     3 'Normalizat'    1.1997       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .71908       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=   5361.153     FROM MIGRAD    STATUS=CONVERGED     85 CALLS      265 TOTAL
                     EDM=   .76E-10    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     5.9581        4.9967        .14421E-03    .19930E-03
   2  Index         2.1628        .72930        .93951E-02    .40355E-04
   3  Normalizat    1.1996        .19557        .20966E-03   -.26353E-04
   4  Prefactor     .71916        .23172        .31635E-03   -.17933E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 5.95813
  Index      = 2.16283
  Normalizat = 1.19964
  Prefactor  = 0.719163
 **********
 **   18 **HESSE 
 **********

 FCN=   5361.153     FROM HESSE     STATUS=OK            23 CALLS      288 TOTAL
                     EDM=   .80E-10    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     5.9581        5.0136        .57682E-05   -1.5220    
   2  Index         2.1628        .73143        .37580E-03   -.60339    
   3  Normalizat    1.1996        .19575        .83863E-05   -.86614    
   4  Prefactor     .71916        .23192        .12654E-04   -1.0278    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 8.02592e-11
Minuit parameter uncertainties:
  1  5.01397
  2  0.735338
  3  0.195867
  4  0.232233
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/811242': 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) = 5361.15276444
delta logL = 0.157230403041

Extracting fit parameters...

4FGL J1018.4+3540
   Spectrum: PowerLaw
303    Prefactor:  5.958e+00  5.014e+00  1.000e-04  1.000e+04 ( 1.000e-12)
304        Index:  2.163e+00  7.353e-01  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:  7.192e-01  2.322e-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:  1.200e+00  1.959e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 4.17
Ra Dec: 154.607 35.680
Photon Index (Free Index): 2.16 +/- 0.74
Photon Flux (Free Index): 2.99e-08 +/- 3.56e-08
Energy Flux (Free Index): 1.44e-05 +/- 1.48e-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/811242/cmap_HighResolution_369446401_369705601_4FGL_J1018.4+3540_daily_bin502.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='9.51e-03', comment='SUCCESS', photon_flux='4.36e-08', energy_flux2='1.44e-05', photon_flux_error='3.76e-08', dlogl='1.57e-01', energy_flux='1.16e-05', photon_flux2='2.99e-08', job_status='DONE', time_completed='2021-09-01 18:03:50.836346', photon_index_error2='0.74', photon_index2='2.16', ts='3.88', fit_tolerance='1e-08', GAL='0.73', photon_index_error='0.00', photon_flux_upper_limit='1.22e-07', energy_flux_error2='1.48e-05', EG='1.18', time_epoch_completed='1630544630.84', return_code='0', job_id='811242', GAL2='0.72', EG2='1.20', return_code2='0', energy_flux_error='9.96e-06', photon_flux_error2='3.56e-08', ts2='4.17', photon_index='2.59' WHERE bin_id='502' AND source_name='4FGL J1018.4+3540' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Wed Sep  1 18:03:50 PDT 2021


------------------------------------------------------------
Sender: LSF System <scs@bullet0116>
Subject: Job 811242: <4FGL_J1018.4+3540_daily_bin502> in cluster <slac> Done

Job <4FGL_J1018.4+3540_daily_bin502> was submitted from host <rhel6-64h> by user <kocevski> in cluster <slac> at Wed Sep  1 17:51:02 2021
Job was executed on host(s) <bullet0116>, in queue <medium>, as user <kocevski> in cluster <slac> at Wed Sep  1 17:51:24 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:51:24 2021
Terminated at Wed Sep  1 18:03:51 2021
Results reported at Wed Sep  1 18:03:51 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1018.4+3540_daily_bin502 154.607 35.6802 369446401 369705601 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 :                                   732.15 sec.
    Max Memory :                                 1094 MB
    Average Memory :                             330.96 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   747 sec.
    Turnaround time :                            769 sec.

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

