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


Performing analysis on: 4FGL_J0358.6+0634_weekly_bin782
RA = 59.6656, Dec = 6.5759
tmin = 711936001, tmax = 712540801
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='28613244', job_status='RUN', time_executed='2023-09-19 21:50:51.735770', time_epoch_executed='1695185451.74' WHERE source_name='4FGL J0358.6+0634' and cadence='weekly' and bin_id='782'

Database successfully updated.
Done.

Creating custom output directory:
/lscratch/kocevski/28613244

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

Retrieving the FT1 file...

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

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

Retrieving 107 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/lscratch/kocevski/28613244/ft1_4FGL_J0358.6+0634_weekly_bin782.fits


Retrieving the FT1 file...

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

Retrieving 107 files...
Done.


Merging files...

Merged file saved to:
/lscratch/kocevski/28613244/ft2_4FGL_J0358.6+0634_weekly_bin782.fits


Selecting the photons:
time -p gtselect infile=/lscratch/kocevski/28613244/ft1_4FGL_J0358.6+0634_weekly_bin782.fits outfile=/lscratch/kocevski/28613244/ft1_filteredMKT_4FGL_J0358.6+0634_weekly_bin782.fits ra=59.6656 dec=6.5759 rad=12.0 tmin=711936001.0 tmax=712540801.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.01
user 3.70
sys 0.22

Adding sun position to ft2 file:
/sdf/group/fermi/g/LCRepository/Repository/bin/sunpos /lscratch/kocevski/28613244/ft2_4FGL_J0358.6+0634_weekly_bin782.fits

Selecting the good time intervals:
time -p gtmktime scfile=/lscratch/kocevski/28613244/ft2_4FGL_J0358.6+0634_weekly_bin782.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/28613244/ft1_filteredMKT_4FGL_J0358.6+0634_weekly_bin782.fits evtable="EVENTS" outfile="/lscratch/kocevski/28613244/ft1_filtered_4FGL_J0358.6+0634_weekly_bin782.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.46
user 0.22
sys 0.13

Number of photons that the gtmktime cut: 3803

Generating the livetime cube:
time -p gtltcube evfile="/lscratch/kocevski/28613244/ft1_filtered_4FGL_J0358.6+0634_weekly_bin782.fits" evtable="EVENTS" scfile=/lscratch/kocevski/28613244/ft2_4FGL_J0358.6+0634_weekly_bin782.fits sctable="SC_DATA" outfile=/lscratch/kocevski/28613244/ltcube_711936001_712540801_4FGL_J0358.6+0634_weekly_bin782.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/28613244/ft2_4FGL_J0358.6+0634_weekly_bin782.fits
.....................!
real 19.59
user 19.15
sys 0.25

Generating the exposure map:
time -p gtexpmap evfile=/lscratch/kocevski/28613244/ft1_filtered_4FGL_J0358.6+0634_weekly_bin782.fits evtable="EVENTS" scfile=/lscratch/kocevski/28613244/ft2_4FGL_J0358.6+0634_weekly_bin782.fits sctable="SC_DATA" expcube=/lscratch/kocevski/28613244/ltcube_711936001_712540801_4FGL_J0358.6+0634_weekly_bin782.fits outfile=/lscratch/kocevski/28613244/expmap_711936001_712540801_4FGL_J0358.6+0634_weekly_bin782.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/28613244/ltcube_711936001_712540801_4FGL_J0358.6+0634_weekly_bin782.fits
.....................!
real 65.17
user 60.99
sys 3.69

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=/lscratch/kocevski/28613244/ft1_filtered_4FGL_J0358.6+0634_weekly_bin782.fits scfile=/lscratch/kocevski/28613244/ft2_4FGL_J0358.6+0634_weekly_bin782.fits outfile=/lscratch/kocevski/28613244/cmap_711936001_712540801_4FGL_J0358.6+0634_weekly_bin782.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 0.63
user 0.24
sys 0.16

Creating the high resolution counts map:
time -p gtbin evfile=/lscratch/kocevski/28613244/ft1_filtered_4FGL_J0358.6+0634_weekly_bin782.fits scfile=/lscratch/kocevski/28613244/ft2_4FGL_J0358.6+0634_weekly_bin782.fits outfile=/lscratch/kocevski/28613244/cmap_HighResolution_711936001_712540801_4FGL_J0358.6+0634_weekly_bin782.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 0.44
user 0.24
sys 0.15

Computing the diffuse response:
time -p gtdiffrsp evfile=/lscratch/kocevski/28613244/ft1_filtered_4FGL_J0358.6+0634_weekly_bin782.fits evtable="EVENTS" scfile=/lscratch/kocevski/28613244/ft2_4FGL_J0358.6+0634_weekly_bin782.fits sctable="SC_DATA" srcmdl=/lscratch/kocevski/28613244/Model_4FGL_J0358.6+0634_weekly_bin782.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/28613244/ft1_filtered_4FGL_J0358.6+0634_weekly_bin782.fits.....................!
real 175.78
user 173.58
sys 1.00

Creating the likelihood object...
obs = UnbinnedObs('/lscratch/kocevski/28613244/ft1_filtered_4FGL_J0358.6+0634_weekly_bin782.fits', '/lscratch/kocevski/28613244/ft2_4FGL_J0358.6+0634_weekly_bin782.fits', expMap='/lscratch/kocevski/28613244/expmap_711936001_712540801_4FGL_J0358.6+0634_weekly_bin782.fits', expCube='/lscratch/kocevski/28613244/ltcube_711936001_712540801_4FGL_J0358.6+0634_weekly_bin782.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/lscratch/kocevski/28613244/Model_4FGL_J0358.6+0634_weekly_bin782.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  0.000e+00  1.000e+06 ( 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): /lscratch/kocevski/28613244/ft1_filtered_4FGL_J0358.6+0634_weekly_bin782.fits
Spacecraft file(s): /lscratch/kocevski/28613244/ft2_4FGL_J0358.6+0634_weekly_bin782.fits
Exposure map: /lscratch/kocevski/28613244/expmap_711936001_712540801_4FGL_J0358.6+0634_weekly_bin782.fits
Exposure cube: /lscratch/kocevski/28613244/ltcube_711936001_712540801_4FGL_J0358.6+0634_weekly_bin782.fits
IRFs: P8R3_SOURCE_V2
Source model file: /lscratch/kocevski/28613244/Model_4FGL_J0358.6+0634_weekly_bin782.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) = 39683.1743743

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    2.1591       1.0000          .0000       .10000E+07
     2 'Prefactor '    .51276E-06   1.0000          .0000       .10000E+07
     3 'norm      '    .12434E-07   1.0000          .0000       .10000E+07
     4 'norm      '    3.4574       1.0000          .0000       .10000E+07
     5 'Prefactor '    .29914E-03   1.0000          .0000       .10000E+07
     6 'Prefactor '    33.718       1.0000          .0000       .10000E+07
     7 'norm      '    .41472E-04   1.0000          .0000       .10000E+07
     8 'Prefactor '    .23717E-05   1.0000          .0000       .10000E+07
     9 'norm      '    .48753E-04   1.0000          .0000       .10000E+07
    10 'Prefactor '    15.063       1.0000          .0000       .10000E+07
    11 'norm      '    2.5512       1.0000          .0000       .10000E+07
    12 'Prefactor '    .38891       1.0000          .0000       .10000E+07
    13 'Prefactor '    27.125       1.0000          .0000       .10000E+07
    14 'Prefactor '    .71260E-04   1.0000          .0000       .10000E+07
    15 'norm      '    1.6805       1.0000          .0000       .10000E+07
    16 'Prefactor '    .41689E-07   1.0000          .0000       .10000E+07
    17 'Normalizat'    .97410       1.0000         .10000E-01   10.000    
    18 'Prefactor '    1.0334       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .4630E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   39683.16     FROM MIGRAD    STATUS=CONVERGED    115 CALLS     1049 TOTAL
                     EDM=   .49E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.8%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     2.1586        1.5221        .17905E-07    .18489E-02
   2  Prefactor      .0000        2.4097       -.11131E-06** at limit **
   3  norm           .0000        .87788        .58848E-07** at limit **
   4  norm          3.4584        .76845       -.25712E-08   -.17412E-02
   5  Prefactor     .17375E-07    8.5859       -.11276E-06** at limit **
   6  Prefactor     33.717        8.5849        .21616E-08    .17454E-02
   7  norm          .55511E-10    2.8196        .14598E-06** at limit **
   8  Prefactor     .21927E-07    8.2498       -.47104E-07** at limit **
   9  norm          .55511E-10    3.5688        .92907E-07** at limit **
  10  Prefactor     15.053        2.1999       -.27592E-08    .78429E-01
  11  norm          2.5503        .60290        .19452E-07    .14947E-01
  12  Prefactor     .38987        .51453       -.37320E-08    .22123E-03
  13  Prefactor     27.124        1.8468       -.24959E-08    .99804E-01
  14  Prefactor     .55511E-09    55.175       -.82259E-07** at limit **
  15  norm          1.6836        1.4026        .19985E-08   -.13459E-02
  16  Prefactor     .61062E-09    14.737       -.97233E-07** at limit **
  17  Normalizat    .97413        .13028       -.22122E-06    .31986E-04
  18  Prefactor     1.0334        .39109E-01    .48813E-07    .11815E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 2.15857
  Prefactor  = 0
  norm       = 0
  norm       = 3.45843
  Prefactor  = 1.7375e-08
  Prefactor  = 33.7175
  norm       = 5.55112e-11
  Prefactor  = 2.19269e-08
  norm       = 5.55112e-11
  Prefactor  = 15.0526
  norm       = 2.55035
  Prefactor  = 0.389868
  Prefactor  = 27.1241
  Prefactor  = 5.55112e-10
  norm       = 1.68362
  Prefactor  = 6.10623e-10
  Normalizat = 0.974126
  Prefactor  = 1.03338
 **********
 **   18 **HESSE 
 **********

 FCN=   39683.16     FROM HESSE     STATUS=OK           290 CALLS     1339 TOTAL
                     EDM=   .11E-06    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     2.1586        1.5160        .70076E-03   -1.5679    
   2  Prefactor      .0000        2.4058        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm           .0000        .87942        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  norm          3.4584        .77230        .54365E-03   -1.5671    
   5  Prefactor     .17375E-07    8.7394        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     33.717        8.6491        .17223E-03   -1.5592    
   7  norm          .55511E-10    2.8287        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .21927E-07    8.4356        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  norm          .55511E-10    .56317        .57873E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     15.053        12.802        .25780E-03   -1.5630    
  11  norm          2.5503        .62224        .63899E-03   -1.5676    
  12  Prefactor     .38987        .53118        .37058E-02   -1.5695    
  13  Prefactor     27.124        13.297        .19204E-03   -1.5604    
  14  Prefactor     .55511E-09    54.934        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  norm          1.6836        1.6872        .81231E-03   -1.5682    
  16  Prefactor     .61062E-09    14.764        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  Normalizat    .97413        .12173        .10866       -.93902    
  18  Prefactor     1.0334        .35658E-01    .41000E-01   -.91625    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.10124e-07
Minuit parameter uncertainties:
  1  1.51597
  2  1.10732e-05
  3  5.8535e-06
  4  0.772301
  5  0.000779782
  6  8.64906
  7  2.62167e-05
  8  0.000860504
  9  1.22422e-05
  10  12.8018
  11  0.622237
  12  0.531183
  13  13.2971
  14  0.000346565
  15  1.68717
  16  0.000189092
  17  0.121763
  18  0.0356583
Done.

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

Extracting fit parameters...

4FGL J0358.6+0634
   Spectrum: PowerLaw
232    Prefactor:  1.737e-08  7.798e-04  0.000e+00  1.000e+06 ( 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:  1.033e+00  3.566e-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.741e-01  1.218e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 59.666 6.576
Photon Flux Upper Limit: 3.69564226616e-08 ph cm-2 s-1
Energy Flux Upper Limit: 0.00288635508902 MeV cm-2 s-1

Saving results to:
/lscratch/kocevski/28613244/likelihoodResults_711936001_712540801_4FGL_J0358.6+0634_weekly_bin782.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) = 39683.1646028
delta logL = -0.00143912129715

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 39683.1631641
delta logL = -4.56217094325e-07

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .82312E-06   1.0000          .0000       .10000E+07
     2 'Index     '    1.3322       1.0000          .0000       10.000    
     3 'Normalizat'    .97411       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.0334       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.
  MNHESS FAILS AND WILL RETURN DIAGONAL MATRIX. 

 FCN=   39683.16     FROM MIGRAD    STATUS=CONVERGED     42 CALLS      239 TOTAL
                     EDM=   .12E-11  STRATEGY=1  ERROR MATRIX UNCERTAINTY=100.0%

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor      .0000        9.5617        .42118E-03** at limit **
   2  Index         2.4638        1.3584        .32154E-05     .0000    
   3  Normalizat    .97413        1.3054        .41653E-05    .15267E-04
   4  Prefactor     1.0334        1.2133       -.21308E-05    .14446E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0
  Index      = 2.46383
  Normalizat = 0.974125
  Prefactor  = 1.03338
 **********
 **   18 **HESSE 
 **********
  MNHESS FAILS AND WILL RETURN DIAGONAL MATRIX. 

 FCN=   39683.16     FROM HESSE     STATUS=FAILED         9 CALLS      248 TOTAL
                     EDM=   .12E-11  STRATEGY=1  ERROR MATRIX UNCERTAINTY=100.0%

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor      .0000        9.5617        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         .68300        1.9102        .32154E-05   -.53197    
   3  Normalizat    .97413        1.3054        .41653E-05   -.93902    
   4  Prefactor     1.0334        1.2133       -.21308E-05   -.91625    
                               ERR DEF=  .500    
Minuit fit quality: 1   estimated distance: 1.17535e-12
Minuit parameter uncertainties:
  1  7.61407e-06
  2  1.38197
  3  1.3523
  4  1.24799
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
Done.

MINUIT Return Code (Free Index): 101
logL (Free Index) = 39683.1631637
delta logL = 9.89530235529e-10

Extracting fit parameters...

4FGL J0358.6+0634
   Spectrum: PowerLaw
232    Prefactor:  0.000e+00  7.614e-06  0.000e+00  1.000e+06 ( 1.000e-13)
233        Index:  2.464e+00  1.382e+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:  1.033e+00  1.248e+00  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.741e-01  1.352e+00  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 59.666 6.576

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/28613244/cmap_HighResolution_711936001_712540801_4FGL_J0358.6+0634_weekly_bin782.png

Cleaning up...

** Nuclear option initiated! **

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='2.89e-03', job_status='DONE', photon_flux_upper_limit='3.70e-08', time_completed='2023-09-19 22:02:41.600720', job_id='28613244', GAL2='1.03', fit_tolerance='1e-08', EG2='0.97', EG='0.97', time_epoch_completed='1695186161.6', return_code2='101', ts='-0.00', comment='SUCCESS', return_code='0', GAL='1.03', dlogl='9.90e-10', ts2='0.00', photon_index_error='0.00', photon_index='2.57' WHERE bin_id='782' AND source_name='4FGL J0358.6+0634' AND cadence='weekly';

Database successfully updated.


Analysis Complete.


Tue Sep 19 22:02:41 PDT 2023

