/sdf/group/fermi/u/kocevski/software/conda/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)

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 make4FGLDR3xml version 01r09.
The default diffuse model files and names are for P8R3, 4FGL DRs, and the default fermitools directory locations.

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

/sdf/group/fermi/u/kocevski/software/conda/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 = 17422
number of fields = 31
RA_SUN column already exists. File will not be modified.
Done.


Performing analysis on: 4FGL_J1558.8+5625_weekly_bin802
RA = 239.718, Dec = 56.4268
tmin = 724032001, tmax = 724636801
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='36607008', job_status='RUN', time_executed='2023-12-19 01:00:50.594902', time_epoch_executed='1702976450.59' WHERE source_name='4FGL J1558.8+5625' and cadence='weekly' and bin_id='802'

Database successfully updated.
Done.

Creating custom output directory:
/lscratch/kocevski/36607008

Creating custom pfile directory:
/lscratch/kocevski/36607008/pfiles/

Retrieving the FT1 file...

Issuing command:
datacat find --group FT1 --filter 'nMetStop>=724032001.0 && nMetStart<724636801.0' /Data/Flight/Reprocess/P305

Issuing command:
datacat find --group FT1 --filter 'nMetStart>564945418 && nMetStop>=724032001.0 && nMetStart<724636801.0' /Data/Flight/Level1/LPA

Retrieving 107 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/lscratch/kocevski/36607008/ft1_4FGL_J1558.8+5625_weekly_bin802.fits


Retrieving the FT1 file...

Issuing command:
datacat find --group FT2 --filter 'nMetStop>=724032001.0 && nMetStart<724636801.0' /Data/Flight/Level1/LPA

Retrieving 107 files...
Done.


Merging files...

Merged file saved to:
/lscratch/kocevski/36607008/ft2_4FGL_J1558.8+5625_weekly_bin802.fits


Selecting the photons:
time -p gtselect infile=/lscratch/kocevski/36607008/ft1_4FGL_J1558.8+5625_weekly_bin802.fits outfile=/lscratch/kocevski/36607008/ft1_filteredMKT_4FGL_J1558.8+5625_weekly_bin802.fits ra=239.718 dec=56.4268 rad=12.0 tmin=724032001.0 tmax=724636801.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.85
user 4.19
sys 0.31

Adding sun position to ft2 file:
/sdf/group/fermi/g/LCRepository/Repository/bin/sunpos /lscratch/kocevski/36607008/ft2_4FGL_J1558.8+5625_weekly_bin802.fits

Selecting the good time intervals:
time -p gtmktime scfile=/lscratch/kocevski/36607008/ft2_4FGL_J1558.8+5625_weekly_bin802.fits sctable="SC_DATA" filter="IN_SAA!=T && LIVETIME>0 && gtifilter('/sdf/group/fermi/g/LCRepository/Likelihood/GTIs/nogrb.gti',(START+STOP)/2) && (angsep(RA_SUN,DEC_SUN,RA_ZENITH,DEC_ZENITH)>115 || gtifilter('/sdf/group/fermi/g/LCRepository/Likelihood/GTIs/nosolarflares.gti',(START+STOP)/2))" roicut=no evfile=/lscratch/kocevski/36607008/ft1_filteredMKT_4FGL_J1558.8+5625_weekly_bin802.fits evtable="EVENTS" outfile="/lscratch/kocevski/36607008/ft1_filtered_4FGL_J1558.8+5625_weekly_bin802.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('/sdf/group/fermi/g/LCRepository/Likelihood/GTIs/nogrb.gti',(START+STOP)/2) && (angsep(RA_SUN,DEC_SUN,RA_ZENITH,DEC_ZENITH)>115 || gtifilter('/sdf/group/fermi/g/LCRepository/Likelihood/GTIs/nosolarflares.gti',(START+STOP)/2))
real 0.45
user 0.22
sys 0.17

Number of photons that the gtmktime cut: 1493

Generating the livetime cube:
time -p gtltcube evfile="/lscratch/kocevski/36607008/ft1_filtered_4FGL_J1558.8+5625_weekly_bin802.fits" evtable="EVENTS" scfile=/lscratch/kocevski/36607008/ft2_4FGL_J1558.8+5625_weekly_bin802.fits sctable="SC_DATA" outfile=/lscratch/kocevski/36607008/ltcube_724032001_724636801_4FGL_J1558.8+5625_weekly_bin802.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 /lscratch/kocevski/36607008/ft2_4FGL_J1558.8+5625_weekly_bin802.fits
.....................!
real 25.03
user 24.54
sys 0.27

Generating the exposure map:
time -p gtexpmap evfile=/lscratch/kocevski/36607008/ft1_filtered_4FGL_J1558.8+5625_weekly_bin802.fits evtable="EVENTS" scfile=/lscratch/kocevski/36607008/ft2_4FGL_J1558.8+5625_weekly_bin802.fits sctable="SC_DATA" expcube=/lscratch/kocevski/36607008/ltcube_724032001_724636801_4FGL_J1558.8+5625_weekly_bin802.fits outfile=/lscratch/kocevski/36607008/expmap_724032001_724636801_4FGL_J1558.8+5625_weekly_bin802.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 /lscratch/kocevski/36607008/ltcube_724032001_724636801_4FGL_J1558.8+5625_weekly_bin802.fits
.....................!
real 67.96
user 63.82
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 220 point sources and 0 extended sources

Setting source of interest to:
4FGL J1558.8+5625 @ 239.718 56.4268

Creating the counts map:
time -p gtbin evfile=/lscratch/kocevski/36607008/ft1_filtered_4FGL_J1558.8+5625_weekly_bin802.fits scfile=/lscratch/kocevski/36607008/ft2_4FGL_J1558.8+5625_weekly_bin802.fits outfile=/lscratch/kocevski/36607008/cmap_724032001_724636801_4FGL_J1558.8+5625_weekly_bin802.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=239.718 yref=56.4268 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.39
user 0.23
sys 0.13

Creating the high resolution counts map:
time -p gtbin evfile=/lscratch/kocevski/36607008/ft1_filtered_4FGL_J1558.8+5625_weekly_bin802.fits scfile=/lscratch/kocevski/36607008/ft2_4FGL_J1558.8+5625_weekly_bin802.fits outfile=/lscratch/kocevski/36607008/cmap_HighResolution_724032001_724636801_4FGL_J1558.8+5625_weekly_bin802.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=239.718 yref=56.4268 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.42
user 0.25
sys 0.14

Computing the diffuse response:
time -p gtdiffrsp evfile=/lscratch/kocevski/36607008/ft1_filtered_4FGL_J1558.8+5625_weekly_bin802.fits evtable="EVENTS" scfile=/lscratch/kocevski/36607008/ft2_4FGL_J1558.8+5625_weekly_bin802.fits sctable="SC_DATA" srcmdl=/lscratch/kocevski/36607008/Model_4FGL_J1558.8+5625_weekly_bin802.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...
/lscratch/kocevski/36607008/ft1_filtered_4FGL_J1558.8+5625_weekly_bin802.fits.....................!
real 45.42
user 44.00
sys 1.18

Creating the likelihood object...
obs = UnbinnedObs('/lscratch/kocevski/36607008/ft1_filtered_4FGL_J1558.8+5625_weekly_bin802.fits', '/lscratch/kocevski/36607008/ft2_4FGL_J1558.8+5625_weekly_bin802.fits', expMap='/lscratch/kocevski/36607008/expmap_724032001_724636801_4FGL_J1558.8+5625_weekly_bin802.fits', expCube='/lscratch/kocevski/36607008/ltcube_724032001_724636801_4FGL_J1558.8+5625_weekly_bin802.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/lscratch/kocevski/36607008/Model_4FGL_J1558.8+5625_weekly_bin802.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1558.8+5625'

4FGL J1558.8+5625
   Spectrum: PowerLaw
318    Prefactor:  3.885e+00  0.000e+00  0.000e+00  1.000e+06 ( 1.000e-13)
319        Index:  2.116e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
320        Scale:  1.645e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /lscratch/kocevski/36607008/ft1_filtered_4FGL_J1558.8+5625_weekly_bin802.fits
Spacecraft file(s): /lscratch/kocevski/36607008/ft2_4FGL_J1558.8+5625_weekly_bin802.fits
Exposure map: /lscratch/kocevski/36607008/expmap_724032001_724636801_4FGL_J1558.8+5625_weekly_bin802.fits
Exposure cube: /lscratch/kocevski/36607008/ltcube_724032001_724636801_4FGL_J1558.8+5625_weekly_bin802.fits
IRFs: P8R3_SOURCE_V2
Source model file: /lscratch/kocevski/36607008/Model_4FGL_J1558.8+5625_weekly_bin802.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) = 16132.4249608

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .11546E-07   1.0000          .0000       .10000E+07
     2 'Prefactor '    .32863E-07   1.0000          .0000       .10000E+07
     3 'norm      '    3.1822       1.0000          .0000       .10000E+07
     4 'Prefactor '    .73275E-08   1.0000          .0000       .10000E+07
     5 'Prefactor '    .49003E-03   1.0000          .0000       .10000E+07
     6 'Prefactor '    6.0240       1.0000          .0000       .10000E+07
     7 'Prefactor '    27.548       1.0000          .0000       .10000E+07
     8 'norm      '    2.6278       1.0000          .0000       .10000E+07
     9 'Prefactor '    .25349E-04   1.0000          .0000       .10000E+07
    10 'Prefactor '    3.8582       1.0000          .0000       .10000E+07
    11 'norm      '    .23370E-07   1.0000          .0000       .10000E+07
    12 'Prefactor '    1.3184       1.0000          .0000       .10000E+07
    13 'Prefactor '    6.1376       1.0000          .0000       .10000E+07
    14 'Prefactor '    .48110E-02   1.0000          .0000       .10000E+07
    15 'Prefactor '    19.628       1.0000          .0000       .10000E+07
    16 'Prefactor '    .72927       1.0000          .0000       .10000E+07
    17 'norm      '    30.028       1.0000          .0000       .10000E+07
    18 'Prefactor '    1.2121       1.0000          .0000       .10000E+07
    19 'Prefactor '    4.2336       1.0000          .0000       .10000E+07
    20 'norm      '    6.5595       1.0000          .0000       .10000E+07
    21 'Prefactor '    8.1126       1.0000          .0000       .10000E+07
    22 'Prefactor '    3.7936       1.0000          .0000       .10000E+07
    23 'Prefactor '    9.5692       1.0000          .0000       .10000E+07
    24 'Prefactor '    .87375E-07   1.0000          .0000       .10000E+07
    25 'Prefactor '    .18208E-07   1.0000          .0000       .10000E+07
    26 'Normalizat'    .90970       1.0000         .10000E-01   10.000    
    27 'Prefactor '    .94928       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .7040E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   16132.38     FROM MIGRAD    STATUS=CONVERGED    200 CALLS     2920 TOTAL
                     EDM=   .16E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.5%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor      .0000        5.4517       -.77162E-06** at limit **
   2  Prefactor     .31641E-08    11.261       -.83654E-06** at limit **
   3  norm          3.1822        1.0477        .13046E-07   -.34751E-02
   4  Prefactor      .0000        1.2053       -.46284E-07** at limit **
   5  Prefactor     .32363E-07    31.882        .10017E-05** at limit **
   6  Prefactor     6.0230        4.2549        .14046E-06    .50646E-03
   7  Prefactor     27.547        3.7412       -.14581E-06   -.20461E-01
   8  norm          2.6284        1.4352       -.47960E-07   -.19429E-02
   9  Prefactor     .37192E-08    164.06       -.27211E-06** at limit **
  10  Prefactor     3.8579        3.1208        .15969E-06    .75138E-03
  11  norm           .0000        1.8126        .34002E-07** at limit **
  12  Prefactor     1.3114        17.464       -.22899E-05   -.16694E-01
  13  Prefactor     6.1232        8.8413        .43627E-06   -.93161E-01
  14  Prefactor     .16437E-06    142.00        .39655E-05** at limit **
  15  Prefactor     19.610        12.494        .11197E-05   -.29407E-01
  16  Prefactor     .72858        1.9219        .80112E-07   -.88433E-03
  17  norm          30.034        7.9392        .45014E-06    .12808    
  18  Prefactor     1.2119        2.1471       -.13490E-06    .12758E-02
  19  Prefactor     4.2327        3.6473       -.10908E-06   -.16751E-02
  20  norm          6.5593        4.7046        .99349E-07   -.17015E-02
  21  Prefactor     8.1122        2.2493       -.72266E-07   -.13571E-02
  22  Prefactor     3.7930        5.0661       -.14303E-06   -.12461E-02
  23  Prefactor     9.5694        9.4721        .14202E-06   -.10082E-02
  24  Prefactor     .12046E-07    5.1314       -.11608E-05** at limit **
  25  Prefactor     .43299E-08    7.1906        .11741E-05** at limit **
  26  Normalizat    .90981        .12029        .12026E-05   -.23583E-03
  27  Prefactor     .94923        .12024        .32465E-05   -.21502E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0
  Prefactor  = 3.16414e-09
  norm       = 3.18218
  Prefactor  = 0
  Prefactor  = 3.2363e-08
  Prefactor  = 6.02304
  Prefactor  = 27.5473
  norm       = 2.62845
  Prefactor  = 3.71925e-09
  Prefactor  = 3.8579
  norm       = 0
  Prefactor  = 1.31136
  Prefactor  = 6.12316
  Prefactor  = 1.64369e-07
  Prefactor  = 19.6097
  Prefactor  = 0.728585
  norm       = 30.0337
  Prefactor  = 1.21195
  Prefactor  = 4.23273
  norm       = 6.5593
  Prefactor  = 8.11221
  Prefactor  = 3.79304
  Prefactor  = 9.56938
  Prefactor  = 1.20459e-08
  Prefactor  = 4.32987e-09
  Normalizat = 0.909812
  Prefactor  = 0.949234
 **********
 **   18 **HESSE 
 **********

 FCN=   16132.38     FROM HESSE     STATUS=OK           562 CALLS     3482 TOTAL
                     EDM=   .21E-05    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor      .0000        5.4541        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     .31641E-08    11.169        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm          3.1822        1.0509        .56782E-03   -1.5672    
   4  Prefactor      .0000        1.2087        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .32363E-07    2.2786        .63222E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     6.0230        4.2466        .40886E-03   -1.5659    
   7  Prefactor     27.547        16.734        .19056E-03   -1.5603    
   8  norm          2.6284        1.4344        .62883E-03   -1.5676    
   9  Prefactor     .37192E-08    169.05        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     3.8579        3.1258        .51351E-03   -1.5669    
  11  norm           .0000        1.8101        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     1.3114        43.615        .95838E-03   -1.5685    
  13  Prefactor     6.1232        18.488        .40500E-03   -1.5658    
  14  Prefactor     .16437E-06    2.5763        .55722E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     19.610        15.617        .22579E-03   -1.5619    
  16  Prefactor     .72858        1.9568        .58364E-03   -1.5691    
  17  norm          30.034        13.206        .18252E-03   -1.5598    
  18  Prefactor     1.2119        2.1780        .10268E-02   -1.5686    
  19  Prefactor     4.2327        3.6645        .48949E-03   -1.5667    
  20  norm          6.5593        4.7074        .39160E-03   -1.5657    
  21  Prefactor     8.1122        2.2602        .35176E-03   -1.5651    
  22  Prefactor     3.7930        5.0764        .51803E-03   -1.5669    
  23  Prefactor     9.5694        9.5060        .32371E-03   -1.5646    
  24  Prefactor     .12046E-07    5.1216        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     .43299E-08    7.1712        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  Normalizat    .90981        .10274        .45025E-01   -.96116    
  27  Prefactor     .94923        .10251        .45630E-01   -.94441    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.14619e-06
Minuit parameter uncertainties:
  1  1.28227e-05
  2  0.000377588
  3  1.05093
  4  1.26803e-06
  5  0.000543072
  6  4.24656
  7  16.7341
  8  1.43442
  9  0.0015855
  10  3.12577
  11  2.46021e-06
  12  15.1257
  13  18.488
  14  0.00130151
  15  15.617
  16  1.95684
  17  13.2061
  18  2.17798
  19  3.66453
  20  4.70735
  21  2.26023
  22  5.07638
  23  9.50597
  24  0.000496708
  25  0.000352847
  26  0.10276
  27  0.102534
Done.

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

Extracting fit parameters...

4FGL J1558.8+5625
   Spectrum: PowerLaw
318    Prefactor:  3.858e+00  3.126e+00  0.000e+00  1.000e+06 ( 1.000e-13)
319        Index:  2.116e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
320        Scale:  1.645e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
701    Prefactor:  9.492e-01  1.025e-01  0.000e+00  1.000e+01 ( 1.000e+00)
702        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
703        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
700   Normalization:  9.098e-01  1.028e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 7.87
Ra Dec: 239.718 56.427
Photon Index (Fixed Index): 2.12 +/- 0.00
Photon Flux (Fixed Index): 1.29e-08 +/- 1.05e-08
Energy Flux (Fixed Index): 6.87e-06 +/- 5.57e-06

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) = 16131.858618
delta logL = 0.522866364247

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 16131.727292
delta logL = 0.654192366532

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    1.6816       1.0000          .0000       .10000E+07
     2 'Index     '    1.0824       1.0000          .0000       10.000    
     3 'Normalizat'    .92232       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .94492       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .7040E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   16131.73     FROM MIGRAD    STATUS=CONVERGED     53 CALLS      243 TOTAL
                     EDM=   .66E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     1.6839        1.7054        .81198E-03   -.92064E-02
   2  Index         1.0825        .45028        .38299       -.13791E-03
   3  Normalizat    .92232        .97480E-01    .45186E-01    .30737E-04
   4  Prefactor     .94491        .10123        .45575E-01    .27984E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 1.68395
  Index      = 1.08254
  Normalizat = 0.922315
  Prefactor  = 0.944906
 **********
 **   18 **HESSE 
 **********

 FCN=   16131.73     FROM HESSE     STATUS=OK            33 CALLS      276 TOTAL
                     EDM=   .17E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     1.6839        2.6120        .15859E-04   -1.5682    
   2  Index         1.0825        .71605        .17519E-01   -.90027    
   3  Normalizat    .92232        .11428        .23343E-03   -.95680    
   4  Prefactor     .94491        .11880        .23871E-03   -.94589    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.66886e-08
Minuit parameter uncertainties:
  1  2.61204
  2  0.722547
  3  0.114313
  4  0.118831
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) = 16131.7272913
delta logL = 0.654193110657

Extracting fit parameters...

4FGL J1558.8+5625
   Spectrum: PowerLaw
318    Prefactor:  1.684e+00  2.612e+00  0.000e+00  1.000e+06 ( 1.000e-13)
319        Index:  1.083e+00  7.225e-01  0.000e+00  1.000e+01 (-1.000e+00)
320        Scale:  1.645e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
701    Prefactor:  9.449e-01  1.188e-01  0.000e+00  1.000e+01 ( 1.000e+00)
702        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
703        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
700   Normalization:  9.223e-01  1.143e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 9.16
Ra Dec: 239.718 56.427
Photon Index (Free Index): 1.08 +/- 0.72
Photon Flux (Free Index): 1.84e-09 +/- 2.53e-09
Energy Flux (Free Index): 2.15e-05 +/- 3.04e-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 /lscratch/kocevski/36607008/cmap_HighResolution_724032001_724636801_4FGL_J1558.8+5625_weekly_bin802.png

Cleaning up...

** Nuclear option initiated! **

Updating database...

UPDATE lightcurve_data_v2 SET comment='SUCCESS', photon_flux='1.29e-08', energy_flux2='2.15e-05', photon_flux_error='1.05e-08', dlogl='6.54e-01', energy_flux='6.87e-06', photon_flux2='1.84e-09', job_status='DONE', time_completed='2023-12-19 01:13:08.685971', photon_index_error2='0.72', photon_index2='1.08', ts='7.87', fit_tolerance='1e-08', GAL='0.95', photon_index_error='0.00', energy_flux_error2='3.04e-05', EG='0.91', time_epoch_completed='1702977188.69', return_code='0', job_id='36607008', GAL2='0.94', EG2='0.92', return_code2='0', energy_flux_error='5.57e-06', photon_flux_error2='2.53e-09', ts2='9.16', photon_index='2.12' WHERE bin_id='802' AND source_name='4FGL J1558.8+5625' AND cadence='weekly';

Database successfully updated.


Analysis Complete.


Tue Dec 19 01:13:08 PST 2023

