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


Performing analysis on: 4FGL_J2118.2+5752_monthly_bin118
RA = 319.551, Dec = 57.8703
tmin = 542851201, tmax = 545443201
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='116496', job_status='RUN', time_executed='2021-11-06 22:35:53.525807', time_epoch_executed='1636263353.53' WHERE source_name='4FGL J2118.2+5752' and cadence='monthly' and bin_id='118'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/116496

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

Retrieving the FT1 file...

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

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

Retrieving 176 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/116496/ft1_4FGL_J2118.2+5752_monthly_bin118.fits


Retrieving the FT1 file...

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

Retrieving 178 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/116496/ft2_4FGL_J2118.2+5752_monthly_bin118.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/116496/ft1_4FGL_J2118.2+5752_monthly_bin118.fits outfile=/scratch/kocevski/116496/ft1_filteredMKT_4FGL_J2118.2+5752_monthly_bin118.fits ra=319.551 dec=57.8703 rad=12.0 tmin=542851201.0 tmax=545443201.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 18.49
user 17.98
sys 0.39

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/116496/ft2_4FGL_J2118.2+5752_monthly_bin118.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/116496/ft2_4FGL_J2118.2+5752_monthly_bin118.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/116496/ft1_filteredMKT_4FGL_J2118.2+5752_monthly_bin118.fits evtable="EVENTS" outfile="/scratch/kocevski/116496/ft1_filtered_4FGL_J2118.2+5752_monthly_bin118.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.59
user 0.42
sys 0.16

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/116496/ft1_filtered_4FGL_J2118.2+5752_monthly_bin118.fits" evtable="EVENTS" scfile=/scratch/kocevski/116496/ft2_4FGL_J2118.2+5752_monthly_bin118.fits sctable="SC_DATA" outfile=/scratch/kocevski/116496/ltcube_542851201_545443201_4FGL_J2118.2+5752_monthly_bin118.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/116496/ft2_4FGL_J2118.2+5752_monthly_bin118.fits
.....................!
real 40.82
user 40.34
sys 0.35

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/116496/ft1_filtered_4FGL_J2118.2+5752_monthly_bin118.fits evtable="EVENTS" scfile=/scratch/kocevski/116496/ft2_4FGL_J2118.2+5752_monthly_bin118.fits sctable="SC_DATA" expcube=/scratch/kocevski/116496/ltcube_542851201_545443201_4FGL_J2118.2+5752_monthly_bin118.fits outfile=/scratch/kocevski/116496/expmap_542851201_545443201_4FGL_J2118.2+5752_monthly_bin118.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/116496/ltcube_542851201_545443201_4FGL_J2118.2+5752_monthly_bin118.fits
.....................!
real 190.73
user 184.67
sys 5.54

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
Extended source FHES J2129.9+5833 in ROI with RadialGaussian spatial model.
Extended source HB 21 in ROI with RadialDisk spatial model.
Extended source FHES J2208.4+6443 in ROI with RadialGaussian spatial model.
Extended source CTB 109 in ROI with RadialDisk spatial model.
Extended source FHES J2304.0+5406 in ROI with RadialGaussian spatial model.
Extended source gamma Cygni in ROI with RadialDisk spatial model.
Extended source Cygnus Cocoon in ROI with RadialGaussian spatial model.
Added 186 point sources and 7 extended sources
If using unbinned likelihood you will need to rerun gtdiffrsp for the extended sources or rerun the makeModel function with optional argument psForce=True

Setting source of interest to:
4FGL J2118.2+5752 @ 319.551 57.8703

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/116496/ft1_filtered_4FGL_J2118.2+5752_monthly_bin118.fits scfile=/scratch/kocevski/116496/ft2_4FGL_J2118.2+5752_monthly_bin118.fits outfile=/scratch/kocevski/116496/cmap_542851201_545443201_4FGL_J2118.2+5752_monthly_bin118.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=319.551 yref=57.8703 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.61
user 0.42
sys 0.17

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/116496/ft1_filtered_4FGL_J2118.2+5752_monthly_bin118.fits scfile=/scratch/kocevski/116496/ft2_4FGL_J2118.2+5752_monthly_bin118.fits outfile=/scratch/kocevski/116496/cmap_HighResolution_542851201_545443201_4FGL_J2118.2+5752_monthly_bin118.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=319.551 yref=57.8703 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.61
user 0.46
sys 0.14

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/116496/ft1_filtered_4FGL_J2118.2+5752_monthly_bin118.fits evtable="EVENTS" scfile=/scratch/kocevski/116496/ft2_4FGL_J2118.2+5752_monthly_bin118.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/116496/Model_4FGL_J2118.2+5752_monthly_bin118.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 CTB 109
adding source Cygnus Cocoon
adding source EG_v02
adding source FHES J2129.9+5833
adding source FHES J2208.4+6443
adding source FHES J2304.0+5406
adding source GAL_V02
adding source HB 21
adding source gamma Cygni
Working on...
/scratch/kocevski/116496/ft1_filtered_4FGL_J2118.2+5752_monthly_bin118.fits.....................!
real 48.04
user 46.62
sys 1.26

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/116496/ft1_filtered_4FGL_J2118.2+5752_monthly_bin118.fits', '/scratch/kocevski/116496/ft2_4FGL_J2118.2+5752_monthly_bin118.fits', expMap='/scratch/kocevski/116496/expmap_542851201_545443201_4FGL_J2118.2+5752_monthly_bin118.fits', expCube='/scratch/kocevski/116496/ltcube_542851201_545443201_4FGL_J2118.2+5752_monthly_bin118.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/116496/Model_4FGL_J2118.2+5752_monthly_bin118.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J2118.2+5752'

4FGL J2118.2+5752
   Spectrum: PowerLaw
372    Prefactor:  3.009e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
373        Index:  2.516e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
374        Scale:  1.366e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/116496/ft1_filtered_4FGL_J2118.2+5752_monthly_bin118.fits
Spacecraft file(s): /scratch/kocevski/116496/ft2_4FGL_J2118.2+5752_monthly_bin118.fits
Exposure map: /scratch/kocevski/116496/expmap_542851201_545443201_4FGL_J2118.2+5752_monthly_bin118.fits
Exposure cube: /scratch/kocevski/116496/ltcube_542851201_545443201_4FGL_J2118.2+5752_monthly_bin118.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/116496/Model_4FGL_J2118.2+5752_monthly_bin118.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) = 2458.31711917

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    .10067E-03   1.0000         .10000E-03   10000.    
     2 'norm      '    55.834       1.0000         .10000E-03   10000.    
     3 'Prefactor '    10.671       1.0000         .10000E-03   10000.    
     4 'norm      '    .10004E-03   1.0000         .10000E-03   10000.    
     5 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
     6 'norm      '    .10004E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    69.570       1.0000         .10000E-03   10000.    
     8 'Prefactor '    78.482       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10950E-03   1.0000         .10000E-03   10000.    
    10 'norm      '    .10011E-03   1.0000         .10000E-03   10000.    
    11 'norm      '    .10216E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    13 'Normalizat'    .56100       1.0000         .10000E-01   10.000    
    14 'Prefactor '    .94241       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6810E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   2458.306     FROM MIGRAD    STATUS=CONVERGED     70 CALLS     1017 TOTAL
                     EDM=   .88E-10  STRATEGY=1  ERROR MATRIX UNCERTAINTY= 13.2%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .10000E-03    6.2418       -.95215E-05** at limit **
   2  norm          55.830        1.5821       -.98486E-06    .21808E-02
   3  Prefactor     10.662        2.7976       -.48011E-05    .20987E-02
   4  norm          .10000E-03    6.6361       -.37272E-05** at limit **
   5  norm          .10000E-03    20.475        .90543E-05** at limit **
   6  norm          .10000E-03    6.2276        .37694E-05** at limit **
   7  Prefactor     69.560        3.2438       -.22362E-05    .66582E-02
   8  Prefactor     78.484        1.1455        .37726E-06   -.11868E-02
   9  Prefactor     .10010E-03    89.772       -.66357E-04** at limit **
  10  norm          .10000E-03    13.865       -.35180E-05** at limit **
  11  norm          .10000E-03    31.702       -.22014E-04** at limit **
  12  Prefactor     .10004E-03    50.763        .67806E-04** at limit **
  13  Normalizat    .56115        .92990       -.12156E-03   -.14303E-05
  14  Prefactor     .94236        .97060E-01    .69564E-05   -.23715E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 0.0001
  norm       = 55.8302
  Prefactor  = 10.662
  norm       = 0.0001
  norm       = 0.0001
  norm       = 0.0001
  Prefactor  = 69.5604
  Prefactor  = 78.4835
  Prefactor  = 0.000100101
  norm       = 0.0001
  norm       = 0.000100004
  Prefactor  = 0.000100039
  Normalizat = 0.561147
  Prefactor  = 0.942359
 **********
 **   18 **HESSE 
 **********

 FCN=   2458.306     FROM HESSE     STATUS=OK           192 CALLS     1209 TOTAL
                     EDM=   .13E-05    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          .10000E-03    6.2418        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  norm          55.830        88.970        .13421E-02   -1.4212    
   3  Prefactor     10.662        164.42        .30663E-02   -1.5055    
   4  norm          .10000E-03    6.6354        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  norm          .10000E-03    20.478        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  norm          .10000E-03    6.2278        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     69.560        124.56        .12031E-02   -1.4038    
   8  Prefactor     78.484        70.891        .11333E-02   -1.3934    
   9  Prefactor     .10010E-03    88.873        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  norm          .10000E-03    13.856        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  norm          .10000E-03    9.9656        .49029E-01   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10004E-03    50.766        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Normalizat    .56115        1.1520        .31402       -1.0966    
  14  Prefactor     .94236        .12010        .24843E-01   -.94676    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.25909e-06
Minuit parameter uncertainties:
  1  1.8656e-05
  2  89.1831
  3  84.0145
  4  5.25915e-06
  5  3.77738e-05
  6  2.32649e-06
  7  125.035
  8  70.9677
  9  0.00598691
  10  1.04192e-05
  11  0.000411417
  12  0.00281662
  13  1.20769
  14  0.120131
Done.

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

Extracting fit parameters...

4FGL J2118.2+5752
   Spectrum: PowerLaw
372    Prefactor:  7.848e+01  7.097e+01  1.000e-04  1.000e+04 ( 1.000e-13)
373        Index:  2.516e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
374        Scale:  1.366e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
670    Prefactor:  9.424e-01  1.201e-01  0.000e+00  1.000e+01 ( 1.000e+00)
671        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
672        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
658   Normalization:  5.611e-01  1.208e+00  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 1.95
Ra Dec: 319.551 57.870
Photon Index (Fixed Index): 2.52 +/- 0.00
Photon Flux (Fixed Index): 3.73e-07 +/- 3.37e-07
Energy Flux (Fixed Index): 1.06e-04 +/- 9.61e-05

TS (Fixed Index): 1.95
Ra Dec: 319.551 57.870
Photon Flux Upper Limit: 1.14e-06 ph cm-2 s-1
Energy Flux Upper Limit: 8.87e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/116496/likelihoodResults_542851201_545443201_4FGL_J2118.2+5752_monthly_bin118.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) = 2458.1712453
delta logL = 0.134529684602

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 2458.16511294
delta logL = 0.14066204284

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    38.209       1.0000         .10000E-03   10000.    
     2 'Index     '    2.9752       1.0000          .0000       10.000    
     3 'Normalizat'    .49631       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .94436       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6810E+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=   2458.165     FROM MIGRAD    STATUS=CONVERGED     90 CALLS      300 TOTAL
                     EDM=   .57E-10    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     38.279        94.705        .64840E-04    .53985E-04
   2  Index         2.9744        1.1907        .36821E-02    .43852E-04
   3  Normalizat    .49623        .94162        .14637E-02   -.84272E-05
   4  Prefactor     .94440        .97371E-01    .10966E-03    .53651E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 38.2785
  Index      = 2.97445
  Normalizat = 0.496226
  Prefactor  = 0.944396
 **********
 **   18 **HESSE 
 **********

 FCN=   2458.165     FROM HESSE     STATUS=OK            25 CALLS      325 TOTAL
                     EDM=   .40E-10    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     38.279        74.760        .12968E-04   -1.4470    
   2  Index         2.9744        .94194        .14729E-03   -.41710    
   3  Normalizat    .49623        .93855        .58549E-04   -1.1259    
   4  Prefactor     .94440        .97131E-01    .43864E-05   -.94607    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 4.03115e-11
Minuit parameter uncertainties:
  1  74.9437
  2  0.948733
  3  0.971263
  4  0.0971485
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/116496': 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) = 2458.16511235
delta logL = 0.140662631784

Extracting fit parameters...

4FGL J2118.2+5752
   Spectrum: PowerLaw
372    Prefactor:  3.828e+01  7.494e+01  1.000e-04  1.000e+04 ( 1.000e-13)
373        Index:  2.974e+00  9.487e-01  0.000e+00  1.000e+01 (-1.000e+00)
374        Scale:  1.366e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
670    Prefactor:  9.444e-01  9.715e-02  0.000e+00  1.000e+01 ( 1.000e+00)
671        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
672        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
658   Normalization:  4.962e-01  9.713e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 2.25
Ra Dec: 319.551 57.870
Photon Index (Free Index): 2.97 +/- 0.95
Photon Flux (Free Index): 4.63e-07 +/- 4.00e-07
Energy Flux (Free Index): 9.36e-05 +/- 8.17e-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/116496/cmap_HighResolution_542851201_545443201_4FGL_J2118.2+5752_monthly_bin118.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='8.87e-02', comment='SUCCESS', photon_flux='3.73e-07', energy_flux2='9.36e-05', photon_flux_error='3.37e-07', dlogl='1.41e-01', energy_flux='1.06e-04', photon_flux2='4.63e-07', job_status='DONE', time_completed='2021-11-06 22:45:45.515786', photon_index_error2='0.95', photon_index2='2.97', ts='1.95', fit_tolerance='1e-08', GAL='0.94', photon_index_error='0.00', photon_flux_upper_limit='1.14e-06', energy_flux_error2='8.17e-05', EG='0.56', time_epoch_completed='1636263945.52', return_code='0', job_id='116496', GAL2='0.94', EG2='0.50', return_code2='0', energy_flux_error='9.61e-05', photon_flux_error2='4.00e-07', ts2='2.25', photon_index='2.52' WHERE bin_id='118' AND source_name='4FGL J2118.2+5752' AND cadence='monthly';

Database successfully updated.


Analysis Complete.


Sat Nov  6 22:45:45 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0048>
Subject: Job 116496: <4FGL_J2118.2+5752_monthly_bin118> in cluster <slac> Done

Job <4FGL_J2118.2+5752_monthly_bin118> was submitted from host <rhel6-64j> by user <kocevski> in cluster <slac> at Sat Nov  6 22:35:13 2021
Job was executed on host(s) <bullet0048>, in queue <medium>, as user <kocevski> in cluster <slac> at Sat Nov  6 22:35:15 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sat Nov  6 22:35:15 2021
Terminated at Sat Nov  6 22:45:46 2021
Results reported at Sat Nov  6 22:45:46 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J2118.2+5752_monthly_bin118 319.551 57.8703 542851201 545443201 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J2118.2+5752 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   557.00 sec.
    Max Memory :                                 1097 MB
    Average Memory :                             258.95 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   630 sec.
    Turnaround time :                            633 sec.

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

