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


Performing analysis on: 4FGL_J1058.6+2817_daily_bin787
RA = 164.65, Dec = 28.2866
tmin = 443318401, tmax = 443577601
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='355097', job_status='RUN', time_executed='2021-09-02 23:36:40.431253', time_epoch_executed='1630651000.43' WHERE source_name='4FGL J1058.6+2817' and cadence='daily' and bin_id='787'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/355097

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/355097/ft1_4FGL_J1058.6+2817_daily_bin787.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/355097/ft2_4FGL_J1058.6+2817_daily_bin787.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/355097/ft1_4FGL_J1058.6+2817_daily_bin787.fits outfile=/scratch/kocevski/355097/ft1_filteredMKT_4FGL_J1058.6+2817_daily_bin787.fits ra=164.65 dec=28.2866 rad=12.0 tmin=443318401.0 tmax=443577601.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 4.98
user 4.52
sys 0.26

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/355097/ft2_4FGL_J1058.6+2817_daily_bin787.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/355097/ft2_4FGL_J1058.6+2817_daily_bin787.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/355097/ft1_filteredMKT_4FGL_J1058.6+2817_daily_bin787.fits evtable="EVENTS" outfile="/scratch/kocevski/355097/ft1_filtered_4FGL_J1058.6+2817_daily_bin787.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.70
user 0.36
sys 0.18

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/355097/ft1_filtered_4FGL_J1058.6+2817_daily_bin787.fits" evtable="EVENTS" scfile=/scratch/kocevski/355097/ft2_4FGL_J1058.6+2817_daily_bin787.fits sctable="SC_DATA" outfile=/scratch/kocevski/355097/ltcube_443318401_443577601_4FGL_J1058.6+2817_daily_bin787.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/355097/ft2_4FGL_J1058.6+2817_daily_bin787.fits
.....................!
real 18.32
user 17.34
sys 0.37

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/355097/ft1_filtered_4FGL_J1058.6+2817_daily_bin787.fits evtable="EVENTS" scfile=/scratch/kocevski/355097/ft2_4FGL_J1058.6+2817_daily_bin787.fits sctable="SC_DATA" expcube=/scratch/kocevski/355097/ltcube_443318401_443577601_4FGL_J1058.6+2817_daily_bin787.fits outfile=/scratch/kocevski/355097/expmap_443318401_443577601_4FGL_J1058.6+2817_daily_bin787.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/355097/ltcube_443318401_443577601_4FGL_J1058.6+2817_daily_bin787.fits
.....................!
real 195.56
user 188.65
sys 6.12

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

Setting source of interest to:
4FGL J1058.6+2817 @ 164.65 28.2866

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/355097/ft1_filtered_4FGL_J1058.6+2817_daily_bin787.fits scfile=/scratch/kocevski/355097/ft2_4FGL_J1058.6+2817_daily_bin787.fits outfile=/scratch/kocevski/355097/cmap_443318401_443577601_4FGL_J1058.6+2817_daily_bin787.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.65 yref=28.2866 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.57
user 0.40
sys 0.16

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/355097/ft1_filtered_4FGL_J1058.6+2817_daily_bin787.fits scfile=/scratch/kocevski/355097/ft2_4FGL_J1058.6+2817_daily_bin787.fits outfile=/scratch/kocevski/355097/cmap_HighResolution_443318401_443577601_4FGL_J1058.6+2817_daily_bin787.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.65 yref=28.2866 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.59
user 0.42
sys 0.15

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/355097/ft1_filtered_4FGL_J1058.6+2817_daily_bin787.fits evtable="EVENTS" scfile=/scratch/kocevski/355097/ft2_4FGL_J1058.6+2817_daily_bin787.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/355097/Model_4FGL_J1058.6+2817_daily_bin787.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/355097/ft1_filtered_4FGL_J1058.6+2817_daily_bin787.fits....................!
real 51.06
user 48.94
sys 1.31

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/355097/ft1_filtered_4FGL_J1058.6+2817_daily_bin787.fits', '/scratch/kocevski/355097/ft2_4FGL_J1058.6+2817_daily_bin787.fits', expMap='/scratch/kocevski/355097/expmap_443318401_443577601_4FGL_J1058.6+2817_daily_bin787.fits', expCube='/scratch/kocevski/355097/ltcube_443318401_443577601_4FGL_J1058.6+2817_daily_bin787.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/355097/Model_4FGL_J1058.6+2817_daily_bin787.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1058.6+2817'

4FGL J1058.6+2817
   Spectrum: PowerLaw
233    Prefactor:  2.847e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
234        Index:  2.226e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
235        Scale:  1.335e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/355097/ft1_filtered_4FGL_J1058.6+2817_daily_bin787.fits
Spacecraft file(s): /scratch/kocevski/355097/ft2_4FGL_J1058.6+2817_daily_bin787.fits
Exposure map: /scratch/kocevski/355097/expmap_443318401_443577601_4FGL_J1058.6+2817_daily_bin787.fits
Exposure cube: /scratch/kocevski/355097/ltcube_443318401_443577601_4FGL_J1058.6+2817_daily_bin787.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/355097/Model_4FGL_J1058.6+2817_daily_bin787.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) = 5478.7204172

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    9.0721       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    1.4945       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10935E-02   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10593E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    9.3685       1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10068E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10365E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    26.850       1.0000         .10000E-03   10000.    
    12 'Prefactor '    1.5692       1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10016E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    12.523       1.0000         .10000E-03   10000.    
    15 'norm      '    1.2329       1.0000         .10000E-03   10000.    
    16 'Prefactor '    3.5040       1.0000         .10000E-03   10000.    
    17 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    19 'norm      '    2.8366       1.0000         .10000E-03   10000.    
    20 'Prefactor '    3.9994       1.0000         .10000E-03   10000.    
    21 'norm      '    1.0257       1.0000         .10000E-03   10000.    
    22 'Prefactor '    5.1200       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10481E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10011E-03   1.0000         .10000E-03   10000.    
    25 'Prefactor '    21.749       1.0000         .10000E-03   10000.    
    26 'Prefactor '    4.2707       1.0000         .10000E-03   10000.    
    27 'Prefactor '    3.0310       1.0000         .10000E-03   10000.    
    28 'Prefactor '    4.2505       1.0000         .10000E-03   10000.    
    29 'Normalizat'    .83513       1.0000         .10000E-01   10.000    
    30 'Prefactor '    .91846       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5550E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   5478.709     FROM MIGRAD    STATUS=CONVERGED    758 CALLS     3931 TOTAL
                     EDM=   .44E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.2%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          9.0731        6.9052        .82320E-07   -.38442E-06
   2  Prefactor     .10000E-03    1.1357        .82600E-07** at limit **
   3  Prefactor     1.4902        3.6857       -.57282E-06    .60957E-04
   4  Prefactor     .10000E-03    23.007        .74177E-05** at limit **
   5  Prefactor     .10000E-03    200.91       -.28828E-04** at limit **
   6  Prefactor     .10000E-03    4.0172        .33256E-06** at limit **
   7  Prefactor     9.3697        6.4197       -.16062E-06   -.46565E-04
   8  Prefactor     .10000E-03    29.440        .10092E-04** at limit **
   9  Prefactor     .10000E-03    .64580       -.12925E-06** at limit **
  10  Prefactor     .10000E-03    3.2220       -.14193E-06** at limit **
  11  Prefactor     26.852        23.310       -.37787E-06    .11000E-04
  12  Prefactor     1.5615        11.453        .97743E-05   -.11893E-04
  13  Prefactor     .10000E-03    8.2537       -.33595E-06** at limit **
  14  Prefactor     12.525        14.763       -.93776E-06   -.15291E-03
  15  norm          1.2329        .29459       -.15537E-07    .43671E-04
  16  Prefactor     3.5047        2.8506       -.15469E-06   -.17914E-04
  17  Prefactor     .10000E-03    4.0647       -.84756E-06** at limit **
  18  Prefactor     .10000E-03    3.9525        .59975E-06** at limit **
  19  norm          2.8383        7.6289       -.24125E-05   -.41394E-04
  20  Prefactor     4.0001        6.9851        .10309E-06   -.22584E-03
  21  norm          1.0271        1.6035        .70803E-07   -.75171E-03
  22  Prefactor     5.1207        8.7620       -.24039E-06   -.96865E-04
  23  Prefactor     .10000E-03    1.3311        .95287E-06** at limit **
  24  Prefactor     .10000E-03    25.208       -.16254E-04** at limit **
  25  Prefactor     21.753        16.888       -.16509E-05    .97012E-05
  26  Prefactor     4.2700        10.904        .77857E-06    .34056E-04
  27  Prefactor     3.0322        4.9037       -.46367E-05   -.26281E-03
  28  Prefactor     4.2526        19.111       -.15812E-05    .19716E-05
  29  Normalizat    .83515        .17036        .20598E-05   -.12883E-03
  30  Prefactor     .91827        .18627       -.87419E-06    .37115E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 9.0731
  Prefactor  = 0.0001
  Prefactor  = 1.4902
  Prefactor  = 0.0001
  Prefactor  = 0.000100003
  Prefactor  = 0.0001
  Prefactor  = 9.36969
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 26.8523
  Prefactor  = 1.56153
  Prefactor  = 0.0001
  Prefactor  = 12.5247
  norm       = 1.23291
  Prefactor  = 3.50471
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 2.83826
  Prefactor  = 4.00015
  norm       = 1.02709
  Prefactor  = 5.12071
  Prefactor  = 0.000100002
  Prefactor  = 0.0001
  Prefactor  = 21.7529
  Prefactor  = 4.27003
  Prefactor  = 3.03223
  Prefactor  = 4.25257
  Normalizat = 0.835155
  Prefactor  = 0.918273
 **********
 **   18 **HESSE 
 **********

 FCN=   5478.709     FROM HESSE     STATUS=OK           596 CALLS     4527 TOTAL
                     EDM=   .41E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          9.0731        6.9069        .13307E-03   -1.5105    
   2  Prefactor     .10000E-03    1.1368        .76916E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     1.4902        3.6707        .21256E-03   -1.5464    
   4  Prefactor     .10000E-03    22.992        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10000E-03    207.19        .41405E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    4.0878        .14470E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     9.3697        6.4241        .13093E-03   -1.5096    
   8  Prefactor     .10000E-03    29.440        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     .10000E-03    .65011        .58053E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .10000E-03    3.2335        .12960E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     26.852        23.330        .77311E-04   -1.4671    
  12  Prefactor     1.5615        11.192        .33940E-03   -1.5458    
  13  Prefactor     .10000E-03    8.3280        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     12.525        14.627        .11319E-03   -1.5000    
  15  norm          1.2329        .29567        .19033E-04   -1.5486    
  16  Prefactor     3.5047        2.8452        .10645E-03   -1.5334    
  17  Prefactor     .10000E-03    4.0793        .14569E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .10000E-03    3.9558        .14371E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  norm          2.8383        7.6067        .24144E-03   -1.5371    
  20  Prefactor     4.0001        7.0213        .10083E-02   -1.5308    
  21  norm          1.0271        14.950        .25267E-02   -1.5505    
  22  Prefactor     5.1207        8.7461        .88840E-03   -1.5255    
  23  Prefactor     .10000E-03    2.3241        .16368E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     .10000E-03    25.087        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     21.753        16.811        .85887E-04   -1.4775    
  26  Prefactor     4.2700        10.832        .19496E-03   -1.5295    
  27  Prefactor     3.0322        4.8876        .19547E-03   -1.5360    
  28  Prefactor     4.2526        19.133        .19544E-03   -1.5296    
  29  Normalizat    .83515        .19745        .23199E-03   -.98778    
  30  Prefactor     .91827        .21534        .25795E-03   -.95505    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 4.10234e-09
Minuit parameter uncertainties:
  1  6.90753
  2  1.3187e-06
  3  3.67129
  4  1.18885e-05
  5  0.00148503
  6  1.48317e-05
  7  6.42454
  8  3.18637e-06
  9  4.31008e-06
  10  4.62593e-05
  11  23.3376
  12  8.36313
  13  1.11363e-05
  14  14.6308
  15  0.295673
  16  2.84531
  17  5.6518e-06
  18  1.49012e-06
  19  7.60928
  20  7.02272
  21  7.83894
  22  8.74829
  23  0.000126933
  24  5.50177e-05
  25  16.8142
  26  10.8373
  27  4.88825
  28  18.05
  29  0.197623
  30  0.215539
Done.

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

Extracting fit parameters...

4FGL J1058.6+2817
   Spectrum: PowerLaw
233    Prefactor:  1.000e-04  1.114e-05  1.000e-04  1.000e+04 ( 1.000e-13)
234        Index:  2.226e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
235        Scale:  1.335e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
552    Prefactor:  9.183e-01  2.155e-01  0.000e+00  1.000e+01 ( 1.000e+00)
553        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
554        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
551   Normalization:  8.352e-01  1.976e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 164.650 28.287
Photon Flux Upper Limit: 6.06e-08 ph cm-2 s-1
Energy Flux Upper Limit: 4.62e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/355097/likelihoodResults_443318401_443577601_4FGL_J1058.6+2817_daily_bin787.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) = 5478.7092676
delta logL = -0.000572274707338

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 5478.70869597
delta logL = -6.51200934954e-07

Fit tolerance = 1e-08

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

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

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

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

 FCN=   5478.709     FROM MIGRAD    STATUS=FAILED        87 CALLS      238 TOTAL
                     EDM=   .13E-06    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    1006.5        .18142E-02** at limit **
   2  Index         2.2572        8.3173        .50000       -.16125E-04
   3  Normalizat    .83516        .52501E-01    .23199E-03    .73557E-04
   4  Prefactor     .91827        .61284E-01    .25795E-03    .57252E-04
                               ERR DEF=  .500    
 START SIMPLEX MINIMIZATION.    CONVERGENCE WHEN EDM .LT.   .20E-04
 SIMPLEX MINIMIZATION HAS CONVERGED.

 FCN=   5478.709     FROM SIMPLEX   STATUS=UNCHANGED    185 CALLS      423 TOTAL
                     EDM=   .16E-04    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    1006.5        .56739E-03** at limit **
   2  Index         2.2572        8.3173        .38185E-06   -.16125E-04
   3  Normalizat    .83516        .52501E-01    .15531E-07    .73557E-04
   4  Prefactor     .91827        .61284E-01    .79006E-08    .57252E-04
                               ERR DEF=  .500    

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   5478.709     FROM MIGRAD    STATUS=CONVERGED     34 CALLS      457 TOTAL
                     EDM=   .32E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    14.822        .36285E-03** at limit **
   2  Index         2.2574        5.9915        .50000       -.16127E-04
   3  Normalizat    .83516        .18148        .92795E-05    .70568E-04
   4  Prefactor     .91827        .21186        .10318E-04    .54651E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000100002
  Index      = 2.25738
  Normalizat = 0.835157
  Prefactor  = 0.91827
 **********
 **   18 **HESSE 
 **********

 FCN=   5478.709     FROM HESSE     STATUS=OK            29 CALLS      486 TOTAL
                     EDM=   .46E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    8.6255        .72569E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.2574        6.1282        .50000       -.58060    
   3  Normalizat    .83516        .18129        .18559E-05   -.98778    
   4  Prefactor     .91827        .21167        .20636E-05   -.95506    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 4.59944e-10
Minuit parameter uncertainties:
  1  0.000274397
  2  4.21868
  3  0.181419
  4  0.211862
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/355097': 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) = 5478.7086952
delta logL = 1.18971911434e-07

Extracting fit parameters...

4FGL J1058.6+2817
   Spectrum: PowerLaw
233    Prefactor:  1.000e-04  2.744e-04  1.000e-04  1.000e+04 ( 1.000e-13)
234        Index:  2.257e+00  4.219e+00  0.000e+00  1.000e+01 (-1.000e+00)
235        Scale:  1.335e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
552    Prefactor:  9.183e-01  2.119e-01  0.000e+00  1.000e+01 ( 1.000e+00)
553        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
554        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
551   Normalization:  8.352e-01  1.814e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 164.650 28.287

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/355097/cmap_HighResolution_443318401_443577601_4FGL_J1058.6+2817_daily_bin787.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='4.62e-03', job_status='DONE', photon_flux_upper_limit='6.06e-08', time_completed='2021-09-02 23:50:24.341316', job_id='355097', GAL2='0.92', fit_tolerance='1e-08', EG2='0.84', EG='0.84', time_epoch_completed='1630651824.34', return_code2='0', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.92', dlogl='1.19e-07', ts2='-0.00', photon_index_error='0.00', photon_index='2.23' WHERE bin_id='787' AND source_name='4FGL J1058.6+2817' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Sep  2 23:50:24 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0231>
Subject: Job 355097: <4FGL_J1058.6+2817_daily_bin787> in cluster <slac> Done

Job <4FGL_J1058.6+2817_daily_bin787> was submitted from host <rhel6-64p> by user <kocevski> in cluster <slac> at Thu Sep  2 23:36:10 2021
Job was executed on host(s) <bullet0231>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Sep  2 23:36:22 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Thu Sep  2 23:36:22 2021
Terminated at Thu Sep  2 23:50:24 2021
Results reported at Thu Sep  2 23:50:24 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1058.6+2817_daily_bin787 164.65 28.2866 443318401 443577601 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1058.6+2817 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   818.45 sec.
    Max Memory :                                 1255 MB
    Average Memory :                             326.69 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   842 sec.
    Turnaround time :                            854 sec.

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

