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


Performing analysis on: 4FGL_J0358.6+0634_daily_bin993
RA = 59.6656, Dec = 6.5759
tmin = 496713601, tmax = 496972801
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='109956', job_status='RUN', time_executed='2021-08-19 20:21:49.211744', time_epoch_executed='1629429709.21' WHERE source_name='4FGL J0358.6+0634' and cadence='daily' and bin_id='993'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/109956

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/109956/ft1_4FGL_J0358.6+0634_daily_bin993.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/109956/ft2_4FGL_J0358.6+0634_daily_bin993.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/109956/ft1_4FGL_J0358.6+0634_daily_bin993.fits outfile=/scratch/kocevski/109956/ft1_filteredMKT_4FGL_J0358.6+0634_daily_bin993.fits ra=59.6656 dec=6.5759 rad=12.0 tmin=496713601.0 tmax=496972801.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 8.63
user 4.66
sys 3.92

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/109956/ft2_4FGL_J0358.6+0634_daily_bin993.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/109956/ft2_4FGL_J0358.6+0634_daily_bin993.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/109956/ft1_filteredMKT_4FGL_J0358.6+0634_daily_bin993.fits evtable="EVENTS" outfile="/scratch/kocevski/109956/ft1_filtered_4FGL_J0358.6+0634_daily_bin993.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 3.84
user 0.32
sys 3.50

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/109956/ft1_filtered_4FGL_J0358.6+0634_daily_bin993.fits" evtable="EVENTS" scfile=/scratch/kocevski/109956/ft2_4FGL_J0358.6+0634_daily_bin993.fits sctable="SC_DATA" outfile=/scratch/kocevski/109956/ltcube_496713601_496972801_4FGL_J0358.6+0634_daily_bin993.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/109956/ft2_4FGL_J0358.6+0634_daily_bin993.fits
.....................!
real 16.07
user 11.52
sys 4.45

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/109956/ft1_filtered_4FGL_J0358.6+0634_daily_bin993.fits evtable="EVENTS" scfile=/scratch/kocevski/109956/ft2_4FGL_J0358.6+0634_daily_bin993.fits sctable="SC_DATA" expcube=/scratch/kocevski/109956/ltcube_496713601_496972801_4FGL_J0358.6+0634_daily_bin993.fits outfile=/scratch/kocevski/109956/expmap_496713601_496972801_4FGL_J0358.6+0634_daily_bin993.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/109956/ltcube_496713601_496972801_4FGL_J0358.6+0634_daily_bin993.fits
.....................!
real 195.30
user 186.70
sys 8.28

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

Setting source of interest to:
4FGL J0358.6+0634 @ 59.6656 6.5759

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/109956/ft1_filtered_4FGL_J0358.6+0634_daily_bin993.fits scfile=/scratch/kocevski/109956/ft2_4FGL_J0358.6+0634_daily_bin993.fits outfile=/scratch/kocevski/109956/cmap_496713601_496972801_4FGL_J0358.6+0634_daily_bin993.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=59.6656 yref=6.5759 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 4.17
user 0.38
sys 3.76

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/109956/ft1_filtered_4FGL_J0358.6+0634_daily_bin993.fits scfile=/scratch/kocevski/109956/ft2_4FGL_J0358.6+0634_daily_bin993.fits outfile=/scratch/kocevski/109956/cmap_HighResolution_496713601_496972801_4FGL_J0358.6+0634_daily_bin993.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=59.6656 yref=6.5759 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 4.13
user 0.40
sys 3.71

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/109956/ft1_filtered_4FGL_J0358.6+0634_daily_bin993.fits evtable="EVENTS" scfile=/scratch/kocevski/109956/ft2_4FGL_J0358.6+0634_daily_bin993.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/109956/Model_4FGL_J0358.6+0634_daily_bin993.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/109956/ft1_filtered_4FGL_J0358.6+0634_daily_bin993.fits.....................!
real 147.91
user 141.67
sys 5.97

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/109956/ft1_filtered_4FGL_J0358.6+0634_daily_bin993.fits', '/scratch/kocevski/109956/ft2_4FGL_J0358.6+0634_daily_bin993.fits', expMap='/scratch/kocevski/109956/expmap_496713601_496972801_4FGL_J0358.6+0634_daily_bin993.fits', expCube='/scratch/kocevski/109956/ltcube_496713601_496972801_4FGL_J0358.6+0634_daily_bin993.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/109956/Model_4FGL_J0358.6+0634_daily_bin993.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J0358.6+0634'

4FGL J0358.6+0634
   Spectrum: PowerLaw
232    Prefactor:  8.019e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
233        Index:  2.567e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
234        Scale:  7.663e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/109956/ft1_filtered_4FGL_J0358.6+0634_daily_bin993.fits
Spacecraft file(s): /scratch/kocevski/109956/ft2_4FGL_J0358.6+0634_daily_bin993.fits
Exposure map: /scratch/kocevski/109956/expmap_496713601_496972801_4FGL_J0358.6+0634_daily_bin993.fits
Exposure cube: /scratch/kocevski/109956/ltcube_496713601_496972801_4FGL_J0358.6+0634_daily_bin993.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/109956/Model_4FGL_J0358.6+0634_daily_bin993.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) = 11349.9797638

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10021E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    5.8789       1.0000         .10000E-03   10000.    
     3 'norm      '    3.4784       1.0000         .10000E-03   10000.    
     4 'norm      '    1.4642       1.0000         .10000E-03   10000.    
     5 'Prefactor '    59.539       1.0000         .10000E-03   10000.    
     6 'Prefactor '    8.1729       1.0000         .10000E-03   10000.    
     7 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     9 'norm      '    2.9330       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .45589E-03   1.0000         .10000E-03   10000.    
    11 'norm      '    .10150E-03   1.0000         .10000E-03   10000.    
    12 'norm      '    .35970       1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10177E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    3.2185       1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10035E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    .10012E-03   1.0000         .10000E-03   10000.    
    17 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    2.9008       1.0000         .10000E-03   10000.    
    19 'Normalizat'    .96051       1.0000         .10000E-01   10.000    
    20 'Prefactor '    .90709       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .4630E+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=   11349.98     FROM MIGRAD    STATUS=CONVERGED    735 CALLS     2694 TOTAL
                     EDM=   .31E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    7.8207        .36285E-03** at limit **
   2  Prefactor     5.8793        12.362        .16563E-03    .13042E-04
   3  norm          3.4782        3.8887        .21681E-03    .59777E-05
   4  norm          1.4642        1.0100        .85541E-04    .70971E-04
   5  Prefactor     59.530        47.330        .51996E-04    .17159E-03
   6  Prefactor     8.1775        15.467        .14024E-03    .28065E-03
   7  norm          .10000E-03    3.4261        .18142E-02** at limit **
   8  Prefactor     .10000E-03    8.6391        .18142E-02** at limit **
   9  norm          2.9333        2.6929        .80874E-03    .31932E-03
  10  Prefactor     .10000E-03    17.383        .11282    ** at limit **
  11  norm          .10000E-03    23.196        .18142E-02** at limit **
  12  norm          .35991        .75898        .12964E-03    .14477E-02
  13  Prefactor     .10000E-03    3.3265        .14544E-02** at limit **
  14  Prefactor     3.2153        13.774        .22581E-03    .46801E-03
  15  Prefactor     .10000E-03    21.883        .18142E-02** at limit **
  16  norm          .10000E-03    1.0851        .16954E-02** at limit **
  17  Prefactor     .10000E-03    22.904        .18142E-02** at limit **
  18  Prefactor     2.8986        6.4794        .23858E-03    .30421E-03
  19  Normalizat    .96039        .22207        .43824E-03    .60969E-03
  20  Prefactor     .90716        .63769E-01    .13718E-03    .20128E-02
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 5.87927
  norm       = 3.47816
  norm       = 1.46418
  Prefactor  = 59.5303
  Prefactor  = 8.17753
  norm       = 0.0001
  Prefactor  = 0.0001
  norm       = 2.93327
  Prefactor  = 0.000100005
  norm       = 0.000100001
  norm       = 0.359911
  Prefactor  = 0.000100003
  Prefactor  = 3.2153
  Prefactor  = 0.000100003
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 2.89862
  Normalizat = 0.96039
  Prefactor  = 0.907157
 **********
 **   18 **HESSE 
 **********

 FCN=   11349.98     FROM HESSE     STATUS=OK           281 CALLS     2975 TOTAL
                     EDM=   .32E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    7.8211        .72569E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     5.8793        12.360        .66250E-05   -1.5223    
   3  norm          3.4782        3.8887        .86725E-05   -1.5335    
   4  norm          1.4642        1.0100        .34216E-05   -1.5466    
   5  Prefactor     59.530        47.323        .10399E-04   -1.4163    
   6  Prefactor     8.1775        15.464        .56095E-05   -1.5136    
   7  norm          .10000E-03    3.4261        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .10000E-03    8.6393        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  norm          2.9333        2.6923        .32350E-04   -1.5365    
  10  Prefactor     .10000E-03    16.332        .11773       -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  norm          .10000E-03    23.209        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  norm          .35991        .75843        .51855E-05   -1.5588    
  13  Prefactor     .10000E-03    3.3664        .29088E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     3.2153        13.766        .90325E-05   -1.5349    
  15  Prefactor     .10000E-03    21.886        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          .10000E-03    1.0871        .33908E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  Prefactor     .10000E-03    22.906        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     2.8986        6.4786        .95432E-05   -1.5367    
  19  Normalizat    .96039        .22206        .17529E-04   -.94369    
  20  Prefactor     .90716        .63787E-01    .27435E-04   -.95891    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 3.19961e-09
Minuit parameter uncertainties:
  1  0.000116374
  2  12.365
  3  3.88895
  4  1.01002
  5  47.3525
  6  15.4714
  7  9.45251e-07
  8  1.39e-05
  9  2.69238
  10  0.000559106
  11  0.000222393
  12  0.758447
  13  0.00020564
  14  13.3108
  15  0.000487017
  16  1.44615e-05
  17  3.85628e-05
  18  6.48015
  19  0.222275
  20  0.0637923
Done.

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

Extracting fit parameters...

4FGL J0358.6+0634
   Spectrum: PowerLaw
232    Prefactor:  5.953e+01  4.735e+01  1.000e-04  1.000e+04 ( 1.000e-13)
233        Index:  2.567e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
234        Scale:  7.663e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
460    Prefactor:  9.072e-01  6.379e-02  0.000e+00  1.000e+01 ( 1.000e+00)
461        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
462        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
459   Normalization:  9.604e-01  2.223e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 2.53
Ra Dec: 59.666 6.576
Photon Index (Fixed Index): 2.57 +/- 0.00
Photon Flux (Fixed Index): 7.08e-08 +/- 5.63e-08
Energy Flux (Fixed Index): 1.92e-05 +/- 1.52e-05

TS (Fixed Index): 2.53
Ra Dec: 59.666 6.576
Photon Flux Upper Limit: 1.79e-07 ph cm-2 s-1
Energy Flux Upper Limit: 1.40e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/109956/likelihoodResults_496713601_496972801_4FGL_J0358.6+0634_daily_bin993.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) = 11349.2128119
delta logL = 0.762224241795

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 11349.2026822
delta logL = 0.772353900953

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    22.035       1.0000         .10000E-03   10000.    
     2 'Index     '    3.5933       1.0000          .0000       10.000    
     3 'Normalizat'    .90043       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .91718       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .4630E+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=   11349.20     FROM MIGRAD    STATUS=CONVERGED     91 CALLS      330 TOTAL
                     EDM=   .11E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     22.030        333.07        .85329E-04   -.12550E-02
   2  Index         3.5936        6.7040        .61343E-02   -.45339E-03
   3  Normalizat    .89988        .23335        .45082E-03   -.39829E-03
   4  Prefactor     .91735        .71141E-01    .13646E-03   -.12797E-02
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 22.0299
  Index      = 3.59356
  Normalizat = 0.899877
  Prefactor  = 0.917354
 **********
 **   18 **HESSE 
 **********

 FCN=   11349.20     FROM HESSE     STATUS=OK            25 CALLS      355 TOTAL
                     EDM=   .13E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     22.030        37.147        .17066E-04   -1.4769    
   2  Index         3.5936        1.0378        .24537E-03   -.28514    
   3  Normalizat    .89988        .21356        .18033E-04   -.96464    
   4  Prefactor     .91735        .63926E-01    .27291E-04   -.95537    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.33834e-09
Minuit parameter uncertainties:
  1  37.1858
  2  1.04602
  3  0.213763
  4  0.0639308
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/109956': 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) = 11349.2026781
delta logL = 0.772358046432

Extracting fit parameters...

4FGL J0358.6+0634
   Spectrum: PowerLaw
232    Prefactor:  2.203e+01  3.719e+01  1.000e-04  1.000e+04 ( 1.000e-13)
233        Index:  3.594e+00  1.046e+00  0.000e+00  1.000e+01 (-1.000e+00)
234        Scale:  7.663e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
460    Prefactor:  9.174e-01  6.393e-02  0.000e+00  1.000e+01 ( 1.000e+00)
461        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
462        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
459   Normalization:  8.999e-01  2.138e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 4.27
Ra Dec: 59.666 6.576
Photon Index (Free Index): 3.59 +/- 1.05
Photon Flux (Free Index): 1.28e-07 +/- 7.56e-08
Energy Flux (Free Index): 2.09e-05 +/- 1.22e-05

Creating a high resolution counts map...
INFO: Auto-setting vmin to -1.000e-01 [aplpy.core]
INFO: Auto-setting vmax to  1.110e+00 [aplpy.core]
Saving /scratch/kocevski/109956/cmap_HighResolution_496713601_496972801_4FGL_J0358.6+0634_daily_bin993.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='1.40e-02', comment='SUCCESS', photon_flux='7.08e-08', energy_flux2='2.09e-05', photon_flux_error='5.63e-08', dlogl='7.72e-01', energy_flux='1.92e-05', photon_flux2='1.28e-07', job_status='DONE', time_completed='2021-08-19 20:37:08.692989', photon_index_error2='1.05', photon_index2='3.59', ts='2.53', fit_tolerance='1e-08', GAL='0.91', photon_index_error='0.00', photon_flux_upper_limit='1.79e-07', energy_flux_error2='1.22e-05', EG='0.96', time_epoch_completed='1629430628.69', return_code='0', job_id='109956', GAL2='0.92', EG2='0.90', return_code2='0', energy_flux_error='1.52e-05', photon_flux_error2='7.56e-08', ts2='4.27', photon_index='2.57' WHERE bin_id='993' AND source_name='4FGL J0358.6+0634' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Aug 19 20:37:08 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0110>
Subject: Job 109956: <4FGL_J0358.6+0634_daily_bin993> in cluster <slac> Done

Job <4FGL_J0358.6+0634_daily_bin993> was submitted from host <rhel6-64a> by user <kocevski> in cluster <slac> at Thu Aug 19 20:20:38 2021
Job was executed on host(s) <bullet0110>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Aug 19 20:20:39 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Thu Aug 19 20:20:39 2021
Terminated at Thu Aug 19 20:37:10 2021
Results reported at Thu Aug 19 20:37:10 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J0358.6+0634_daily_bin993 59.6656 6.5759 496713601 496972801 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J0358.6+0634 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   969.15 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             336.88 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   990 sec.
    Turnaround time :                            992 sec.

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

