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


Performing analysis on: 4FGL_J2358.3-1021_daily_bin1039
RA = 359.582, Dec = -10.3616
tmin = 508636801, tmax = 508896001
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='231554', job_status='RUN', time_executed='2021-09-30 11:26:10.208118', time_epoch_executed='1633026370.21' WHERE source_name='4FGL J2358.3-1021' and cadence='daily' and bin_id='1039'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/231554

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/231554/ft1_4FGL_J2358.3-1021_daily_bin1039.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/231554/ft2_4FGL_J2358.3-1021_daily_bin1039.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/231554/ft1_4FGL_J2358.3-1021_daily_bin1039.fits outfile=/scratch/kocevski/231554/ft1_filteredMKT_4FGL_J2358.3-1021_daily_bin1039.fits ra=359.582 dec=-10.3616 rad=12.0 tmin=508636801.0 tmax=508896001.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.72
user 3.48
sys 0.20

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/231554/ft2_4FGL_J2358.3-1021_daily_bin1039.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/231554/ft2_4FGL_J2358.3-1021_daily_bin1039.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/231554/ft1_filteredMKT_4FGL_J2358.3-1021_daily_bin1039.fits evtable="EVENTS" outfile="/scratch/kocevski/231554/ft1_filtered_4FGL_J2358.3-1021_daily_bin1039.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.48
user 0.32
sys 0.16

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/231554/ft1_filtered_4FGL_J2358.3-1021_daily_bin1039.fits" evtable="EVENTS" scfile=/scratch/kocevski/231554/ft2_4FGL_J2358.3-1021_daily_bin1039.fits sctable="SC_DATA" outfile=/scratch/kocevski/231554/ltcube_508636801_508896001_4FGL_J2358.3-1021_daily_bin1039.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/231554/ft2_4FGL_J2358.3-1021_daily_bin1039.fits
.....................!
real 11.67
user 11.29
sys 0.35

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/231554/ft1_filtered_4FGL_J2358.3-1021_daily_bin1039.fits evtable="EVENTS" scfile=/scratch/kocevski/231554/ft2_4FGL_J2358.3-1021_daily_bin1039.fits sctable="SC_DATA" expcube=/scratch/kocevski/231554/ltcube_508636801_508896001_4FGL_J2358.3-1021_daily_bin1039.fits outfile=/scratch/kocevski/231554/expmap_508636801_508896001_4FGL_J2358.3-1021_daily_bin1039.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/231554/ltcube_508636801_508896001_4FGL_J2358.3-1021_daily_bin1039.fits
.....................!
real 192.77
user 187.25
sys 5.18

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

Setting source of interest to:
4FGL J2358.3-1021 @ 359.582 -10.3616

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/231554/ft1_filtered_4FGL_J2358.3-1021_daily_bin1039.fits scfile=/scratch/kocevski/231554/ft2_4FGL_J2358.3-1021_daily_bin1039.fits outfile=/scratch/kocevski/231554/cmap_508636801_508896001_4FGL_J2358.3-1021_daily_bin1039.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=359.582 yref=-10.3616 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.53
user 0.38
sys 0.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/231554/ft1_filtered_4FGL_J2358.3-1021_daily_bin1039.fits scfile=/scratch/kocevski/231554/ft2_4FGL_J2358.3-1021_daily_bin1039.fits outfile=/scratch/kocevski/231554/cmap_HighResolution_508636801_508896001_4FGL_J2358.3-1021_daily_bin1039.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=359.582 yref=-10.3616 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.53
user 0.38
sys 0.14

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/231554/ft1_filtered_4FGL_J2358.3-1021_daily_bin1039.fits evtable="EVENTS" scfile=/scratch/kocevski/231554/ft2_4FGL_J2358.3-1021_daily_bin1039.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/231554/Model_4FGL_J2358.3-1021_daily_bin1039.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/231554/ft1_filtered_4FGL_J2358.3-1021_daily_bin1039.fits.....................!
real 42.75
user 41.45
sys 1.21

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/231554/ft1_filtered_4FGL_J2358.3-1021_daily_bin1039.fits', '/scratch/kocevski/231554/ft2_4FGL_J2358.3-1021_daily_bin1039.fits', expMap='/scratch/kocevski/231554/expmap_508636801_508896001_4FGL_J2358.3-1021_daily_bin1039.fits', expCube='/scratch/kocevski/231554/ltcube_508636801_508896001_4FGL_J2358.3-1021_daily_bin1039.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/231554/Model_4FGL_J2358.3-1021_daily_bin1039.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J2358.3-1021'

4FGL J2358.3-1021
   Spectrum: PowerLaw
544    Prefactor:  4.076e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-12)
545        Index:  2.593e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
546        Scale:  5.750e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/231554/ft1_filtered_4FGL_J2358.3-1021_daily_bin1039.fits
Spacecraft file(s): /scratch/kocevski/231554/ft2_4FGL_J2358.3-1021_daily_bin1039.fits
Exposure map: /scratch/kocevski/231554/expmap_508636801_508896001_4FGL_J2358.3-1021_daily_bin1039.fits
Exposure cube: /scratch/kocevski/231554/ltcube_508636801_508896001_4FGL_J2358.3-1021_daily_bin1039.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/231554/Model_4FGL_J2358.3-1021_daily_bin1039.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) = 4226.13684499

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     2 'norm      '    36.706       1.0000         .10000E-03   10000.    
     3 'Prefactor '    24.465       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .31820       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .30433E-03   1.0000         .10000E-03   10000.    
     6 'norm      '    .11241E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    8.4490       1.0000         .10000E-03   10000.    
     8 'norm      '    6.4705       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    10 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    26.628       1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    1.7121       1.0000         .10000E-03   10000.    
    15 'norm      '    14.882       1.0000         .10000E-03   10000.    
    16 'Prefactor '    .10136E-03   1.0000         .10000E-03   10000.    
    17 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    .11535E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    20 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10024E-03   1.0000         .10000E-03   10000.    
    23 'norm      '    .10011E-03   1.0000         .10000E-03   10000.    
    24 'norm      '    2.0273       1.0000         .10000E-03   10000.    
    25 'Prefactor '    18.172       1.0000         .10000E-03   10000.    
    26 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    27 'Normalizat'    1.0673       1.0000         .10000E-01   10.000    
    28 'Prefactor '    .88375       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5660E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   4226.130     FROM MIGRAD    STATUS=CONVERGED    716 CALLS     3551 TOTAL
                     EDM=   .13E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .6%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    3.3977       -.16259E-06** at limit **
   2  norm          36.710        50.306        .50397E-05    .35571E-05
   3  Prefactor     24.464        39.095        .79277E-06    .11228E-03
   4  Prefactor     .47372        15.452       -.30833E-05    .30719E-03
   5  Prefactor     .10004E-03    7.2738       -.30038E-05** at limit **
   6  norm          .10000E-03    1.8504        .86279E-07** at limit **
   7  Prefactor     8.4480        17.015       -.29915E-05    .31879E-03
   8  norm          6.4674        5.9352        .13220E-05    .21546E-02
   9  Prefactor     .10000E-03    10.082       -.47911E-05** at limit **
  10  norm          .10000E-03    4.7732       -.12336E-05** at limit **
  11  Prefactor     .10000E-03    32.145        .25436E-04** at limit **
  12  Prefactor     26.636        33.935        .31776E-05    .85997E-05
  13  Prefactor     .10000E-03    5.5683       -.12576E-05** at limit **
  14  norm          1.7131        1.4450       -.13471E-07   -.27587E-03
  15  norm          14.883        8.5556       -.15815E-06   -.76943E-04
  16  Prefactor     .10000E-03    35.682       -.25891E-04** at limit **
  17  Prefactor     .10000E-03    10.773        .47186E-05** at limit **
  18  Prefactor     .10000E-03    180.52       -.37944E-04** at limit **
  19  Prefactor     .10000E-03    4.4741       -.53082E-06** at limit **
  20  norm          .10000E-03    8.4579        .63270E-06** at limit **
  21  Prefactor     .10000E-03    22.828       -.29549E-05** at limit **
  22  Prefactor     .10000E-03    5.2881        .12627E-05** at limit **
  23  norm          .10000E-03    .30837        .17362E-07** at limit **
  24  norm          2.0278        4.8752       -.12985E-05   -.47336E-03
  25  Prefactor     18.171        17.284        .95977E-06    .12497E-03
  26  Prefactor     .10000E-03    4.6182        .11802E-05** at limit **
  27  Normalizat    1.0676        .22022       -.19090E-06    .42382E-03
  28  Prefactor     .88343        .19614        .15883E-06    .34482E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  norm       = 36.7102
  Prefactor  = 24.4638
  Prefactor  = 0.473724
  Prefactor  = 0.000100042
  norm       = 0.000100001
  Prefactor  = 8.44799
  norm       = 6.46737
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 26.6358
  Prefactor  = 0.0001
  norm       = 1.71309
  norm       = 14.8826
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 2.02777
  Prefactor  = 18.1712
  Prefactor  = 0.0001
  Normalizat = 1.0676
  Prefactor  = 0.883426
 **********
 **   18 **HESSE 
 **********

 FCN=   4226.130     FROM HESSE     STATUS=OK           517 CALLS     4068 TOTAL
                     EDM=   .94E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    3.4007        .11703E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  norm          36.710        50.307        .66150E-04   -1.4495    
   3  Prefactor     24.464        39.024        .80987E-04   -1.4718    
   4  Prefactor     .47372        126.97        .48321E-02   -1.5570    
   5  Prefactor     .10004E-03    18.457        .27651E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  norm          .10000E-03    6.1655        .16725E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     8.4480        16.916        .13791E-03   -1.5127    
   8  norm          6.4674        5.1363        .11554E-03   -1.5199    
   9  Prefactor     .10000E-03    10.084        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  norm          .10000E-03    4.7998        .13870E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .10000E-03    31.973        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     26.636        33.930        .77633E-04   -1.4675    
  13  Prefactor     .10000E-03    5.5812        .14975E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          1.7131        1.4322        .67195E-04   -1.5446    
  15  norm          14.883        8.5358        .10382E-03   -1.4936    
  16  Prefactor     .10000E-03    35.510        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  Prefactor     .10000E-03    10.779        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .10000E-03    180.16        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10000E-03    4.4784        .13428E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  norm          .10000E-03    8.4612        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .10000E-03    22.831        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     .10000E-03    5.4964        .29150E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  norm          .10000E-03    .38635        .67865E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  norm          2.0278        4.7280        .20516E-03   -1.5423    
  25  Prefactor     18.171        17.272        .93955E-04   -1.4855    
  26  Prefactor     .10000E-03    4.6518        .13638E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  Normalizat    1.0676        .25209        .24846E-03   -.90799    
  28  Prefactor     .88343        .22677        .24422E-03   -.96723    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 9.41271e-09
Minuit parameter uncertainties:
  1  1.45607e-06
  2  50.3657
  3  39.0645
  4  15.5426
  5  0.00176503
  6  0.000141557
  7  16.9254
  8  5.13665
  9  1.18996e-06
  10  2.1617e-06
  11  5.63327e-06
  12  33.9542
  13  7.5878e-07
  14  1.43218
  15  8.5365
  16  2.91565e-07
  17  1.30222e-06
  18  1.71632e-05
  19  5.19442e-08
  20  6.16536e-07
  21  5.77709e-07
  22  1.00453e-05
  23  7.65213e-06
  24  4.72884
  25  17.2769
  26  1.92681e-06
  27  0.252375
  28  0.227013
Done.

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

Extracting fit parameters...

4FGL J2358.3-1021
   Spectrum: PowerLaw
544    Prefactor:  1.000e-04  1.927e-06  1.000e-04  1.000e+04 ( 1.000e-12)
545        Index:  2.593e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
546        Scale:  5.750e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
563    Prefactor:  8.834e-01  2.270e-01  0.000e+00  1.000e+01 ( 1.000e+00)
564        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
565        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
562   Normalization:  1.068e+00  2.524e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 359.582 -10.362
Photon Flux Upper Limit: 9.55e-08 ph cm-2 s-1
Energy Flux Upper Limit: 7.47e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/231554/likelihoodResults_508636801_508896001_4FGL_J2358.3-1021_daily_bin1039.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) = 4226.13073273
delta logL = -0.00102348109067

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 4226.1297093
delta logL = -4.70417944598e-08

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10022E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.5972       1.0000          .0000       10.000    
     3 'Normalizat'    1.0676       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .88347       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5660E+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.
 MIGRAD TERMINATED WITHOUT CONVERGENCE.

 FCN=   4225.873     FROM MIGRAD    STATUS=FAILED       211 CALLS      344 TOTAL
                     EDM=   .11E-06    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    .30780E-01    .28400E-03** at limit **
   2  Index         9.7582        8.9008        .92830E-01    .38952E-04
   3  Normalizat    1.0315        .91854E-01    .24846E-03    .19832E-03
   4  Prefactor     .90574        .83003E-01    .24422E-03    .42268E-04
                               ERR DEF=  .500    
 START SIMPLEX MINIMIZATION.    CONVERGENCE WHEN EDM .LT.   .20E-04
 SIMPLEX MINIMIZATION HAS CONVERGED.

 FCN=   4225.873     FROM SIMPLEX   STATUS=UNCHANGED    177 CALLS      521 TOTAL
                     EDM=   .95E-05    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    .30780E-01    .99300E-05** at limit **
   2  Index         9.7582        8.9008        .20339E-03    .38952E-04
   3  Normalizat    1.0315        .91854E-01    .21336E-05    .19832E-03
   4  Prefactor     .90574        .83003E-01    .11426E-05    .42268E-04
                               ERR DEF=  .500    

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   4225.873     FROM MIGRAD    STATUS=CONVERGED     40 CALLS      561 TOTAL
                     EDM=   .63E-11    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    .34004E-01    .27140E-03** at limit **
   2  Index         9.7582        8.8877        .37132E-02    .12216E-05
   3  Normalizat    1.0315        .95853E-01    .49692E-04    .49280E-04
   4  Prefactor     .90574        .86849E-01    .97688E-05   -.34913E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Index      = 9.75819
  Normalizat = 1.03153
  Prefactor  = 0.905739
 **********
 **   18 **HESSE 
 **********

 FCN=   4225.873     FROM HESSE     STATUS=NOT POSDEF    33 CALLS      594 TOTAL
                     EDM=   .58E-11    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    .33357E-01    .27434E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         9.7582        8.8492        .14853E-03    1.2585    
   3  Normalizat    1.0315        .95335E-01    .99384E-05   -.91982    
   4  Prefactor     .90574        .86376E-01    .19538E-05   -.95941    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 5.75075e-12
Minuit parameter uncertainties:
  1  1.03587e-07
  2  12.5505
  3  0.0953504
  4  0.0863893
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/231554': 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): 102
logL (Free Index) = 4225.872792
delta logL = 0.256917245698

Extracting fit parameters...

4FGL J2358.3-1021
   Spectrum: PowerLaw
544    Prefactor:  1.000e-04  1.036e-07  1.000e-04  1.000e+04 ( 1.000e-12)
545        Index:  9.758e+00  1.255e+01  0.000e+00  1.000e+01 (-1.000e+00)
546        Scale:  5.750e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
563    Prefactor:  9.057e-01  8.639e-02  0.000e+00  1.000e+01 ( 1.000e+00)
564        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
565        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
562   Normalization:  1.032e+00  9.535e-02  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 359.582 -10.362

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/231554/cmap_HighResolution_508636801_508896001_4FGL_J2358.3-1021_daily_bin1039.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='7.47e-03', job_status='DONE', photon_flux_upper_limit='9.55e-08', time_completed='2021-09-30 11:36:45.867920', job_id='231554', GAL2='0.91', fit_tolerance='1e-08', EG2='1.03', EG='1.07', time_epoch_completed='1633027005.87', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.88', dlogl='2.57e-01', ts2='0.54', photon_index_error='0.00', photon_index='2.59' WHERE bin_id='1039' AND source_name='4FGL J2358.3-1021' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Sep 30 11:36:45 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0274>
Subject: Job 231554: <4FGL_J2358.3-1021_daily_bin1039> in cluster <slac> Done

Job <4FGL_J2358.3-1021_daily_bin1039> was submitted from host <rhel6-64f> by user <kocevski> in cluster <slac> at Thu Sep 30 11:25:45 2021
Job was executed on host(s) <bullet0274>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Sep 30 11:25:47 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Thu Sep 30 11:25:47 2021
Terminated at Thu Sep 30 11:36:46 2021
Results reported at Thu Sep 30 11:36:46 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J2358.3-1021_daily_bin1039 359.582 -10.3616 508636801 508896001 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J2358.3-1021 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   624.00 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             280.10 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   659 sec.
    Turnaround time :                            661 sec.

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

