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


Performing analysis on: 4FGL_J1158.5+4824_daily_bin305
RA = 179.637, Dec = 48.4161
tmin = 318384001, tmax = 318643201
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='195980', job_status='RUN', time_executed='2021-09-04 17:31:21.273838', time_epoch_executed='1630801881.27' WHERE source_name='4FGL J1158.5+4824' and cadence='daily' and bin_id='305'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/195980

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/195980/ft1_4FGL_J1158.5+4824_daily_bin305.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/195980/ft2_4FGL_J1158.5+4824_daily_bin305.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/195980/ft1_4FGL_J1158.5+4824_daily_bin305.fits outfile=/scratch/kocevski/195980/ft1_filteredMKT_4FGL_J1158.5+4824_daily_bin305.fits ra=179.637 dec=48.4161 rad=12.0 tmin=318384001.0 tmax=318643201.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.25
user 3.04
sys 0.20

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/195980/ft2_4FGL_J1158.5+4824_daily_bin305.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/195980/ft2_4FGL_J1158.5+4824_daily_bin305.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/195980/ft1_filteredMKT_4FGL_J1158.5+4824_daily_bin305.fits evtable="EVENTS" outfile="/scratch/kocevski/195980/ft1_filtered_4FGL_J1158.5+4824_daily_bin305.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.49
user 0.34
sys 0.14

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/195980/ft1_filtered_4FGL_J1158.5+4824_daily_bin305.fits" evtable="EVENTS" scfile=/scratch/kocevski/195980/ft2_4FGL_J1158.5+4824_daily_bin305.fits sctable="SC_DATA" outfile=/scratch/kocevski/195980/ltcube_318384001_318643201_4FGL_J1158.5+4824_daily_bin305.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/195980/ft2_4FGL_J1158.5+4824_daily_bin305.fits
.....................!
real 12.21
user 11.88
sys 0.30

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/195980/ft1_filtered_4FGL_J1158.5+4824_daily_bin305.fits evtable="EVENTS" scfile=/scratch/kocevski/195980/ft2_4FGL_J1158.5+4824_daily_bin305.fits sctable="SC_DATA" expcube=/scratch/kocevski/195980/ltcube_318384001_318643201_4FGL_J1158.5+4824_daily_bin305.fits outfile=/scratch/kocevski/195980/expmap_318384001_318643201_4FGL_J1158.5+4824_daily_bin305.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/195980/ltcube_318384001_318643201_4FGL_J1158.5+4824_daily_bin305.fits
.....................!
real 191.17
user 186.00
sys 4.76

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

Setting source of interest to:
4FGL J1158.5+4824 @ 179.637 48.4161

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/195980/ft1_filtered_4FGL_J1158.5+4824_daily_bin305.fits scfile=/scratch/kocevski/195980/ft2_4FGL_J1158.5+4824_daily_bin305.fits outfile=/scratch/kocevski/195980/cmap_318384001_318643201_4FGL_J1158.5+4824_daily_bin305.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=179.637 yref=48.4161 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.39
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/195980/ft1_filtered_4FGL_J1158.5+4824_daily_bin305.fits scfile=/scratch/kocevski/195980/ft2_4FGL_J1158.5+4824_daily_bin305.fits outfile=/scratch/kocevski/195980/cmap_HighResolution_318384001_318643201_4FGL_J1158.5+4824_daily_bin305.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=179.637 yref=48.4161 axisrot=0.0 rafield="RA" decfield="DEC" proj="AIT" hpx_ordering_scheme="RING" hpx_order=3 hpx_ebin=yes hpx_region="" evtable="EVENTS" sctable="SC_DATA" efield="ENERGY" tfield="TIME" chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

This is gtbin version HEAD
real 0.54
user 0.38
sys 0.15

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/195980/ft1_filtered_4FGL_J1158.5+4824_daily_bin305.fits evtable="EVENTS" scfile=/scratch/kocevski/195980/ft2_4FGL_J1158.5+4824_daily_bin305.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/195980/Model_4FGL_J1158.5+4824_daily_bin305.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/195980/ft1_filtered_4FGL_J1158.5+4824_daily_bin305.fits.....................!
real 47.83
user 46.28
sys 1.34

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/195980/ft1_filtered_4FGL_J1158.5+4824_daily_bin305.fits', '/scratch/kocevski/195980/ft2_4FGL_J1158.5+4824_daily_bin305.fits', expMap='/scratch/kocevski/195980/expmap_318384001_318643201_4FGL_J1158.5+4824_daily_bin305.fits', expCube='/scratch/kocevski/195980/ltcube_318384001_318643201_4FGL_J1158.5+4824_daily_bin305.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/195980/Model_4FGL_J1158.5+4824_daily_bin305.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1158.5+4824'

4FGL J1158.5+4824
   Spectrum: PowerLaw
349    Prefactor:  5.005e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
350        Index:  2.443e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
351        Scale:  9.466e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/195980/ft1_filtered_4FGL_J1158.5+4824_daily_bin305.fits
Spacecraft file(s): /scratch/kocevski/195980/ft2_4FGL_J1158.5+4824_daily_bin305.fits
Exposure map: /scratch/kocevski/195980/expmap_318384001_318643201_4FGL_J1158.5+4824_daily_bin305.fits
Exposure cube: /scratch/kocevski/195980/ltcube_318384001_318643201_4FGL_J1158.5+4824_daily_bin305.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/195980/Model_4FGL_J1158.5+4824_daily_bin305.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) = 5404.77910561

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10010E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10038E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10022E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    49.137       1.0000         .10000E-03   10000.    
     5 'Prefactor '    146.73       1.0000         .10000E-03   10000.    
     6 'norm      '    28.790       1.0000         .10000E-03   10000.    
     7 'Prefactor '    4.1424       1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10013E-03   1.0000         .10000E-03   10000.    
     9 'norm      '    .10087E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    10.709       1.0000         .10000E-03   10000.    
    11 'norm      '    .13425E-03   1.0000         .10000E-03   10000.    
    12 'norm      '    9.8600       1.0000         .10000E-03   10000.    
    13 'Prefactor '    .15913E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    63.002       1.0000         .10000E-03   10000.    
    15 'norm      '    .12220E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    27.404       1.0000         .10000E-03   10000.    
    17 'norm      '    1.7163       1.0000         .10000E-03   10000.    
    18 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    2.5852       1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10208E-03   1.0000         .10000E-03   10000.    
    22 'norm      '    2.6002       1.0000         .10000E-03   10000.    
    23 'Prefactor '    23.518       1.0000         .10000E-03   10000.    
    24 'Normalizat'    1.0414       1.0000         .10000E-01   10.000    
    25 'Prefactor '    .82590       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6830E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   5404.774     FROM MIGRAD    STATUS=CONVERGED    590 CALLS     2935 TOTAL
                     EDM=   .18E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .6%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    77.641       -.59630E-04** at limit **
   2  Prefactor     .10000E-03    65.100        .13071E-04** at limit **
   3  Prefactor     .10000E-03    56.061        .47421E-04** at limit **
   4  Prefactor     49.139        67.128        .15490E-05    .19481E-04
   5  Prefactor     146.76        94.627        .26795E-04    .85719E-05
   6  norm          28.779        36.610       -.11493E-04   -.38440E-06
   7  Prefactor     4.1418        6.5182        .79724E-06   -.20266E-03
   8  Prefactor     .10000E-03    15.094        .10295E-04** at limit **
   9  norm          .10000E-03    1.2945        .24455E-06** at limit **
  10  Prefactor     10.691        27.199       -.11963E-04   -.32772E-03
  11  norm          .10000E-03    .55304        .91053E-06** at limit **
  12  norm          9.8597        6.9546        .21153E-06   -.19266E-04
  13  Prefactor     .10000E-03    2.1944       -.52017E-07** at limit **
  14  Prefactor     62.998        49.238       -.26630E-05   -.25176E-03
  15  norm          .10007E-03    4.8864       -.28220E-05** at limit **
  16  Prefactor     27.404        21.367        .31583E-06    .16820E-05
  17  norm          1.7161        2.6141       -.67288E-07   -.50188E-03
  18  norm          .10000E-03    2.3587        .35873E-07** at limit **
  19  Prefactor     .10000E-03    9.9327        .67351E-06** at limit **
  20  Prefactor     2.5854        4.0683       -.13602E-07   -.18439E-03
  21  Prefactor     .10000E-03    29.740       -.13572E-04** at limit **
  22  norm          2.6003        1.6489        .16803E-07    .16236E-03
  23  Prefactor     23.533        39.710        .17251E-04    .44552E-05
  24  Normalizat    1.0414        .16822       -.92911E-06   -.89780E-06
  25  Prefactor     .82578        .19583        .11393E-06   -.74237E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 49.139
  Prefactor  = 146.763
  norm       = 28.7786
  Prefactor  = 4.14185
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 10.6909
  norm       = 0.000100002
  norm       = 9.85974
  Prefactor  = 0.0001
  Prefactor  = 62.9976
  norm       = 0.000100069
  Prefactor  = 27.4041
  norm       = 1.71607
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 2.58536
  Prefactor  = 0.0001
  norm       = 2.60028
  Prefactor  = 23.5331
  Normalizat = 1.04144
  Prefactor  = 0.825778
 **********
 **   18 **HESSE 
 **********

 FCN=   5404.774     FROM HESSE     STATUS=OK           429 CALLS     3364 TOTAL
                     EDM=   .70E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    77.551        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     .10000E-03    65.093        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10000E-03    55.912        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     49.139        67.543        .57207E-04   -1.4305    
   5  Prefactor     146.76        94.537        .16634E-03   -1.3279    
   6  norm          28.779        36.598        .74668E-04   -1.4635    
   7  Prefactor     4.1418        6.5089        .19805E-03   -1.5301    
   8  Prefactor     .10000E-03    15.097        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  norm          .10000E-03    2.2604        .16208E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     10.691        26.045        .12243E-03   -1.5054    
  11  norm          .10000E-03    2.6444        .97887E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  norm          9.8597        6.9557        .12761E-03   -1.5080    
  13  Prefactor     .10000E-03    6.0083        .18894E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     62.998        48.574        .50556E-04   -1.4119    
  15  norm          .10007E-03    13.512        .31332E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     27.404        19.404        .76528E-04   -1.4661    
  17  norm          1.7161        2.6020        .13573E-03   -1.5446    
  18  norm          .10000E-03    2.3678        .11025E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10000E-03    10.010        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     2.5854        4.0517        .18097E-03   -1.5386    
  21  Prefactor     .10000E-03    30.306        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  norm          2.6003        1.6528        .73246E-04   -1.5385    
  23  Prefactor     23.533        39.683        .82597E-04   -1.4737    
  24  Normalizat    1.0414        .19769        .21017E-03   -.91655    
  25  Prefactor     .82578        .22980        .28860E-03   -.98785    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 7.02108e-09
Minuit parameter uncertainties:
  1  0.000101375
  2  1.86857e-05
  3  1.83301e-05
  4  67.6484
  5  94.6343
  6  36.6269
  7  6.50999
  8  1.94137e-06
  9  4.12686e-05
  10  26.073
  11  0.000141754
  12  6.95624
  13  4.96052e-06
  14  48.6042
  15  0.00193464
  16  19.4083
  17  2.60221
  18  1.67592e-06
  19  5.75564e-06
  20  4.05213
  21  0.000140829
  22  1.65279
  23  39.7273
  24  0.19783
  25  0.230065
Done.

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

Extracting fit parameters...

4FGL J1158.5+4824
   Spectrum: PowerLaw
349    Prefactor:  2.740e+01  1.941e+01  1.000e-04  1.000e+04 ( 1.000e-13)
350        Index:  2.443e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
351        Scale:  9.466e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
680    Prefactor:  8.258e-01  2.301e-01  0.000e+00  1.000e+01 ( 1.000e+00)
681        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
682        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
679   Normalization:  1.041e+00  1.978e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 3.26
Ra Dec: 179.637 48.416
Photon Index (Fixed Index): 2.44 +/- 0.00
Photon Flux (Fixed Index): 4.61e-08 +/- 3.26e-08
Energy Flux (Fixed Index): 1.43e-05 +/- 1.01e-05

TS (Fixed Index): 3.26
Ra Dec: 179.637 48.416
Photon Flux Upper Limit: 1.16e-07 ph cm-2 s-1
Energy Flux Upper Limit: 8.95e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/195980/likelihoodResults_318384001_318643201_4FGL_J1158.5+4824_daily_bin305.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) = 5404.27761622
delta logL = 0.496284818573

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 5404.27315136
delta logL = 0.500749682435

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    11.368       1.0000         .10000E-03   10000.    
     2 'Index     '    3.2128       1.0000          .0000       10.000    
     3 'Normalizat'    1.0082       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .85338       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6830E+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=   5404.273     FROM MIGRAD    STATUS=CONVERGED     85 CALLS      288 TOTAL
                     EDM=   .40E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     11.365        22.461        .11882E-03   -.43754E-03
   2  Index         3.2130        1.1543        .45160E-02   -.17351E-03
   3  Normalizat    1.0082        .18880        .21310E-03   -.13152E-03
   4  Prefactor     .85338        .23078        .28437E-03   -.17115E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 11.3646
  Index      = 3.21301
  Normalizat = 1.00824
  Prefactor  = 0.853378
 **********
 **   18 **HESSE 
 **********

 FCN=   5404.273     FROM HESSE     STATUS=OK            25 CALLS      313 TOTAL
                     EDM=   .40E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     11.365        16.469        .47528E-05   -1.5034    
   2  Index         3.2130        .84953        .18064E-03   -.36548    
   3  Normalizat    1.0082        .18801        .42620E-04   -.92755    
   4  Prefactor     .85338        .22985        .11375E-04   -.97790    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 4.0136e-10
Minuit parameter uncertainties:
  1  16.4759
  2  0.854285
  3  0.18813
  4  0.230112
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/195980': 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) = 5404.27315133
delta logL = 0.500749705847

Extracting fit parameters...

4FGL J1158.5+4824
   Spectrum: PowerLaw
349    Prefactor:  1.136e+01  1.648e+01  1.000e-04  1.000e+04 ( 1.000e-13)
350        Index:  3.213e+00  8.543e-01  0.000e+00  1.000e+01 (-1.000e+00)
351        Scale:  9.466e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
680    Prefactor:  8.534e-01  2.301e-01  0.000e+00  1.000e+01 ( 1.000e+00)
681        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
682        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
679   Normalization:  1.008e+00  1.881e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 4.29
Ra Dec: 179.637 48.416
Photon Index (Free Index): 3.21 +/- 0.85
Photon Flux (Free Index): 7.04e-08 +/- 4.47e-08
Energy Flux (Free Index): 1.28e-05 +/- 7.80e-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/195980/cmap_HighResolution_318384001_318643201_4FGL_J1158.5+4824_daily_bin305.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='8.95e-03', comment='SUCCESS', photon_flux='4.61e-08', energy_flux2='1.28e-05', photon_flux_error='3.26e-08', dlogl='5.01e-01', energy_flux='1.43e-05', photon_flux2='7.04e-08', job_status='DONE', time_completed='2021-09-04 17:43:30.043077', photon_index_error2='0.85', photon_index2='3.21', ts='3.26', fit_tolerance='1e-08', GAL='0.83', photon_index_error='0.00', photon_flux_upper_limit='1.16e-07', energy_flux_error2='7.80e-06', EG='1.04', time_epoch_completed='1630802610.04', return_code='0', job_id='195980', GAL2='0.85', EG2='1.01', return_code2='0', energy_flux_error='1.01e-05', photon_flux_error2='4.47e-08', ts2='4.29', photon_index='2.44' WHERE bin_id='305' AND source_name='4FGL J1158.5+4824' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sat Sep  4 17:43:30 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0055>
Subject: Job 195980: <4FGL_J1158.5+4824_daily_bin305> in cluster <slac> Done

Job <4FGL_J1158.5+4824_daily_bin305> was submitted from host <rhel6-64p> by user <kocevski> in cluster <slac> at Sat Sep  4 17:31:06 2021
Job was executed on host(s) <bullet0055>, in queue <medium>, as user <kocevski> in cluster <slac> at Sat Sep  4 17:31:08 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sat Sep  4 17:31:08 2021
Terminated at Sat Sep  4 17:43:33 2021
Results reported at Sat Sep  4 17:43:33 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1158.5+4824_daily_bin305 179.637 48.4161 318384001 318643201 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1158.5+4824 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   727.00 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             300.61 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   742 sec.
    Turnaround time :                            747 sec.

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

