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


Performing analysis on: 4FGL_J1059.5+2057_daily_bin134
RA = 164.878, Dec = 20.9524
tmin = 274060801, tmax = 274320001
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='410324', job_status='RUN', time_executed='2021-09-03 02:33:29.060610', time_epoch_executed='1630661609.06' WHERE source_name='4FGL J1059.5+2057' and cadence='daily' and bin_id='134'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/410324

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/410324/ft1_4FGL_J1059.5+2057_daily_bin134.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/410324/ft2_4FGL_J1059.5+2057_daily_bin134.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/410324/ft1_4FGL_J1059.5+2057_daily_bin134.fits outfile=/scratch/kocevski/410324/ft1_filteredMKT_4FGL_J1059.5+2057_daily_bin134.fits ra=164.878 dec=20.9524 rad=12.0 tmin=274060801.0 tmax=274320001.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.84
user 3.46
sys 0.20

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/410324/ft2_4FGL_J1059.5+2057_daily_bin134.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/410324/ft2_4FGL_J1059.5+2057_daily_bin134.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/410324/ft1_filteredMKT_4FGL_J1059.5+2057_daily_bin134.fits evtable="EVENTS" outfile="/scratch/kocevski/410324/ft1_filtered_4FGL_J1059.5+2057_daily_bin134.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.53
user 0.34
sys 0.15

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/410324/ft1_filtered_4FGL_J1059.5+2057_daily_bin134.fits" evtable="EVENTS" scfile=/scratch/kocevski/410324/ft2_4FGL_J1059.5+2057_daily_bin134.fits sctable="SC_DATA" outfile=/scratch/kocevski/410324/ltcube_274060801_274320001_4FGL_J1059.5+2057_daily_bin134.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/410324/ft2_4FGL_J1059.5+2057_daily_bin134.fits
.....................!
real 15.47
user 15.10
sys 0.33

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/410324/ft1_filtered_4FGL_J1059.5+2057_daily_bin134.fits evtable="EVENTS" scfile=/scratch/kocevski/410324/ft2_4FGL_J1059.5+2057_daily_bin134.fits sctable="SC_DATA" expcube=/scratch/kocevski/410324/ltcube_274060801_274320001_4FGL_J1059.5+2057_daily_bin134.fits outfile=/scratch/kocevski/410324/expmap_274060801_274320001_4FGL_J1059.5+2057_daily_bin134.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/410324/ltcube_274060801_274320001_4FGL_J1059.5+2057_daily_bin134.fits
.....................!
real 191.84
user 186.41
sys 4.83

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

Setting source of interest to:
4FGL J1059.5+2057 @ 164.878 20.9524

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/410324/ft1_filtered_4FGL_J1059.5+2057_daily_bin134.fits scfile=/scratch/kocevski/410324/ft2_4FGL_J1059.5+2057_daily_bin134.fits outfile=/scratch/kocevski/410324/cmap_274060801_274320001_4FGL_J1059.5+2057_daily_bin134.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=164.878 yref=20.9524 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.38
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/410324/ft1_filtered_4FGL_J1059.5+2057_daily_bin134.fits scfile=/scratch/kocevski/410324/ft2_4FGL_J1059.5+2057_daily_bin134.fits outfile=/scratch/kocevski/410324/cmap_HighResolution_274060801_274320001_4FGL_J1059.5+2057_daily_bin134.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=164.878 yref=20.9524 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.39
sys 0.15

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/410324/ft1_filtered_4FGL_J1059.5+2057_daily_bin134.fits evtable="EVENTS" scfile=/scratch/kocevski/410324/ft2_4FGL_J1059.5+2057_daily_bin134.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/410324/Model_4FGL_J1059.5+2057_daily_bin134.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/410324/ft1_filtered_4FGL_J1059.5+2057_daily_bin134.fits.....................!
real 57.84
user 56.22
sys 1.23

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/410324/ft1_filtered_4FGL_J1059.5+2057_daily_bin134.fits', '/scratch/kocevski/410324/ft2_4FGL_J1059.5+2057_daily_bin134.fits', expMap='/scratch/kocevski/410324/expmap_274060801_274320001_4FGL_J1059.5+2057_daily_bin134.fits', expCube='/scratch/kocevski/410324/ltcube_274060801_274320001_4FGL_J1059.5+2057_daily_bin134.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/410324/Model_4FGL_J1059.5+2057_daily_bin134.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1059.5+2057'

4FGL J1059.5+2057
   Spectrum: PowerLaw
250    Prefactor:  2.435e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
251        Index:  2.415e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
252        Scale:  1.122e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/410324/ft1_filtered_4FGL_J1059.5+2057_daily_bin134.fits
Spacecraft file(s): /scratch/kocevski/410324/ft2_4FGL_J1059.5+2057_daily_bin134.fits
Exposure map: /scratch/kocevski/410324/expmap_274060801_274320001_4FGL_J1059.5+2057_daily_bin134.fits
Exposure cube: /scratch/kocevski/410324/ltcube_274060801_274320001_4FGL_J1059.5+2057_daily_bin134.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/410324/Model_4FGL_J1059.5+2057_daily_bin134.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) = 6102.47234731

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    19.094       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10186E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10008E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10022E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .12767E-01   1.0000         .10000E-03   10000.    
     7 'Prefactor '    6.2608       1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    22.306       1.0000         .10000E-03   10000.    
    10 'norm      '    .10978E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    .65955       1.0000         .10000E-03   10000.    
    12 'Prefactor '    8.5434       1.0000         .10000E-03   10000.    
    13 'norm      '    .10006E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    17 'Prefactor '    40.091       1.0000         .10000E-03   10000.    
    18 'Prefactor '    9.6335       1.0000         .10000E-03   10000.    
    19 'Normalizat'    .95704       1.0000         .10000E-01   10.000    
    20 'Prefactor '    1.4110       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5780E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   6102.426     FROM MIGRAD    STATUS=CONVERGED    428 CALLS     2075 TOTAL
                     EDM=   .92E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .4%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          19.091        12.154       -.13163E-07   -.23293E-04
   2  Prefactor     .10000E-03    26.863        .31682E-06** at limit **
   3  Prefactor     .10000E-03    3.7971       -.88284E-07** at limit **
   4  Prefactor     .10000E-03    .89121       -.27082E-07** at limit **
   5  Prefactor     .10000E-03    6.1787        .21163E-05** at limit **
   6  Prefactor     .10000E-03    10.740        .23707E-05** at limit **
   7  Prefactor     6.2633        13.738       -.75354E-05   -.46059E-03
   8  Prefactor     .10000E-03    9.5543        .38535E-05** at limit **
   9  Prefactor     22.300        24.653       -.65111E-07   -.41916E-03
  10  norm          .10004E-03    .73224       -.53470E-06** at limit **
  11  Prefactor     .65700        2.5144       -.21261E-05   -.60141E-03
  12  Prefactor     8.5427        8.6087       -.88830E-06   -.10074E-03
  13  norm          .10000E-03    5.8578       -.80119E-06** at limit **
  14  norm          .10000E-03    9.0532        .31985E-05** at limit **
  15  Prefactor     .10000E-03    4.5719        .87735E-07** at limit **
  16  Prefactor     .10000E-03    10.408       -.38398E-05** at limit **
  17  Prefactor     40.052        41.346       -.37140E-04    .28111E-04
  18  Prefactor     9.6329        12.797        .92230E-06   -.20508E-04
  19  Normalizat    .95687        .20333        .48076E-05   -.18070E-04
  20  Prefactor     1.4112        .20880        .10193E-05    .15379E-03
                               ERR DEF=  .500    
Final values: 
  norm       = 19.0912
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.000100003
  Prefactor  = 6.26325
  Prefactor  = 0.0001
  Prefactor  = 22.2995
  norm       = 0.000100044
  Prefactor  = 0.656999
  Prefactor  = 8.54273
  norm       = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 40.0521
  Prefactor  = 9.63292
  Normalizat = 0.956874
  Prefactor  = 1.41122
 **********
 **   18 **HESSE 
 **********

 FCN=   6102.426     FROM HESSE     STATUS=OK           293 CALLS     2368 TOTAL
                     EDM=   .65E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          19.091        12.145        .91660E-04   -1.4834    
   2  Prefactor     .10000E-03    26.887        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10000E-03    3.8236        .14859E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    .89741        .71960E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10000E-03    6.3806        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    93.757        .40564E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     6.2633        13.190        .16043E-03   -1.5207    
   8  Prefactor     .10000E-03    9.5996        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     22.300        23.140        .84810E-04   -1.4763    
  10  norm          .10004E-03    8.0754        .12649E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .65700        3.9824        .22384E-02   -1.5546    
  12  Prefactor     8.5427        8.5992        .13714E-03   -1.5123    
  13  norm          .10000E-03    5.8718        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          .10000E-03    9.1591        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .10000E-03    4.5786        .16311E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     .10000E-03    10.423        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  Prefactor     40.052        41.107        .63305E-04   -1.4441    
  18  Prefactor     9.6329        12.785        .12911E-03   -1.5087    
  19  Normalizat    .95687        .23547        .27799E-03   -.94490    
  20  Prefactor     1.4112        .24948        .25397E-03   -.80057    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 6.4971e-09
Minuit parameter uncertainties:
  1  12.1461
  2  6.7294e-05
  3  1.98404e-05
  4  2.64076e-06
  5  5.74904e-05
  6  0.000976101
  7  13.1961
  8  1.55433e-05
  9  23.1497
  10  0.00119067
  11  3.23515
  12  8.60041
  13  8.15741e-05
  14  4.72582e-05
  15  3.19539e-06
  16  1.48226e-05
  17  41.1356
  18  12.7888
  19  0.235724
  20  0.249692
Done.

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

Extracting fit parameters...

4FGL J1059.5+2057
   Spectrum: PowerLaw
250    Prefactor:  2.230e+01  2.315e+01  1.000e-04  1.000e+04 ( 1.000e-13)
251        Index:  2.415e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
252        Scale:  1.122e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
575    Prefactor:  1.411e+00  2.497e-01  0.000e+00  1.000e+01 ( 1.000e+00)
576        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
577        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
574   Normalization:  9.569e-01  2.357e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 1.39
Ra Dec: 164.878 20.952
Photon Index (Fixed Index): 2.41 +/- 0.00
Photon Flux (Fixed Index): 5.42e-08 +/- 5.62e-08
Energy Flux (Fixed Index): 1.74e-05 +/- 1.81e-05

TS (Fixed Index): 1.39
Ra Dec: 164.878 20.952
Photon Flux Upper Limit: 1.56e-07 ph cm-2 s-1
Energy Flux Upper Limit: 1.21e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/410324/likelihoodResults_274060801_274320001_4FGL_J1059.5+2057_daily_bin134.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) = 6102.41561638
delta logL = 0.010273997169

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 6101.72610394
delta logL = 0.699786442448

Fit tolerance = 1e-08

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

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

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   6101.726     FROM MIGRAD    STATUS=CONVERGED     62 CALLS      398 TOTAL
                     EDM=   .53E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .72648E-03    .86890E-02    .37899E-03** at limit **
   2  Index         7.5714        2.2447        .11916        .12267E-03
   3  Normalizat    .86682        .47544E-01    .65733E-01    .30746E-05
   4  Prefactor     1.5055        .51694E-01    .55992E-01   -.40338E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000726477
  Index      = 7.57138
  Normalizat = 0.866816
  Prefactor  = 1.50554
 **********
 **   18 **HESSE 
 **********

 FCN=   6101.726     FROM HESSE     STATUS=NOT POSDEF    33 CALLS      431 TOTAL
                     EDM=   .47E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .72648E-03    .20767E-01    .15847E-04   -1.5703    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         7.5714        7.4006        .46831E-02    .54016    
   3  Normalizat    .86682        .17821        .29078E-03   -.97636    
   4  Prefactor     1.5055        .18957        .24757E-03   -.77385    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 4.68867e-08
Minuit parameter uncertainties:
  1  0.00721382
  2  4.29854
  3  0.178329
  4  0.189661
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/410324': 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) = 6101.7260903
delta logL = 0.699800085412

Extracting fit parameters...

4FGL J1059.5+2057
   Spectrum: PowerLaw
250    Prefactor:  7.265e-04  7.214e-03  1.000e-04  1.000e+04 ( 1.000e-13)
251        Index:  7.571e+00  4.299e+00  0.000e+00  1.000e+01 (-1.000e+00)
252        Scale:  1.122e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
575    Prefactor:  1.506e+00  1.897e-01  0.000e+00  1.000e+01 ( 1.000e+00)
576        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
577        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
574   Normalization:  8.668e-01  1.783e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 3.08
Ra Dec: 164.878 20.952
Photon Index (Free Index): 7.57 +/- 4.30
Photon Flux (Free Index): 1.00e-07 +/- 6.90e-08
Energy Flux (Free Index): 1.18e-05 +/- 8.57e-06

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/410324/cmap_HighResolution_274060801_274320001_4FGL_J1059.5+2057_daily_bin134.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='1.21e-02', comment='SUCCESS', photon_flux='5.42e-08', energy_flux2='1.18e-05', photon_flux_error='5.62e-08', dlogl='7.00e-01', energy_flux='1.74e-05', photon_flux2='1.00e-07', job_status='DONE', time_completed='2021-09-03 02:44:02.358888', photon_index_error2='4.30', photon_index2='7.57', ts='1.39', fit_tolerance='1e-08', GAL='1.41', photon_index_error='0.00', photon_flux_upper_limit='1.56e-07', energy_flux_error2='8.57e-06', EG='0.96', time_epoch_completed='1630662242.36', return_code='0', job_id='410324', GAL2='1.51', EG2='0.87', return_code2='102', energy_flux_error='1.81e-05', photon_flux_error2='6.90e-08', ts2='3.08', photon_index='2.41' WHERE bin_id='134' AND source_name='4FGL J1059.5+2057' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Fri Sep  3 02:44:02 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0237>
Subject: Job 410324: <4FGL_J1059.5+2057_daily_bin134> in cluster <slac> Done

Job <4FGL_J1059.5+2057_daily_bin134> was submitted from host <rhel6-64h> by user <kocevski> in cluster <slac> at Fri Sep  3 02:31:42 2021
Job was executed on host(s) <bullet0237>, in queue <medium>, as user <kocevski> in cluster <slac> at Fri Sep  3 02:31:52 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Fri Sep  3 02:31:52 2021
Terminated at Fri Sep  3 02:44:03 2021
Results reported at Fri Sep  3 02:44:03 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1059.5+2057_daily_bin134 164.878 20.9524 274060801 274320001 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1059.5+2057 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   629.48 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             275.88 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   730 sec.
    Turnaround time :                            741 sec.

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

