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


Performing analysis on: 4FGL_J0159.0+3313_daily_bin1306
RA = 29.7665, Dec = 33.2175
tmin = 577843201, tmax = 578102401
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='981826', job_status='RUN', time_executed='2021-08-14 23:53:35.468124', time_epoch_executed='1629010415.47' WHERE source_name='4FGL J0159.0+3313' and cadence='daily' and bin_id='1306'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/981826

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/981826/ft1_4FGL_J0159.0+3313_daily_bin1306.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/981826/ft2_4FGL_J0159.0+3313_daily_bin1306.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/981826/ft1_4FGL_J0159.0+3313_daily_bin1306.fits outfile=/scratch/kocevski/981826/ft1_filteredMKT_4FGL_J0159.0+3313_daily_bin1306.fits ra=29.7665 dec=33.2175 rad=12.0 tmin=577843201.0 tmax=578102401.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 13.57
user 3.09
sys 10.29

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/981826/ft2_4FGL_J0159.0+3313_daily_bin1306.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/981826/ft2_4FGL_J0159.0+3313_daily_bin1306.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/981826/ft1_filteredMKT_4FGL_J0159.0+3313_daily_bin1306.fits evtable="EVENTS" outfile="/scratch/kocevski/981826/ft1_filtered_4FGL_J0159.0+3313_daily_bin1306.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 13.28
user 0.35
sys 12.68

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/981826/ft1_filtered_4FGL_J0159.0+3313_daily_bin1306.fits" evtable="EVENTS" scfile=/scratch/kocevski/981826/ft2_4FGL_J0159.0+3313_daily_bin1306.fits sctable="SC_DATA" outfile=/scratch/kocevski/981826/ltcube_577843201_578102401_4FGL_J0159.0+3313_daily_bin1306.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/981826/ft2_4FGL_J0159.0+3313_daily_bin1306.fits
.....................!
real 27.36
user 15.26
sys 11.57

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/981826/ft1_filtered_4FGL_J0159.0+3313_daily_bin1306.fits evtable="EVENTS" scfile=/scratch/kocevski/981826/ft2_4FGL_J0159.0+3313_daily_bin1306.fits sctable="SC_DATA" expcube=/scratch/kocevski/981826/ltcube_577843201_578102401_4FGL_J0159.0+3313_daily_bin1306.fits outfile=/scratch/kocevski/981826/expmap_577843201_578102401_4FGL_J0159.0+3313_daily_bin1306.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/981826/ltcube_577843201_578102401_4FGL_J0159.0+3313_daily_bin1306.fits
.....................!
real 205.74
user 186.52
sys 17.49

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

Setting source of interest to:
4FGL J0159.0+3313 @ 29.7665 33.2175

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/981826/ft1_filtered_4FGL_J0159.0+3313_daily_bin1306.fits scfile=/scratch/kocevski/981826/ft2_4FGL_J0159.0+3313_daily_bin1306.fits outfile=/scratch/kocevski/981826/cmap_577843201_578102401_4FGL_J0159.0+3313_daily_bin1306.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.7665 yref=33.2175 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 11.39
user 0.40
sys 9.99

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/981826/ft1_filtered_4FGL_J0159.0+3313_daily_bin1306.fits scfile=/scratch/kocevski/981826/ft2_4FGL_J0159.0+3313_daily_bin1306.fits outfile=/scratch/kocevski/981826/cmap_HighResolution_577843201_578102401_4FGL_J0159.0+3313_daily_bin1306.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.7665 yref=33.2175 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 10.55
user 0.39
sys 10.09

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/981826/ft1_filtered_4FGL_J0159.0+3313_daily_bin1306.fits evtable="EVENTS" scfile=/scratch/kocevski/981826/ft2_4FGL_J0159.0+3313_daily_bin1306.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/981826/Model_4FGL_J0159.0+3313_daily_bin1306.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/981826/ft1_filtered_4FGL_J0159.0+3313_daily_bin1306.fits.....................!
real 52.25
user 37.87
sys 14.08

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/981826/ft1_filtered_4FGL_J0159.0+3313_daily_bin1306.fits', '/scratch/kocevski/981826/ft2_4FGL_J0159.0+3313_daily_bin1306.fits', expMap='/scratch/kocevski/981826/expmap_577843201_578102401_4FGL_J0159.0+3313_daily_bin1306.fits', expCube='/scratch/kocevski/981826/ltcube_577843201_578102401_4FGL_J0159.0+3313_daily_bin1306.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/981826/Model_4FGL_J0159.0+3313_daily_bin1306.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J0159.0+3313'

4FGL J0159.0+3313
   Spectrum: PowerLaw
265    Prefactor:  1.345e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-14)
266        Index:  1.985e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
267        Scale:  3.553e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/981826/ft1_filtered_4FGL_J0159.0+3313_daily_bin1306.fits
Spacecraft file(s): /scratch/kocevski/981826/ft2_4FGL_J0159.0+3313_daily_bin1306.fits
Exposure map: /scratch/kocevski/981826/expmap_577843201_578102401_4FGL_J0159.0+3313_daily_bin1306.fits
Exposure cube: /scratch/kocevski/981826/ltcube_577843201_578102401_4FGL_J0159.0+3313_daily_bin1306.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/981826/Model_4FGL_J0159.0+3313_daily_bin1306.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) = 2820.13992559

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    .57436       1.0000         .10000E-03   10000.    
     2 'Prefactor '    55.196       1.0000         .10000E-03   10000.    
     3 'Prefactor '    .16023E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .64070E-02   1.0000         .10000E-03   10000.    
     5 'norm      '    .10100E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    88.123       1.0000         .10000E-03   10000.    
     7 'Prefactor '    1.9117       1.0000         .10000E-03   10000.    
     8 'norm      '    1.4775       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .32202E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    16.775       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .25768E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    66.817       1.0000         .10000E-03   10000.    
    13 'Prefactor '    .13059E-02   1.0000         .10000E-03   10000.    
    14 'norm      '    .59302       1.0000         .10000E-03   10000.    
    15 'Prefactor '    4.0353       1.0000         .10000E-03   10000.    
    16 'Prefactor '    .32642       1.0000         .10000E-03   10000.    
    17 'Prefactor '    6.6750       1.0000         .10000E-03   10000.    
    18 'norm      '    .17326E-02   1.0000         .10000E-03   10000.    
    19 'Prefactor '    10.039       1.0000         .10000E-03   10000.    
    20 'norm      '    2.4042       1.0000         .10000E-03   10000.    
    21 'norm      '    .50864E-01   1.0000         .10000E-03   10000.    
    22 'norm      '    .46314       1.0000         .10000E-03   10000.    
    23 'Prefactor '    17.876       1.0000         .10000E-03   10000.    
    24 'norm      '    .29929E-02   1.0000         .10000E-03   10000.    
    25 'Prefactor '    .50604E-03   1.0000         .10000E-03   10000.    
    26 'norm      '    12.098       1.0000         .10000E-03   10000.    
    27 'Prefactor '    4.4967       1.0000         .10000E-03   10000.    
    28 'Normalizat'    .28456       1.0000         .10000E-01   10.000    
    29 'Prefactor '    1.4627       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5940E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   2820.085     FROM MIGRAD    STATUS=CONVERGED    854 CALLS     3298 TOTAL
                     EDM=   .17E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  4.6%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .57576        2.9527        .84176E-06   -.17614E-04
   2  Prefactor     58.385        84.254        .40987E-06    .21910E-05
   3  Prefactor     .10000E-03    20.299        .28599E-06** at limit **
   4  Prefactor     .10000E-03    74.029       -.31232E-06** at limit **
   5  norm          .10000E-03    1.5656        .33947E-07** at limit **
   6  Prefactor     92.486        88.009       -.55774E-05   -.42880E-05
   7  Prefactor     .10000E-03    248.99       -.53389E-06** at limit **
   8  norm          1.4801        1.4613        .83016E-07    .44527E-04
   9  Prefactor     .10000E-03    9.4264       -.40027E-07** at limit **
  10  Prefactor     17.204        29.342        .69927E-06   -.16392E-04
  11  Prefactor     .10000E-03    6.3127        .36592E-07** at limit **
  12  Prefactor     70.622        77.528       -.46562E-05   -.10009E-03
  13  Prefactor     .10000E-03    27.535        .16135E-07** at limit **
  14  norm          .57013        15.201        .75720E-07   -.12297E-03
  15  Prefactor     .10000E-03    727.73       -.39481E-05** at limit **
  16  Prefactor     .10482E-03    21.838        .51729E-05** at limit **
  17  Prefactor     6.6880        10.860        .19335E-06   -.19667E-05
  18  norm          .10000E-03    7.1292        .44094E-07** at limit **
  19  Prefactor     10.465        17.476       -.10337E-05   -.42988E-04
  20  norm          2.4025        1.2969       -.71763E-08   -.15438E-03
  21  norm          .10000E-03    131.05        .11691E-06** at limit **
  22  norm          .46324        .49982        .49911E-07    .13928E-03
  23  Prefactor     17.902        11.026        .46363E-06    .14083E-04
  24  norm          .10000E-03    12.944       -.20438E-07** at limit **
  25  Prefactor     .10000E-03    39.035       -.45308E-07** at limit **
  26  norm          12.049        5.0758        .13048E-06   -.41822E-04
  27  Prefactor     .10000E-03    757.94        .91470E-06** at limit **
  28  Normalizat    .27811        .45867       -.17109E-04   -.26297E-04
  29  Prefactor     1.4652        .25078        .25450E-05   -.53283E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 0.575755
  Prefactor  = 58.3848
  Prefactor  = 0.0001
  Prefactor  = 0.000100001
  norm       = 0.0001
  Prefactor  = 92.4856
  Prefactor  = 0.0001
  norm       = 1.48011
  Prefactor  = 0.0001
  Prefactor  = 17.2042
  Prefactor  = 0.0001
  Prefactor  = 70.6223
  Prefactor  = 0.0001
  norm       = 0.570133
  Prefactor  = 0.0001
  Prefactor  = 0.000104822
  Prefactor  = 6.68801
  norm       = 0.0001
  Prefactor  = 10.4653
  norm       = 2.40246
  norm       = 0.0001
  norm       = 0.463245
  Prefactor  = 17.9021
  norm       = 0.0001
  Prefactor  = 0.0001
  norm       = 12.0485
  Prefactor  = 0.0001
  Normalizat = 0.278112
  Prefactor  = 1.46516
 **********
 **   18 **HESSE 
 **********

 FCN=   2820.085     FROM HESSE     STATUS=OK           565 CALLS     3863 TOTAL
                     EDM=   .53E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          .57576        2.9880        .17217E-03   -1.5556    
   2  Prefactor     58.385        84.229        .53992E-04   -1.4178    
   3  Prefactor     .10000E-03    20.573        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    75.014        .18840E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  norm          .10000E-03    2.6567        .12946E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     92.486        87.910        .21400E-03   -1.3782    
   7  Prefactor     .10000E-03    249.26        .15033E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          1.4801        1.4546        .61371E-04   -1.5465    
   9  Prefactor     .10000E-03    9.4355        .15926E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     17.204        29.277        .97788E-04   -1.4878    
  11  Prefactor     .10000E-03    6.5436        .25965E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     70.622        92.810        .24550E-03   -1.4025    
  13  Prefactor     .10000E-03    27.538        .20576E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          .57013        15.761        .39187E-02   -1.5557    
  15  Prefactor     .10000E-03    727.83        .10037E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     .10482E-03    56.379        .62275E-01   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  Prefactor     6.6880        10.858        .15531E-03   -1.5191    
  18  norm          .10000E-03    7.2466        .27486E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     10.465        17.584        .12646E-03   -1.5061    
  20  norm          2.4025        1.2847        .41498E-04   -1.5398    
  21  norm          .10000E-03    131.07        .18549E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  norm          .46324        .48255        .37530E-03   -1.5572    
  23  Prefactor     17.902        10.987        .94729E-04   -1.4861    
  24  norm          .10000E-03    13.238        .37183E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     .10000E-03    39.080        .21151E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  norm          12.049        5.0867        .36964E-03   -1.5014    
  27  Prefactor     .10000E-03    760.17        .94934E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  Normalizat    .27811        .46352        .68295E-03   -1.2417    
  29  Prefactor     1.4652        .25196        .18417E-03   -.78520    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 5.32911e-08
Minuit parameter uncertainties:
  1  2.62322
  2  84.402
  3  6.88829e-05
  4  0.000490801
  5  1.79306e-05
  6  88.0336
  7  0.000522034
  8  1.45468
  9  1.53906e-05
  10  29.3017
  11  5.83883e-05
  12  93.001
  13  1.13565e-05
  14  5.99647
  15  0.000186444
  16  0.0330076
  17  10.8615
  18  5.68362e-05
  19  17.5925
  20  1.28471
  21  1.49749e-05
  22  0.482556
  23  10.9883
  24  3.5624e-05
  25  3.90803e-05
  26  5.08692
  27  0.00100045
  28  0.470134
  29  0.252172
Done.

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

Extracting fit parameters...

4FGL J0159.0+3313
   Spectrum: PowerLaw
265    Prefactor:  7.062e+01  9.300e+01  1.000e-04  1.000e+04 ( 1.000e-14)
266        Index:  1.985e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
267        Scale:  3.553e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
591    Prefactor:  1.465e+00  2.522e-01  0.000e+00  1.000e+01 ( 1.000e+00)
592        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
593        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
590   Normalization:  2.781e-01  4.701e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 1.17
Ra Dec: 29.767 33.218
Photon Index (Fixed Index): 1.98 +/- 0.00
Photon Flux (Fixed Index): 8.57e-08 +/- 1.13e-07
Energy Flux (Fixed Index): 6.15e-05 +/- 8.10e-05

TS (Fixed Index): 1.17
Ra Dec: 29.767 33.218
Photon Flux Upper Limit: 2.89e-07 ph cm-2 s-1
Energy Flux Upper Limit: 2.16e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/981826/likelihoodResults_577843201_578102401_4FGL_J0159.0+3313_daily_bin1306.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) = 2818.46556491
delta logL = 1.6195645475

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 2818.44131445
delta logL = 1.64381501255

Fit tolerance = 1e-08

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

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

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   2818.441     FROM MIGRAD    STATUS=CONVERGED     64 CALLS      295 TOTAL
                     EDM=   .12E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     2.3198        25.526        .67475E-02    .97536E-03
   2  Index         3.5090        1.9498        .42738E-01    .31887E-03
   3  Normalizat    .24626E-01    .10258        .32454        .24232E-04
   4  Prefactor     1.5589        .95341E-01    .29207E-01   -.84409E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 2.31984
  Index      = 3.50903
  Normalizat = 0.0246255
  Prefactor  = 1.55889
 **********
 **   18 **HESSE 
 **********

 FCN=   2818.441     FROM HESSE     STATUS=NOT POSDEF    35 CALLS      330 TOTAL
                     EDM=   .28E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     2.3198        34.444        .43936E-04   -1.5403    
   2  Index         3.5090        2.3617        .18219E-02   -.30280    
   3  Normalizat    .24626E-01    7.3605        .12971E-01   -1.4943    
   4  Prefactor     1.5589        .34620        .17909E-03   -.75903    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 2.76414e-10
Minuit parameter uncertainties:
  1  17.89
  2  2.47054
  3  0.61015
  4  0.346731
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/981826': 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) = 2818.44118667
delta logL = 1.64394279151

Extracting fit parameters...

4FGL J0159.0+3313
   Spectrum: PowerLaw
265    Prefactor:  2.320e+00  1.789e+01  1.000e-04  1.000e+04 ( 1.000e-14)
266        Index:  3.509e+00  2.471e+00  0.000e+00  1.000e+01 (-1.000e+00)
267        Scale:  3.553e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
591    Prefactor:  1.559e+00  3.467e-01  0.000e+00  1.000e+01 ( 1.000e+00)
592        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
593        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
590   Normalization:  2.463e-02  6.102e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 5.14
Ra Dec: 29.767 33.218
Photon Index (Free Index): 3.51 +/- 2.47
Photon Flux (Free Index): 2.56e-07 +/- 1.64e-07
Energy Flux (Free Index): 4.25e-05 +/- 3.40e-05

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/981826/cmap_HighResolution_577843201_578102401_4FGL_J0159.0+3313_daily_bin1306.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='2.16e-02', comment='SUCCESS', photon_flux='8.57e-08', energy_flux2='4.25e-05', photon_flux_error='1.13e-07', dlogl='1.64e+00', energy_flux='6.15e-05', photon_flux2='2.56e-07', job_status='DONE', time_completed='2021-08-15 00:05:27.323452', photon_index_error2='2.47', photon_index2='3.51', ts='1.17', fit_tolerance='1e-08', GAL='1.47', photon_index_error='0.00', photon_flux_upper_limit='2.89e-07', energy_flux_error2='3.40e-05', EG='0.28', time_epoch_completed='1629011127.32', return_code='0', job_id='981826', GAL2='1.56', EG2='0.02', return_code2='102', energy_flux_error='8.10e-05', photon_flux_error2='1.64e-07', ts2='5.14', photon_index='1.98' WHERE bin_id='1306' AND source_name='4FGL J0159.0+3313' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sun Aug 15 00:05:27 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0210>
Subject: Job 981826: <4FGL_J0159.0+3313_daily_bin1306> in cluster <slac> Done

Job <4FGL_J0159.0+3313_daily_bin1306> was submitted from host <rhel6-64f> by user <kocevski> in cluster <slac> at Sat Aug 14 23:50:17 2021
Job was executed on host(s) <bullet0210>, in queue <medium>, as user <kocevski> in cluster <slac> at Sat Aug 14 23:50:26 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sat Aug 14 23:50:26 2021
Terminated at Sun Aug 15 00:05:29 2021
Results reported at Sun Aug 15 00:05:29 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J0159.0+3313_daily_bin1306 29.7665 33.2175 577843201 578102401 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J0159.0+3313 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   855.00 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             248.17 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   902 sec.
    Turnaround time :                            912 sec.

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

