aklog: Couldn't determine realm of user:aklog: unknown RPC error (-1765328189)  while getting realm
/nfs/farm/g/glast/g/LCRepository/bin/miniconda2/envs/fermitools_v1.0.5/lib/python2.7/site-packages/matplotlib/font_manager.py:281: UserWarning: Matplotlib is building the font cache using fc-list. This may take a moment.
  'Matplotlib is building the font cache using fc-list. '
/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 128 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 = 17006
number of fields = 30
RA_SUN column already exists. File will not be modified.
Done.


Performing analysis on: 4FGL_J0058.4+3315_weekly_bin582
RA = 14.6101, Dec = 33.2505
tmin = 590976001, tmax = 591580801
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='28201', job_status='RUN', time_executed='2021-07-03 13:40:09.310916', time_epoch_executed='1625344809.31' WHERE source_name='4FGL J0058.4+3315' and cadence='weekly' and bin_id='582'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/28201

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

Retrieving the FT1 file...

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

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

Retrieving 107 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/28201/ft1_4FGL_J0058.4+3315_weekly_bin582.fits


Retrieving the FT1 file...

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

Retrieving 107 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/28201/ft2_4FGL_J0058.4+3315_weekly_bin582.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/28201/ft1_4FGL_J0058.4+3315_weekly_bin582.fits outfile=/scratch/kocevski/28201/ft1_filteredMKT_4FGL_J0058.4+3315_weekly_bin582.fits ra=14.6101 dec=33.2505 rad=12.0 tmin=590976001.0 tmax=591580801.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 7.10
user 6.69
sys 0.29

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/28201/ft2_4FGL_J0058.4+3315_weekly_bin582.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/28201/ft2_4FGL_J0058.4+3315_weekly_bin582.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/28201/ft1_filteredMKT_4FGL_J0058.4+3315_weekly_bin582.fits evtable="EVENTS" outfile="/scratch/kocevski/28201/ft1_filtered_4FGL_J0058.4+3315_weekly_bin582.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.76
user 0.37
sys 0.16

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/28201/ft1_filtered_4FGL_J0058.4+3315_weekly_bin582.fits" evtable="EVENTS" scfile=/scratch/kocevski/28201/ft2_4FGL_J0058.4+3315_weekly_bin582.fits sctable="SC_DATA" outfile=/scratch/kocevski/28201/ltcube_590976001_591580801_4FGL_J0058.4+3315_weekly_bin582.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/28201/ft2_4FGL_J0058.4+3315_weekly_bin582.fits
.....................!
real 27.65
user 27.08
sys 0.30

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/28201/ft1_filtered_4FGL_J0058.4+3315_weekly_bin582.fits evtable="EVENTS" scfile=/scratch/kocevski/28201/ft2_4FGL_J0058.4+3315_weekly_bin582.fits sctable="SC_DATA" expcube=/scratch/kocevski/28201/ltcube_590976001_591580801_4FGL_J0058.4+3315_weekly_bin582.fits outfile=/scratch/kocevski/28201/expmap_590976001_591580801_4FGL_J0058.4+3315_weekly_bin582.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/28201/ltcube_590976001_591580801_4FGL_J0058.4+3315_weekly_bin582.fits
.....................!
real 191.01
user 185.49
sys 5.04

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

Setting source of interest to:
4FGL J0058.4+3315 @ 14.6101 33.2505

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/28201/ft1_filtered_4FGL_J0058.4+3315_weekly_bin582.fits scfile=/scratch/kocevski/28201/ft2_4FGL_J0058.4+3315_weekly_bin582.fits outfile=/scratch/kocevski/28201/cmap_590976001_591580801_4FGL_J0058.4+3315_weekly_bin582.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=14.6101 yref=33.2505 axisrot=0.0 rafield="RA" decfield="DEC" proj="AIT" hpx_ordering_scheme="RING" hpx_order=3 hpx_ebin=yes hpx_region="" evtable="EVENTS" sctable="SC_DATA" efield="ENERGY" tfield="TIME" chatter=2 clobber=yes debug=no gui=no mode="ql"

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

This is gtbin version HEAD
real 0.59
user 0.40
sys 0.16

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/28201/ft1_filtered_4FGL_J0058.4+3315_weekly_bin582.fits scfile=/scratch/kocevski/28201/ft2_4FGL_J0058.4+3315_weekly_bin582.fits outfile=/scratch/kocevski/28201/cmap_HighResolution_590976001_591580801_4FGL_J0058.4+3315_weekly_bin582.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=14.6101 yref=33.2505 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.64
user 0.39
sys 0.18

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/28201/ft1_filtered_4FGL_J0058.4+3315_weekly_bin582.fits evtable="EVENTS" scfile=/scratch/kocevski/28201/ft2_4FGL_J0058.4+3315_weekly_bin582.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/28201/Model_4FGL_J0058.4+3315_weekly_bin582.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/28201/ft1_filtered_4FGL_J0058.4+3315_weekly_bin582.fits.....................!
real 35.93
user 34.63
sys 1.16

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/28201/ft1_filtered_4FGL_J0058.4+3315_weekly_bin582.fits', '/scratch/kocevski/28201/ft2_4FGL_J0058.4+3315_weekly_bin582.fits', expMap='/scratch/kocevski/28201/expmap_590976001_591580801_4FGL_J0058.4+3315_weekly_bin582.fits', expCube='/scratch/kocevski/28201/ltcube_590976001_591580801_4FGL_J0058.4+3315_weekly_bin582.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/28201/Model_4FGL_J0058.4+3315_weekly_bin582.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J0058.4+3315'

4FGL J0058.4+3315
   Spectrum: PowerLaw
189    Prefactor:  1.596e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
190        Index:  2.343e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
191        Scale:  1.298e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/28201/ft1_filtered_4FGL_J0058.4+3315_weekly_bin582.fits
Spacecraft file(s): /scratch/kocevski/28201/ft2_4FGL_J0058.4+3315_weekly_bin582.fits
Exposure map: /scratch/kocevski/28201/expmap_590976001_591580801_4FGL_J0058.4+3315_weekly_bin582.fits
Exposure cube: /scratch/kocevski/28201/ltcube_590976001_591580801_4FGL_J0058.4+3315_weekly_bin582.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/28201/Model_4FGL_J0058.4+3315_weekly_bin582.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) = 2786.61003406

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    36.340       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10031E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .30862E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     6 'norm      '    .10007E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10061E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10048E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10010E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    13.394       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10012E-03   1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10012E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    1.6446       1.0000         .10000E-03   10000.    
    15 'norm      '    1.0099       1.0000         .10000E-03   10000.    
    16 'Prefactor '    43.248       1.0000         .10000E-03   10000.    
    17 'Prefactor '    .10515E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    13.867       1.0000         .10000E-03   10000.    
    19 'Prefactor '    1.1683       1.0000         .10000E-03   10000.    
    20 'norm      '    2.0054       1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10007E-03   1.0000         .10000E-03   10000.    
    22 'norm      '    2.3920       1.0000         .10000E-03   10000.    
    23 'Prefactor '    25.260       1.0000         .10000E-03   10000.    
    24 'Normalizat'    .39548       1.0000         .10000E-01   10.000    
    25 'Prefactor '    1.1540       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5490E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   2786.592     FROM MIGRAD    STATUS=CONVERGED    572 CALLS     2860 TOTAL
                     EDM=   .12E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  3.5%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          36.319        41.460        .27093E-05    .31425E-04
   2  Prefactor     .10000E-03    10.336        .45231E-06** at limit **
   3  Prefactor     .10000E-03    39.769        .14927E-05** at limit **
   4  Prefactor     .10000E-03    147.21        .19177E-05** at limit **
   5  Prefactor     .10000E-03    25.740        .15138E-06** at limit **
   6  norm          .10000E-03    1.6364        .12973E-06** at limit **
   7  Prefactor     .10000E-03    36.659        .28946E-06** at limit **
   8  Prefactor     .10000E-03    6.4459        .21456E-06** at limit **
   9  Prefactor     .10000E-03    8.1237        .81402E-07** at limit **
  10  Prefactor     13.376        18.421        .20296E-05    .12856E-03
  11  Prefactor     .10000E-03    71.090       -.12429E-05** at limit **
  12  Prefactor     .10000E-03    36.815       -.19534E-05** at limit **
  13  Prefactor     .10000E-03    58.297        .19725E-05** at limit **
  14  norm          1.6447        1.2524       -.26197E-06    .32964E-04
  15  norm          1.0105        2.3837        .10872E-06   -.75528E-04
  16  Prefactor     43.189        73.462        .69718E-05    .69706E-04
  17  Prefactor     .10001E-03    6.4798       -.31291E-05** at limit **
  18  Prefactor     13.861        16.733        .77499E-06    .81816E-04
  19  Prefactor     1.1673        53.890        .32146E-04   -.12451E-03
  20  norm          2.0055        1.7870        .98465E-07    .18405E-03
  21  Prefactor     .10000E-03    111.57        .44757E-06** at limit **
  22  norm          2.3918        1.3755       -.38750E-07    .92282E-04
  23  Prefactor     25.260        22.534        .55894E-06    .47395E-04
  24  Normalizat    .39573        .33229       -.11844E-04   -.31914E-04
  25  Prefactor     1.1538        .19931        .22863E-05    .20044E-03
                               ERR DEF=  .500    
Final values: 
  norm       = 36.3191
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.000100004
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 13.3757
  Prefactor  = 0.000100001
  Prefactor  = 0.000100001
  Prefactor  = 0.0001
  norm       = 1.64473
  norm       = 1.01054
  Prefactor  = 43.1893
  Prefactor  = 0.000100009
  Prefactor  = 13.8608
  Prefactor  = 1.16733
  norm       = 2.00552
  Prefactor  = 0.0001
  norm       = 2.39177
  Prefactor  = 25.2597
  Normalizat = 0.395726
  Prefactor  = 1.15382
 **********
 **   18 **HESSE 
 **********

 FCN=   2786.592     FROM HESSE     STATUS=OK           421 CALLS     3281 TOTAL
                     EDM=   .22E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          36.319        41.414        .66481E-04   -1.4502    
   2  Prefactor     .10000E-03    10.514        .16573E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10000E-03    39.768        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    151.71        .42756E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10000E-03    25.744        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  norm          .10000E-03    1.6440        .65947E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10000E-03    37.605        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .10000E-03    6.4863        .13087E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     .10000E-03    8.1290        .14695E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     13.376        18.359        .54723E-03   -1.4976    
  11  Prefactor     .10000E-03    72.041        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10000E-03    36.881        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     .10000E-03    58.295        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          1.6447        1.2406        .49079E-04   -1.5451    
  15  norm          1.0105        2.2630        .11141E-03   -1.5507    
  16  Prefactor     43.189        73.695        .60960E-04   -1.4393    
  17  Prefactor     .10001E-03    6.7247        .13331E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     13.861        16.385        .10756E-03   -1.4963    
  19  Prefactor     1.1673        54.512        .21248E-02   -1.5492    
  20  norm          2.0055        1.7976        .64381E-04   -1.5425    
  21  Prefactor     .10000E-03    111.60        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  norm          2.3918        1.3741        .45198E-04   -1.5399    
  23  Prefactor     25.260        22.518        .79704E-04   -1.4702    
  24  Normalizat    .39573        .33901        .42509E-03   -1.1752    
  25  Prefactor     1.1538        .20926        .16848E-03   -.87765    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.22654e-09
Minuit parameter uncertainties:
  1  41.4465
  2  9.20258e-05
  3  5.16331e-05
  4  0.00150389
  5  1.82293e-05
  6  1.05788e-05
  7  0.000260033
  8  3.2146e-05
  9  1.46452e-05
  10  18.3669
  11  0.000649231
  12  0.000331934
  13  5.39904e-05
  14  1.24065
  15  2.26317
  16  73.8512
  17  0.000483362
  18  16.3906
  19  15.9689
  20  1.79765
  21  0.000122362
  22  1.37407
  23  22.526
  24  0.340789
  25  0.209409
Done.

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

Extracting fit parameters...

4FGL J0058.4+3315
   Spectrum: PowerLaw
189    Prefactor:  1.000e-04  1.465e-05  1.000e-04  1.000e+04 ( 1.000e-13)
190        Index:  2.343e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
191        Scale:  1.298e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
546    Prefactor:  1.154e+00  2.094e-01  0.000e+00  1.000e+01 ( 1.000e+00)
547        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
548        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
545   Normalization:  3.957e-01  3.408e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 14.610 33.251
Photon Flux Upper Limit: 1.21e-07 ph cm-2 s-1
Energy Flux Upper Limit: 9.29e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/28201/likelihoodResults_590976001_591580801_4FGL_J0058.4+3315_weekly_bin582.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): 102
logL (Free Index) = 2786.59260931
delta logL = -0.000581311678161

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 2786.59202803
delta logL = -2.8721842682e-08

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10262E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.3202       1.0000          .0000       10.000    
     3 'Normalizat'    .39570       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.1538       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5490E+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=   2786.592     FROM MIGRAD    STATUS=FAILED        92 CALLS      246 TOTAL
                     EDM=   .69E-06    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10724E-03    32.332        .15024E-01** at limit **
   2  Index         1.7828        8.0354        .50000        .46743E-05
   3  Normalizat    .39573        .11718E-01    .42508E-03   -.29032E-04
   4  Prefactor     1.1538        .77325E-02    .16848E-03    .99867E-05
                               ERR DEF=  .500    
 START SIMPLEX MINIMIZATION.    CONVERGENCE WHEN EDM .LT.   .20E-04
 SIMPLEX MINIMIZATION HAS CONVERGED.

 FCN=   2786.592     FROM SIMPLEX   STATUS=UNCHANGED    105 CALLS      351 TOTAL
                     EDM=   .13E-04    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10724E-03    32.332        .57150E-03** at limit **
   2  Index         1.7828        8.0354        .28514E-02    .46743E-05
   3  Normalizat    .39573        .11718E-01    .16432E-04   -.29032E-04
   4  Prefactor     1.1538        .77325E-02    .84690E-05    .99867E-05
                               ERR DEF=  .500    

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   2786.592     FROM MIGRAD    STATUS=CONVERGED     82 CALLS      433 TOTAL
                     EDM=   .11E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    1790.3        .35487E-03** at limit **
   2  Index         1.6490        8.5884        .50000       -.11119E-07
   3  Normalizat    .39573        .11704        .34006E-05    .28082E-04
   4  Prefactor     1.1538        .77252E-01    .13478E-05    .11556E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Index      = 1.64904
  Normalizat = 0.395731
  Prefactor  = 1.15381
 **********
 **   18 **HESSE 
 **********

 FCN=   2786.592     FROM HESSE     STATUS=OK            29 CALLS      462 TOTAL
                     EDM=   .18E-10    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    14.852        .70973E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         1.6490        8.7941        .50000       -.73447    
   3  Normalizat    .39573        .30259        .68013E-06   -1.1752    
   4  Prefactor     1.1538        .19977        .26957E-06   -.87765    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.78926e-11
Minuit parameter uncertainties:
  1  2.96926e-06
  2  250.004
  3  0.303855
  4  0.199902
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/28201': 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) = 2786.59202599
delta logL = 2.00783642867e-06

Extracting fit parameters...

4FGL J0058.4+3315
   Spectrum: PowerLaw
189    Prefactor:  1.000e-04  2.969e-06  1.000e-04  1.000e+04 ( 1.000e-13)
190        Index:  1.649e+00  2.500e+02  0.000e+00  1.000e+01 (-1.000e+00)
191        Scale:  1.298e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
546    Prefactor:  1.154e+00  1.999e-01  0.000e+00  1.000e+01 ( 1.000e+00)
547        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
548        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
545   Normalization:  3.957e-01  3.039e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 14.610 33.251

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/28201/cmap_HighResolution_590976001_591580801_4FGL_J0058.4+3315_weekly_bin582.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='9.29e-03', job_status='DONE', photon_flux_upper_limit='1.21e-07', time_completed='2021-07-03 13:49:10.413880', job_id='28201', GAL2='1.15', fit_tolerance='1e-08', EG2='0.40', EG='0.40', time_epoch_completed='1625345350.41', return_code2='0', ts='-0.00', comment='SUCCESS', return_code='0', GAL='1.15', dlogl='2.01e-06', ts2='-0.00', photon_index_error='0.00', photon_index='2.34' WHERE bin_id='582' AND source_name='4FGL J0058.4+3315' AND cadence='weekly';

Database successfully updated.


Analysis Complete.


Sat Jul  3 13:49:10 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0209>
Subject: Job 28201: <4FGL_J0058.4+3315_weekly_bin582> in cluster <slac> Done

Job <4FGL_J0058.4+3315_weekly_bin582> was submitted from host <rhel6-64l> by user <kocevski> in cluster <slac> at Sat Jul  3 13:37:14 2021
Job was executed on host(s) <bullet0209>, in queue <medium>, as user <kocevski> in cluster <slac> at Sat Jul  3 13:37:15 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sat Jul  3 13:37:15 2021
Terminated at Sat Jul  3 13:49:11 2021
Results reported at Sat Jul  3 13:49:11 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J0058.4+3315_weekly_bin582 14.6101 33.2505 590976001 591580801 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J0058.4+3315 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   527.00 sec.
    Max Memory :                                 1095 MB
    Average Memory :                             280.15 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   715 sec.
    Turnaround time :                            717 sec.

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

