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


Performing analysis on: 4FGL_J0159.5+1046_weekly_bin574
RA = 29.8858, Dec = 10.7737
tmin = 586137601, tmax = 586742401
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='321277', job_status='RUN', time_executed='2021-07-04 12:55:50.728526', time_epoch_executed='1625428550.73' WHERE source_name='4FGL J0159.5+1046' and cadence='weekly' and bin_id='574'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/321277

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

Retrieving the FT1 file...

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

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

Retrieving 87 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/321277/ft1_4FGL_J0159.5+1046_weekly_bin574.fits


Retrieving the FT1 file...

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

Retrieving 87 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/321277/ft2_4FGL_J0159.5+1046_weekly_bin574.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/321277/ft1_4FGL_J0159.5+1046_weekly_bin574.fits outfile=/scratch/kocevski/321277/ft1_filteredMKT_4FGL_J0159.5+1046_weekly_bin574.fits ra=29.8858 dec=10.7737 rad=12.0 tmin=586137601.0 tmax=586742401.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.89
user 7.30
sys 0.44

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/321277/ft2_4FGL_J0159.5+1046_weekly_bin574.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/321277/ft2_4FGL_J0159.5+1046_weekly_bin574.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/321277/ft1_filteredMKT_4FGL_J0159.5+1046_weekly_bin574.fits evtable="EVENTS" outfile="/scratch/kocevski/321277/ft1_filtered_4FGL_J0159.5+1046_weekly_bin574.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.87
user 0.36
sys 0.26

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/321277/ft1_filtered_4FGL_J0159.5+1046_weekly_bin574.fits" evtable="EVENTS" scfile=/scratch/kocevski/321277/ft2_4FGL_J0159.5+1046_weekly_bin574.fits sctable="SC_DATA" outfile=/scratch/kocevski/321277/ltcube_586137601_586742401_4FGL_J0159.5+1046_weekly_bin574.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/321277/ft2_4FGL_J0159.5+1046_weekly_bin574.fits
.....................!
real 21.50
user 20.82
sys 0.44

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/321277/ft1_filtered_4FGL_J0159.5+1046_weekly_bin574.fits evtable="EVENTS" scfile=/scratch/kocevski/321277/ft2_4FGL_J0159.5+1046_weekly_bin574.fits sctable="SC_DATA" expcube=/scratch/kocevski/321277/ltcube_586137601_586742401_4FGL_J0159.5+1046_weekly_bin574.fits outfile=/scratch/kocevski/321277/expmap_586137601_586742401_4FGL_J0159.5+1046_weekly_bin574.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/321277/ltcube_586137601_586742401_4FGL_J0159.5+1046_weekly_bin574.fits
.....................!
real 191.58
user 185.18
sys 4.81

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 J0159.5+1046 @ 29.8858 10.7737

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/321277/ft1_filtered_4FGL_J0159.5+1046_weekly_bin574.fits scfile=/scratch/kocevski/321277/ft2_4FGL_J0159.5+1046_weekly_bin574.fits outfile=/scratch/kocevski/321277/cmap_586137601_586742401_4FGL_J0159.5+1046_weekly_bin574.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=29.8858 yref=10.7737 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.68
user 0.38
sys 0.27

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/321277/ft1_filtered_4FGL_J0159.5+1046_weekly_bin574.fits scfile=/scratch/kocevski/321277/ft2_4FGL_J0159.5+1046_weekly_bin574.fits outfile=/scratch/kocevski/321277/cmap_HighResolution_586137601_586742401_4FGL_J0159.5+1046_weekly_bin574.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=29.8858 yref=10.7737 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.68
user 0.40
sys 0.26

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/321277/ft1_filtered_4FGL_J0159.5+1046_weekly_bin574.fits evtable="EVENTS" scfile=/scratch/kocevski/321277/ft2_4FGL_J0159.5+1046_weekly_bin574.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/321277/Model_4FGL_J0159.5+1046_weekly_bin574.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/321277/ft1_filtered_4FGL_J0159.5+1046_weekly_bin574.fits.....................!
real 132.90
user 130.87
sys 1.39

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/321277/ft1_filtered_4FGL_J0159.5+1046_weekly_bin574.fits', '/scratch/kocevski/321277/ft2_4FGL_J0159.5+1046_weekly_bin574.fits', expMap='/scratch/kocevski/321277/expmap_586137601_586742401_4FGL_J0159.5+1046_weekly_bin574.fits', expCube='/scratch/kocevski/321277/ltcube_586137601_586742401_4FGL_J0159.5+1046_weekly_bin574.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/321277/Model_4FGL_J0159.5+1046_weekly_bin574.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J0159.5+1046'

4FGL J0159.5+1046
   Spectrum: PowerLaw
219    Prefactor:  2.134e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
220        Index:  1.995e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
221        Scale:  2.167e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/321277/ft1_filtered_4FGL_J0159.5+1046_weekly_bin574.fits
Spacecraft file(s): /scratch/kocevski/321277/ft2_4FGL_J0159.5+1046_weekly_bin574.fits
Exposure map: /scratch/kocevski/321277/expmap_586137601_586742401_4FGL_J0159.5+1046_weekly_bin574.fits
Exposure cube: /scratch/kocevski/321277/ltcube_586137601_586742401_4FGL_J0159.5+1046_weekly_bin574.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/321277/Model_4FGL_J0159.5+1046_weekly_bin574.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) = 12513.221503

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    11.777       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .36654E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     5 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    1.8736       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10007E-03   1.0000         .10000E-03   10000.    
     8 'norm      '    24.835       1.0000         .10000E-03   10000.    
     9 'Prefactor '    2.6782       1.0000         .10000E-03   10000.    
    10 'norm      '    2.4344       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10006E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10908E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    25.824       1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10022E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    1.6056       1.0000         .10000E-03   10000.    
    17 'Prefactor '    .12167E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    19 'norm      '    .31965       1.0000         .10000E-03   10000.    
    20 'Prefactor '    9.9014       1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10071E-03   1.0000         .10000E-03   10000.    
    22 'norm      '    8.6007       1.0000         .10000E-03   10000.    
    23 'Prefactor '    12.896       1.0000         .10000E-03   10000.    
    24 'Normalizat'    .99008       1.0000         .10000E-01   10.000    
    25 'Prefactor '    1.0159       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5380E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   12513.20     FROM MIGRAD    STATUS=CONVERGED    593 CALLS     2955 TOTAL
                     EDM=   .62E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  5.8%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     11.777        7.7171        .56595E-07    .66376E-05
   2  Prefactor     .10000E-03    8.3100        .25490E-06** at limit **
   3  Prefactor     .10001E-03    17.994       -.21086E-05** at limit **
   4  Prefactor     .10000E-03    1.6334       -.54386E-07** at limit **
   5  norm          .10000E-03    8.2921        .38452E-06** at limit **
   6  Prefactor     1.8735        3.9082        .91487E-06   -.32064E-03
   7  Prefactor     .10000E-03    1.0081       -.15631E-06** at limit **
   8  norm          24.835        5.3819       -.20127E-07   -.33277E-03
   9  Prefactor     2.6781        1.7604       -.20487E-06   -.70504E-03
  10  norm          2.4343        .78666       -.22484E-07   -.36002E-03
  11  Prefactor     .10000E-03    13.182       -.24212E-05** at limit **
  12  Prefactor     .10000E-03    7.1445       -.11312E-05** at limit **
  13  Prefactor     .10001E-03    3.0666        .88821E-06** at limit **
  14  Prefactor     25.827        25.883       -.24454E-06   -.76247E-04
  15  Prefactor     .10000E-03    4.8135        .14812E-05** at limit **
  16  Prefactor     1.6052        9.5179       -.82115E-06   -.23537E-03
  17  Prefactor     .10001E-03    4.2059        .10396E-06** at limit **
  18  Prefactor     .10000E-03    3.4219        .52253E-06** at limit **
  19  norm          .31961        .24836        .39419E-07    .13351E-03
  20  Prefactor     9.8082        30.804       -.12574E-05   -.73659E-04
  21  Prefactor     .10000E-03    31.748       -.21280E-05** at limit **
  22  norm          8.6056        8.9735        .43980E-07   -.20245E-03
  23  Prefactor     12.851        30.493        .17102E-05   -.27773E-04
  24  Normalizat    .99005        .13917        .35803E-06   -.37751E-03
  25  Prefactor     1.0159        .88687E-01   -.64607E-06   -.64846E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 11.7765
  Prefactor  = 0.0001
  Prefactor  = 0.000100012
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 1.87353
  Prefactor  = 0.0001
  norm       = 24.8347
  Prefactor  = 2.67811
  norm       = 2.4343
  Prefactor  = 0.000100001
  Prefactor  = 0.0001
  Prefactor  = 0.000100011
  Prefactor  = 25.8272
  Prefactor  = 0.0001
  Prefactor  = 1.60523
  Prefactor  = 0.000100012
  Prefactor  = 0.0001
  norm       = 0.319613
  Prefactor  = 9.80821
  Prefactor  = 0.000100001
  norm       = 8.60563
  Prefactor  = 12.8509
  Normalizat = 0.990051
  Prefactor  = 1.01591
 **********
 **   18 **HESSE 
 **********

 FCN=   12513.20     FROM HESSE     STATUS=OK           429 CALLS     3384 TOTAL
                     EDM=   .35E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     11.777        7.7176        .11673E-03   -1.5021    
   2  Prefactor     .10000E-03    8.3147        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10001E-03    25.974        .36980E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    1.6471        .13957E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  norm          .10000E-03    8.4221        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     1.8735        5.4345        .15212E-02   -1.5434    
   7  Prefactor     .10000E-03    1.0466        .21884E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          24.835        5.3945        .80381E-04   -1.4711    
   9  Prefactor     2.6781        1.7539        .11490E-03   -1.5381    
  10  norm          2.4343        .78545        .54281E-04   -1.5396    
  11  Prefactor     .10000E-03    13.312        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10000E-03    7.2045        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     .10001E-03    6.7964        .30883E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     25.827        25.862        .78830E-04   -1.4691    
  15  Prefactor     .10000E-03    4.9704        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     1.6052        12.885        .16722E-02   -1.5455    
  17  Prefactor     .10001E-03    13.688        .34158E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .10000E-03    3.4557        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  norm          .31961        .23341        .47575E-03   -1.5595    
  20  Prefactor     9.8082        30.982        .12735E-03   -1.5082    
  21  Prefactor     .10000E-03    32.148        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  norm          8.6056        8.8377        .13668E-03   -1.5121    
  23  Prefactor     12.851        30.383        .11154E-03   -1.4991    
  24  Normalizat    .99005        .15785        .30383E-03   -.93364    
  25  Prefactor     1.0159        .10120        .19056E-03   -.92201    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 3.52737e-09
Minuit parameter uncertainties:
  1  7.71825
  2  2.06141e-05
  3  0.00111109
  4  1.31888e-06
  5  3.09493e-05
  6  5.43591
  7  3.18414e-06
  8  5.39464
  9  1.75395
  10  0.785457
  11  0.000215214
  12  8.20878e-05
  13  0.000542763
  14  25.8732
  15  6.30581e-05
  16  9.09804
  17  0.000827331
  18  2.03061e-05
  19  0.233407
  20  31.0333
  21  0.000261903
  22  8.83908
  23  30.4195
  24  0.157927
  25  0.101221
Done.

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

Extracting fit parameters...

4FGL J0159.5+1046
   Spectrum: PowerLaw
219    Prefactor:  1.874e+00  5.436e+00  1.000e-04  1.000e+04 ( 1.000e-13)
220        Index:  1.995e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
221        Scale:  2.167e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
535    Prefactor:  1.016e+00  1.012e-01  0.000e+00  1.000e+01 ( 1.000e+00)
536        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
537        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
534   Normalization:  9.901e-01  1.579e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.13
Ra Dec: 29.886 10.774
Photon Flux Upper Limit: 6.62e-08 ph cm-2 s-1
Energy Flux Upper Limit: 4.96e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/321277/likelihoodResults_586137601_586742401_4FGL_J0159.5+1046_weekly_bin574.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) = 12511.4606874
delta logL = 1.74123136524

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 12511.3961654
delta logL = 1.80575342509

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .58913       1.0000         .10000E-03   10000.    
     2 'Index     '    3.3957       1.0000          .0000       10.000    
     3 'Normalizat'    .91536       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.0370       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5380E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   12511.40     FROM MIGRAD    STATUS=CONVERGED     57 CALLS      264 TOTAL
                     EDM=   .23E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .58710        3.4607        .10351E-01    .21271E-02
   2  Index         3.3971        1.4775        .80697E-01    .39863E-03
   3  Normalizat    .91552        .35480E-01    .70954E-01    .19106E-04
   4  Prefactor     1.0368        .22545E-01    .40742E-01   -.11739E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.5871
  Index      = 3.39712
  Normalizat = 0.915515
  Prefactor  = 1.03682
 **********
 **   18 **HESSE 
 **********

 FCN=   12511.40     FROM HESSE     STATUS=NOT POSDEF    33 CALLS      297 TOTAL
                     EDM=   .12E-05    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .58710        8.8870        .46808E-04   -1.5555    
   2  Index         3.3971        2.7686        .39900E-02   -.32634    
   3  Normalizat    .91552        .14980        .31394E-03   -.95917    
   4  Prefactor     1.0368        .94927E-01    .18859E-03   -.91512    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 1.21902e-06
Minuit parameter uncertainties:
  1  4.56882
  2  2.95705
  3  0.149863
  4  0.0949421
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/321277': 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) = 12511.3961627
delta logL = 1.80575606971

Extracting fit parameters...

4FGL J0159.5+1046
   Spectrum: PowerLaw
219    Prefactor:  5.871e-01  4.569e+00  1.000e-04  1.000e+04 ( 1.000e-13)
220        Index:  3.397e+00  2.957e+00  0.000e+00  1.000e+01 (-1.000e+00)
221        Scale:  2.167e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
535    Prefactor:  1.037e+00  9.494e-02  0.000e+00  1.000e+01 ( 1.000e+00)
536        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
537        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
534   Normalization:  9.155e-01  1.499e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 3.91
Ra Dec: 29.886 10.774
Photon Index (Free Index): 3.40 +/- 2.96
Photon Flux (Free Index): 8.47e-08 +/- 4.80e-08
Energy Flux (Free Index): 1.45e-05 +/- 1.39e-05

Creating a high resolution counts map...
INFO: Auto-setting vmin to -1.000e-01 [aplpy.core]
INFO: Auto-setting vmax to  1.110e+00 [aplpy.core]
Saving /scratch/kocevski/321277/cmap_HighResolution_586137601_586742401_4FGL_J0159.5+1046_weekly_bin574.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='4.96e-03', comment='SUCCESS', energy_flux2='1.45e-05', dlogl='1.81e+00', photon_flux2='8.47e-08', job_status='DONE', time_completed='2021-07-04 13:16:14.523856', photon_index_error2='2.96', photon_index2='3.40', ts='0.13', fit_tolerance='1e-08', GAL='1.02', photon_index_error='0.00', photon_flux_upper_limit='6.62e-08', energy_flux_error2='1.39e-05', EG='0.99', time_epoch_completed='1625429774.52', return_code='0', job_id='321277', GAL2='1.04', EG2='0.92', return_code2='102', photon_flux_error2='4.80e-08', ts2='3.91', photon_index='1.99' WHERE bin_id='574' AND source_name='4FGL J0159.5+1046' AND cadence='weekly';

Database successfully updated.


Analysis Complete.


Sun Jul  4 13:16:14 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0074>
Subject: Job 321277: <4FGL_J0159.5+1046_weekly_bin574> in cluster <slac> Done

Job <4FGL_J0159.5+1046_weekly_bin574> was submitted from host <rhel6-64q> by user <kocevski> in cluster <slac> at Sun Jul  4 05:59:37 2021
Job was executed on host(s) <bullet0074>, in queue <medium>, as user <kocevski> in cluster <slac> at Sun Jul  4 05:59:38 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sun Jul  4 05:59:38 2021
Terminated at Sun Jul  4 13:16:18 2021
Results reported at Sun Jul  4 13:16:18 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J0159.5+1046_weekly_bin574 29.8858 10.7737 586137601 586742401 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J0159.5+1046 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   1178.00 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             62.49 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   26197 sec.
    Turnaround time :                            26201 sec.

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

