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


Performing analysis on: 4FGL_J1158.5+4824_daily_bin364
RA = 179.637, Dec = 48.4161
tmin = 333676801, tmax = 333936001
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='196078', job_status='RUN', time_executed='2021-09-04 17:31:29.321931', time_epoch_executed='1630801889.32' WHERE source_name='4FGL J1158.5+4824' and cadence='daily' and bin_id='364'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/196078

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/196078/ft1_4FGL_J1158.5+4824_daily_bin364.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/196078/ft2_4FGL_J1158.5+4824_daily_bin364.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/196078/ft1_4FGL_J1158.5+4824_daily_bin364.fits outfile=/scratch/kocevski/196078/ft1_filteredMKT_4FGL_J1158.5+4824_daily_bin364.fits ra=179.637 dec=48.4161 rad=12.0 tmin=333676801.0 tmax=333936001.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.91
user 3.63
sys 0.21

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/196078/ft2_4FGL_J1158.5+4824_daily_bin364.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/196078/ft1_filteredMKT_4FGL_J1158.5+4824_daily_bin364.fits evtable="EVENTS" outfile="/scratch/kocevski/196078/ft1_filtered_4FGL_J1158.5+4824_daily_bin364.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.14

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/196078/ft1_filtered_4FGL_J1158.5+4824_daily_bin364.fits" evtable="EVENTS" scfile=/scratch/kocevski/196078/ft2_4FGL_J1158.5+4824_daily_bin364.fits sctable="SC_DATA" outfile=/scratch/kocevski/196078/ltcube_333676801_333936001_4FGL_J1158.5+4824_daily_bin364.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/196078/ft2_4FGL_J1158.5+4824_daily_bin364.fits
.....................!
real 11.72
user 11.34
sys 0.31

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/196078/ft1_filtered_4FGL_J1158.5+4824_daily_bin364.fits evtable="EVENTS" scfile=/scratch/kocevski/196078/ft2_4FGL_J1158.5+4824_daily_bin364.fits sctable="SC_DATA" expcube=/scratch/kocevski/196078/ltcube_333676801_333936001_4FGL_J1158.5+4824_daily_bin364.fits outfile=/scratch/kocevski/196078/expmap_333676801_333936001_4FGL_J1158.5+4824_daily_bin364.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/196078/ltcube_333676801_333936001_4FGL_J1158.5+4824_daily_bin364.fits
.....................!
real 189.42
user 185.20
sys 3.85

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/196078/ft1_filtered_4FGL_J1158.5+4824_daily_bin364.fits scfile=/scratch/kocevski/196078/ft2_4FGL_J1158.5+4824_daily_bin364.fits outfile=/scratch/kocevski/196078/cmap_333676801_333936001_4FGL_J1158.5+4824_daily_bin364.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.55
user 0.35
sys 0.16

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/196078/ft1_filtered_4FGL_J1158.5+4824_daily_bin364.fits scfile=/scratch/kocevski/196078/ft2_4FGL_J1158.5+4824_daily_bin364.fits outfile=/scratch/kocevski/196078/cmap_HighResolution_333676801_333936001_4FGL_J1158.5+4824_daily_bin364.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.55
user 0.38
sys 0.15

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

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/196078/ft1_filtered_4FGL_J1158.5+4824_daily_bin364.fits', '/scratch/kocevski/196078/ft2_4FGL_J1158.5+4824_daily_bin364.fits', expMap='/scratch/kocevski/196078/expmap_333676801_333936001_4FGL_J1158.5+4824_daily_bin364.fits', expCube='/scratch/kocevski/196078/ltcube_333676801_333936001_4FGL_J1158.5+4824_daily_bin364.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/196078/Model_4FGL_J1158.5+4824_daily_bin364.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/196078/ft1_filtered_4FGL_J1158.5+4824_daily_bin364.fits
Spacecraft file(s): /scratch/kocevski/196078/ft2_4FGL_J1158.5+4824_daily_bin364.fits
Exposure map: /scratch/kocevski/196078/expmap_333676801_333936001_4FGL_J1158.5+4824_daily_bin364.fits
Exposure cube: /scratch/kocevski/196078/ltcube_333676801_333936001_4FGL_J1158.5+4824_daily_bin364.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/196078/Model_4FGL_J1158.5+4824_daily_bin364.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) = 7099.99898251

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10118E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .64094E-03   1.0000         .10000E-03   10000.    
     6 'norm      '    53.632       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    7.7841       1.0000         .10000E-03   10000.    
     9 'norm      '    4.3898       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    11 'norm      '    11.398       1.0000         .10000E-03   10000.    
    12 'norm      '    12.964       1.0000         .10000E-03   10000.    
    13 'Prefactor '    12.033       1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    15 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    32.000       1.0000         .10000E-03   10000.    
    17 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
    18 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10210E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    22 'norm      '    5.5757       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    24 'Normalizat'    .98591       1.0000         .10000E-01   10.000    
    25 'Prefactor '    1.1135       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=   7099.843     FROM MIGRAD    STATUS=CONVERGED    554 CALLS     2416 TOTAL
                     EDM=   .97E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .5%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    30.173        .11013E-04** at limit **
   2  Prefactor     .10000E-03    40.816        .71336E-05** at limit **
   3  Prefactor     .10000E-03    27.719        .28179E-05** at limit **
   4  Prefactor     .10000E-03    45.805       -.17559E-04** at limit **
   5  Prefactor     .10012E-03    468.96       -.32283E-03** at limit **
   6  norm          53.629        47.949       -.32197E-05    .16021E-03
   7  Prefactor     .10000E-03    1.9640        .10747E-06** at limit **
   8  Prefactor     7.7836        22.104       -.75337E-06   -.16921E-04
   9  norm          4.3895        2.7131       -.38902E-06   -.25811E-02
  10  Prefactor     .10000E-03    15.951        .85661E-05** at limit **
  11  norm          11.398        1.8673       -.47955E-07   -.41320E-03
  12  norm          12.965        10.406       -.50224E-07   -.31990E-04
  13  Prefactor     12.033        4.4693       -.45692E-06    .10842E-03
  14  Prefactor     .10000E-03    39.659        .10780E-04** at limit **
  15  norm          .10000E-03    1.2996        .21431E-06** at limit **
  16  Prefactor     32.003        21.310        .84696E-06    .36812E-04
  17  norm          .10000E-03    .96432        .56502E-07** at limit **
  18  norm          .10000E-03    2.4107        .10059E-06** at limit **
  19  Prefactor     .10000E-03    25.235       -.52025E-05** at limit **
  20  Prefactor     .10000E-03    1.5634        .15311E-06** at limit **
  21  Prefactor     .10000E-03    13.997       -.36540E-05** at limit **
  22  norm          5.5762        2.5872        .44447E-06   -.41780E-04
  23  Prefactor     .10000E-03    22.420       -.13337E-04** at limit **
  24  Normalizat    .98603        .15828        .65151E-07    .59541E-03
  25  Prefactor     1.1133        .19798       -.20767E-06    .51320E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.000100116
  norm       = 53.6293
  Prefactor  = 0.0001
  Prefactor  = 7.78358
  norm       = 4.38946
  Prefactor  = 0.0001
  norm       = 11.398
  norm       = 12.9651
  Prefactor  = 12.0329
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 32.0027
  norm       = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 5.57618
  Prefactor  = 0.0001
  Normalizat = 0.986025
  Prefactor  = 1.11327
 **********
 **   18 **HESSE 
 **********

 FCN=   7099.843     FROM HESSE     STATUS=OK           413 CALLS     2829 TOTAL
                     EDM=   .19E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    30.188        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     .10000E-03    40.820        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10000E-03    27.722        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    45.925        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10012E-03    468.10        .21029E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  norm          53.629        47.941        .27384E-03   -1.4242    
   7  Prefactor     .10000E-03    1.9727        .11529E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     7.7836        22.099        .14372E-03   -1.5150    
   9  norm          4.3895        2.7167        .52853E-03   -1.5289    
  10  Prefactor     .10000E-03    15.965        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  norm          11.398        1.8684        .44430E-04   -1.5033    
  12  norm          12.965        10.413        .11125E-03   -1.4988    
  13  Prefactor     12.033        4.4751        .97864E-04   -1.5014    
  14  Prefactor     .10000E-03    39.711        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  norm          .10000E-03    1.3010        .93806E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     32.003        21.323        .70832E-04   -1.4576    
  17  norm          .10000E-03    .99626        .16141E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  norm          .10000E-03    2.4198        .12775E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10000E-03    25.531        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .10000E-03    1.5669        .10289E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .10000E-03    14.046        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  norm          5.5762        2.5862        .89279E-04   -1.5236    
  23  Prefactor     .10000E-03    22.443        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Normalizat    .98603        .18571        .24907E-03   -.93500    
  25  Prefactor     1.1133        .23209        .29717E-03   -.89044    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.94173e-09
Minuit parameter uncertainties:
  1  1.38976e-05
  2  4.17415e-06
  3  3.76644e-06
  4  6.45714e-05
  5  0.0148815
  6  47.9756
  7  1.47327e-06
  8  22.1225
  9  2.71678
  10  9.18544e-06
  11  1.86844
  12  10.4149
  13  4.47522
  14  8.45295e-06
  15  2.62555e-07
  16  21.3284
  17  6.66718e-07
  18  1.81759e-06
  19  3.56009e-05
  20  4.15774e-07
  21  3.35386e-06
  22  2.5863
  23  4.34162e-06
  24  0.185836
  25  0.2323
Done.

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

Extracting fit parameters...

4FGL J1158.5+4824
   Spectrum: PowerLaw
349    Prefactor:  3.200e+01  2.133e+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:  1.113e+00  2.323e-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:  9.860e-01  1.858e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 5.97
Ra Dec: 179.637 48.416
Photon Index (Fixed Index): 2.44 +/- 0.00
Photon Flux (Fixed Index): 5.38e-08 +/- 3.58e-08
Energy Flux (Fixed Index): 1.67e-05 +/- 1.11e-05

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) = 7099.55219401
delta logL = 0.290992464125

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 7099.55174479
delta logL = 0.291441682123

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    40.881       1.0000         .10000E-03   10000.    
     2 'Index     '    2.0600       1.0000          .0000       10.000    
     3 'Normalizat'    1.0019       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.1009       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=   7099.552     FROM MIGRAD    STATUS=CONVERGED     89 CALLS      295 TOTAL
                     EDM=   .21E-10    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     40.861        26.913        .31347E-03   -.63831E-05
   2  Index         2.0595        .47453        .74430E-02    .53628E-05
   3  Normalizat    1.0019        .18353        .24742E-03   -.39378E-04
   4  Prefactor     1.1010        .23096        .29862E-03    .29581E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 40.8606
  Index      = 2.05945
  Normalizat = 1.0019
  Prefactor  = 1.101
 **********
 **   18 **HESSE 
 **********

 FCN=   7099.552     FROM HESSE     STATUS=OK            25 CALLS      320 TOTAL
                     EDM=   .20E-10    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     40.861        26.751        .12539E-04   -1.4429    
   2  Index         2.0595        .47156        .29772E-03   -.62872    
   3  Normalizat    1.0019        .18367        .98968E-05   -.92967    
   4  Prefactor     1.1010        .23117        .11945E-04   -.89435    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.01324e-11
Minuit parameter uncertainties:
  1  26.7591
  2  0.47263
  3  0.183786
  4  0.23138
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/196078': 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) = 7099.55174369
delta logL = 0.291442783354

Extracting fit parameters...

4FGL J1158.5+4824
   Spectrum: PowerLaw
349    Prefactor:  4.086e+01  2.676e+01  1.000e-04  1.000e+04 ( 1.000e-13)
350        Index:  2.059e+00  4.726e-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:  1.101e+00  2.314e-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.002e+00  1.838e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 6.62
Ra Dec: 179.637 48.416
Photon Index (Free Index): 2.06 +/- 0.47
Photon Flux (Free Index): 3.95e-08 +/- 3.21e-08
Energy Flux (Free Index): 2.37e-05 +/- 2.05e-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/196078/cmap_HighResolution_333676801_333936001_4FGL_J1158.5+4824_daily_bin364.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET comment='SUCCESS', photon_flux='5.38e-08', energy_flux2='2.37e-05', photon_flux_error='3.58e-08', dlogl='2.91e-01', energy_flux='1.67e-05', photon_flux2='3.95e-08', job_status='DONE', time_completed='2021-09-04 17:43:09.027259', photon_index_error2='0.47', photon_index2='2.06', ts='5.97', fit_tolerance='1e-08', GAL='1.11', photon_index_error='0.00', energy_flux_error2='2.05e-05', EG='0.99', time_epoch_completed='1630802589.03', return_code='0', job_id='196078', GAL2='1.10', EG2='1.00', return_code2='0', energy_flux_error='1.11e-05', photon_flux_error2='3.21e-08', ts2='6.62', photon_index='2.44' WHERE bin_id='364' AND source_name='4FGL J1158.5+4824' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sat Sep  4 17:43:09 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0227>
Subject: Job 196078: <4FGL_J1158.5+4824_daily_bin364> in cluster <slac> Done

Job <4FGL_J1158.5+4824_daily_bin364> was submitted from host <rhel6-64p> by user <kocevski> in cluster <slac> at Sat Sep  4 17:31:13 2021
Job was executed on host(s) <bullet0227>, in queue <medium>, as user <kocevski> in cluster <slac> at Sat Sep  4 17:31:16 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:16 2021
Terminated at Sat Sep  4 17:43:09 2021
Results reported at Sat Sep  4 17:43:09 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1158.5+4824_daily_bin364 179.637 48.4161 333676801 333936001 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 :                                   697.00 sec.
    Max Memory :                                 1258 MB
    Average Memory :                             359.00 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   713 sec.
    Turnaround time :                            716 sec.

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

