/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 60 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 = 7487
number of fields = 31
RA_SUN column already exists. File will not be modified.DDone.


Performing analysis on: 4FGL_J1018.4+3540_daily_bin1641
RA = 154.607, Dec = 35.6802
tmin = 664675201, tmax = 664934401
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='364481', job_status='RUN', time_executed='2022-01-27 00:13:05.859233', time_epoch_executed='1643271185.86' WHERE source_name='4FGL J1018.4+3540' and cadence='daily' and bin_id='1641'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/364481

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

Retrieving the FT1 file...

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

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

Retrieving 48 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/364481/ft1_4FGL_J1018.4+3540_daily_bin1641.fits


Retrieving the FT1 file...

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

Retrieving 48 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/364481/ft2_4FGL_J1018.4+3540_daily_bin1641.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/364481/ft1_4FGL_J1018.4+3540_daily_bin1641.fits outfile=/scratch/kocevski/364481/ft1_filteredMKT_4FGL_J1018.4+3540_daily_bin1641.fits ra=154.607 dec=35.6802 rad=12.0 tmin=664675201.0 tmax=664934401.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.78
user 3.39
sys 0.18

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/364481/ft2_4FGL_J1018.4+3540_daily_bin1641.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/364481/ft1_filteredMKT_4FGL_J1018.4+3540_daily_bin1641.fits evtable="EVENTS" outfile="/scratch/kocevski/364481/ft1_filtered_4FGL_J1018.4+3540_daily_bin1641.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 1.04
user 0.32
sys 0.18

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/364481/ft1_filtered_4FGL_J1018.4+3540_daily_bin1641.fits" evtable="EVENTS" scfile=/scratch/kocevski/364481/ft2_4FGL_J1018.4+3540_daily_bin1641.fits sctable="SC_DATA" outfile=/scratch/kocevski/364481/ltcube_664675201_664934401_4FGL_J1018.4+3540_daily_bin1641.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/364481/ft2_4FGL_J1018.4+3540_daily_bin1641.fits
.....................!
real 12.61
user 11.65
sys 0.33

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/364481/ft1_filtered_4FGL_J1018.4+3540_daily_bin1641.fits evtable="EVENTS" scfile=/scratch/kocevski/364481/ft2_4FGL_J1018.4+3540_daily_bin1641.fits sctable="SC_DATA" expcube=/scratch/kocevski/364481/ltcube_664675201_664934401_4FGL_J1018.4+3540_daily_bin1641.fits outfile=/scratch/kocevski/364481/expmap_664675201_664934401_4FGL_J1018.4+3540_daily_bin1641.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/364481/ltcube_664675201_664934401_4FGL_J1018.4+3540_daily_bin1641.fits
.....................!
real 190.36
user 185.14
sys 4.64

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/364481/ft1_filtered_4FGL_J1018.4+3540_daily_bin1641.fits scfile=/scratch/kocevski/364481/ft2_4FGL_J1018.4+3540_daily_bin1641.fits outfile=/scratch/kocevski/364481/cmap_664675201_664934401_4FGL_J1018.4+3540_daily_bin1641.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.53
user 0.37
sys 0.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/364481/ft1_filtered_4FGL_J1018.4+3540_daily_bin1641.fits scfile=/scratch/kocevski/364481/ft2_4FGL_J1018.4+3540_daily_bin1641.fits outfile=/scratch/kocevski/364481/cmap_HighResolution_664675201_664934401_4FGL_J1018.4+3540_daily_bin1641.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.54
user 0.39
sys 0.14

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

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

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    .23149E-02   1.0000         .10000E-03   10000.    
     2 'norm      '    15.716       1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10020E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10010E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10048E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    6.7822       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    3.5839       1.0000         .10000E-03   10000.    
     9 'norm      '    8.9456       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .20007E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    2.5768       1.0000         .10000E-03   10000.    
    13 'norm      '    .10045E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10307E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    3.1735       1.0000         .10000E-03   10000.    
    17 'Prefactor '    .10090E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    7.4559       1.0000         .10000E-03   10000.    
    19 'Prefactor '    .58594       1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    22 'norm      '    .50368       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10021E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    25 'norm      '    17.703       1.0000         .10000E-03   10000.    
    26 'Normalizat'    1.0784       1.0000         .10000E-01   10.000    
    27 'Prefactor '    .97053       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.

 FCN=   5854.258     FROM MIGRAD    STATUS=CONVERGED    665 CALLS     2850 TOTAL
                     EDM=   .12E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  4.9%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .10001E-03    7.0342        .73247E-06** at limit **
   2  norm          15.714        14.785        .30430E-06   -.38040E-04
   3  Prefactor     .10001E-03    31.064       -.34621E-05** at limit **
   4  Prefactor     .10000E-03    8.6463        .12027E-05** at limit **
   5  Prefactor     .10000E-03    26.004        .21828E-05** at limit **
   6  Prefactor     6.7793        8.8244        .30025E-05   -.28030E-03
   7  Prefactor     .10000E-03    4.9341        .50706E-07** at limit **
   8  Prefactor     3.5826        3.0912       -.15214E-06    .85202E-04
   9  norm          8.9438        8.0183       -.15401E-06   -.99989E-05
  10  Prefactor     .10013E-03    2.5183       -.12130E-05** at limit **
  11  Prefactor     .10000E-03    12.653        .78153E-06** at limit **
  12  Prefactor     2.5768        4.1303        .32519E-06    .55412E-03
  13  norm          .10000E-03    7.8967       -.12800E-06** at limit **
  14  Prefactor     .10001E-03    40.887        .31271E-05** at limit **
  15  Prefactor     .10000E-03    18.286        .16389E-05** at limit **
  16  Prefactor     3.1715        4.5229        .46612E-06    .13038E-04
  17  Prefactor     .10000E-03    1.9781       -.30216E-07** at limit **
  18  Prefactor     7.3471        31.982       -.28935E-05   -.12823E-03
  19  Prefactor     .40995        23.868        .11574E-05   -.77987E-04
  20  Prefactor     .10000E-03    29.781       -.17940E-05** at limit **
  21  Prefactor     .10000E-03    8.9755       -.14084E-05** at limit **
  22  norm          .50357        .22336        .84247E-08    .52807E-04
  23  Prefactor     .10000E-03    13.025        .10459E-06** at limit **
  24  Prefactor     .10000E-03    10.867        .39047E-06** at limit **
  25  norm          17.701        14.127        .33311E-07   -.26755E-04
  26  Normalizat    1.0786        .17820       -.32010E-06    .17359E-03
  27  Prefactor     .97064        .20856       -.50095E-06    .80107E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 0.000100008
  norm       = 15.7141
  Prefactor  = 0.000100009
  Prefactor  = 0.000100001
  Prefactor  = 0.000100003
  Prefactor  = 6.77935
  Prefactor  = 0.0001
  Prefactor  = 3.58264
  norm       = 8.9438
  Prefactor  = 0.000100131
  Prefactor  = 0.0001
  Prefactor  = 2.57677
  norm       = 0.0001
  Prefactor  = 0.000100007
  Prefactor  = 0.000100002
  Prefactor  = 3.17152
  Prefactor  = 0.0001
  Prefactor  = 7.34706
  Prefactor  = 0.409949
  Prefactor  = 0.000100002
  Prefactor  = 0.000100001
  norm       = 0.503573
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 17.7012
  Normalizat = 1.07858
  Prefactor  = 0.970636
 **********
 **   18 **HESSE 
 **********

 FCN=   5854.258     FROM HESSE     STATUS=OK           494 CALLS     3344 TOTAL
                     EDM=   .10E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          .10001E-03    32.885        .38899E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  norm          15.714        14.786        .50515E-03   -1.4915    
   3  Prefactor     .10001E-03    32.292        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    8.7859        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10000E-03    26.514        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     6.7793        9.3119        .77034E-03   -1.5187    
   7  Prefactor     .10000E-03    4.9486        .16595E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     3.5826        3.0798        .11659E-03   -1.5329    
   9  norm          8.9438        8.0177        .13401E-03   -1.5110    
  10  Prefactor     .10013E-03    15.572        .20503E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .10000E-03    12.722        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     2.5768        3.9323        .17903E-03   -1.5387    
  13  norm          .10000E-03    8.0113        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     .10001E-03    41.885        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .10000E-03    18.679        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     3.1715        4.4982        .17942E-03   -1.5352    
  17  Prefactor     .10000E-03    1.9920        .10504E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     7.3471        32.890        .14688E-03   -1.5166    
  19  Prefactor     .40995        27.174        .10582       -1.5580    
  20  Prefactor     .10000E-03    30.105        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .10000E-03    9.2553        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  norm          .50357        .22473        .23309E-04   -1.5566    
  23  Prefactor     .10000E-03    13.168        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     .10000E-03    10.950        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  norm          17.701        14.117        .95190E-04   -1.4866    
  26  Normalizat    1.0786        .20505        .22681E-03   -.90443    
  27  Prefactor     .97064        .24265        .28190E-03   -.93715    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.00912e-08
Minuit parameter uncertainties:
  1  0.00103129
  2  14.7896
  3  0.00106141
  4  0.000191712
  5  0.000592952
  6  9.31392
  7  1.09066e-05
  8  3.07998
  9  8.01862
  10  0.00286178
  11  0.000150297
  12  3.93266
  13  1.38885e-05
  14  0.00110138
  15  0.000406641
  16  4.49867
  17  1.72852e-06
  18  31.1183
  19  6.67764
  20  0.000537228
  21  0.00022414
  22  0.224731
  23  1.90208e-05
  24  6.62169e-05
  25  14.1194
  26  0.205205
  27  0.2429DoDone.

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

Extracting fit parameters...

4FGL J1018.4+3540
   Spectrum: PowerLaw
303    Prefactor:  2.577e+00  3.933e+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:  9.706e-01  2.429e-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.079e+00  2.052e-01  1.000e-02  1.000e+01 ( 1.000e+00)


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

Saving results to:
/scratch/kocevski/364481/likelihoodResults_664675201_664934401_4FGL_J1018.4+3540_daily_bin1641.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) = 5854.01114333
delta logL = 0.246755735148

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 5853.98267666
delta logL = 0.275222408757

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    3.4919       1.0000         .10000E-03   10000.    
     2 'Index     '    1.8351       1.0000          .0000       10.000    
     3 'Normalizat'    1.0959       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .95240       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.

 FCN=   5853.983     FROM MIGRAD    STATUS=CONVERGED     46 CALLS      198 TOTAL
                     EDM=   .13E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     3.4918        4.5967        .54094E-02   -.15574E-02
   2  Index         1.8372        .61110        .26833       -.43912E-04
   3  Normalizat    1.0957        .17340        .38169E-01    .29546E-04
   4  Prefactor     .95270        .20631        .45669E-01    .33715E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 3.49176
  Index      = 1.83722
  Normalizat = 1.09573
  Prefactor  = 0.952701
 **********
 **   18 **HESSE 
 **********

 FCN=   5853.983     FROM HESSE     STATUS=OK            33 CALLS      231 TOTAL
                     EDM=   .42E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     3.4918        4.2627        .16251E-03   -1.5334    
   2  Index         1.8372        .75261        .10467E-01   -.68485    
   3  Normalizat    1.0957        .20137        .22516E-03   -.89889    
   4  Prefactor     .95270        .23939        .28405E-03   -.94323    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 4.16857e-09
Minuit parameter uncertainties:
  1  4.26305
  2  0.757434
  3  0.201506
  4  0.239653
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/364481': 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) = 5853.98267173
delta logL = 0.275227332188

Extracting fit parameters...

4FGL J1018.4+3540
   Spectrum: PowerLaw
303    Prefactor:  3.492e+00  4.263e+00  1.000e-04  1.000e+04 ( 1.000e-12)
304        Index:  1.837e+00  7.574e-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:  9.527e-01  2.397e-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.096e+00  2.015e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 1.12
Ra Dec: 154.607 35.680
Photon Index (Free Index): 1.84 +/- 0.76
Photon Flux (Free Index): 1.32e-08 +/- 1.93e-08
Energy Flux (Free Index): 1.41e-05 +/- 2.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/364481/cmap_HighResolution_664675201_664934401_4FGL_J1018.4+3540_daily_bin1641.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='7.79e-03', comment='SUCCESS', energy_flux2='1.41e-05', dlogl='2.75e-01', photon_flux2='1.32e-08', job_status='DONE', time_completed='2022-01-27 00:24:57.331753', photon_index_error2='0.76', photon_index2='1.84', ts='0.57', fit_tolerance='1e-08', GAL='0.97', photon_index_error='0.00', photon_flux_upper_limit='9.96e-08', energy_flux_error2='2.48e-05', EG='1.08', time_epoch_completed='1643271897.33', return_code='0', job_id='364481', GAL2='0.95', EG2='1.10', return_code2='0', photon_flux_error2='1.93e-08', ts2='1.12', photon_index='2.59' WHERE bin_id='1641' AND source_name='4FGL J1018.4+3540' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Jan 27 00:24:57 PST 2022

-----------------------------------------------------------
Sender: LSF System <lsf@bullet0212>
Subject: Job 364559: <4FGL_J1018.4+3540_daily_bin1641> in cluster <slac> Done

Job <4FGL_J1018.4+3540_daily_bin1641> was submitted from host <rhel6-64l> by user <kocevski> in cluster <slac> at Thu Jan 27 00:10:13 2022
Job was executed on host(s) <bullet0212>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Jan 27 00:10:15 2022
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Thu Jan 27 00:10:15 2022
Terminated at Thu Jan 27 00:24:09 2022
Results reported at Thu Jan 27 00:24:09 2022

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1018.4+3540_daily_bin1641 154.607 35.6802 664675201 664934401 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 :                                   723.03 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             302.29 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   833 sec.
    Turnaround time :                            836 sec.

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


------------------------------------------------------------
Sender: LSF System <lsf@bullet0216>
Subject: Job 364481: <4FGL_J1018.4+3540_daily_bin1641> in cluster <slac> Done

Job <4FGL_J1018.4+3540_daily_bin1641> was submitted from host <rhel6-64k> by user <kocevski> in cluster <slac> at Thu Jan 27 00:10:05 2022
Job was executed on host(s) <bullet0216>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Jan 27 00:10:07 2022
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Thu Jan 27 00:10:07 2022
Terminated at Thu Jan 27 00:24:58 2022
Results reported at Thu Jan 27 00:24:58 2022

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1018.4+3540_daily_bin1641 154.607 35.6802 664675201 664934401 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 :                                   711.33 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             300.42 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   890 sec.
    Turnaround time :                            893 sec.

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

