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


Performing analysis on: 4FGL_J0159.5+1046_daily_bin1597
RA = 29.8858, Dec = 10.7737
tmin = 653270401, tmax = 653529601
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='534671', job_status='RUN', time_executed='2021-09-17 00:15:34.825284', time_epoch_executed='1631862934.83' WHERE source_name='4FGL J0159.5+1046' and cadence='daily' and bin_id='1597'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/534671

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/534671/ft1_4FGL_J0159.5+1046_daily_bin1597.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/534671/ft2_4FGL_J0159.5+1046_daily_bin1597.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/534671/ft1_4FGL_J0159.5+1046_daily_bin1597.fits outfile=/scratch/kocevski/534671/ft1_filteredMKT_4FGL_J0159.5+1046_daily_bin1597.fits ra=29.8858 dec=10.7737 rad=12.0 tmin=653270401.0 tmax=653529601.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.38
user 3.09
sys 0.21

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/534671/ft2_4FGL_J0159.5+1046_daily_bin1597.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/534671/ft1_filteredMKT_4FGL_J0159.5+1046_daily_bin1597.fits evtable="EVENTS" outfile="/scratch/kocevski/534671/ft1_filtered_4FGL_J0159.5+1046_daily_bin1597.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.50
user 0.34
sys 0.15

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/534671/ft1_filtered_4FGL_J0159.5+1046_daily_bin1597.fits" evtable="EVENTS" scfile=/scratch/kocevski/534671/ft2_4FGL_J0159.5+1046_daily_bin1597.fits sctable="SC_DATA" outfile=/scratch/kocevski/534671/ltcube_653270401_653529601_4FGL_J0159.5+1046_daily_bin1597.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/534671/ft2_4FGL_J0159.5+1046_daily_bin1597.fits
.....................!
real 12.81
user 12.46
sys 0.32

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/534671/ft1_filtered_4FGL_J0159.5+1046_daily_bin1597.fits evtable="EVENTS" scfile=/scratch/kocevski/534671/ft2_4FGL_J0159.5+1046_daily_bin1597.fits sctable="SC_DATA" expcube=/scratch/kocevski/534671/ltcube_653270401_653529601_4FGL_J0159.5+1046_daily_bin1597.fits outfile=/scratch/kocevski/534671/expmap_653270401_653529601_4FGL_J0159.5+1046_daily_bin1597.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/534671/ltcube_653270401_653529601_4FGL_J0159.5+1046_daily_bin1597.fits
.....................!
real 190.65
user 185.45
sys 4.83

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/534671/ft1_filtered_4FGL_J0159.5+1046_daily_bin1597.fits scfile=/scratch/kocevski/534671/ft2_4FGL_J0159.5+1046_daily_bin1597.fits outfile=/scratch/kocevski/534671/cmap_653270401_653529601_4FGL_J0159.5+1046_daily_bin1597.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.56
user 0.38
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/534671/ft1_filtered_4FGL_J0159.5+1046_daily_bin1597.fits scfile=/scratch/kocevski/534671/ft2_4FGL_J0159.5+1046_daily_bin1597.fits outfile=/scratch/kocevski/534671/cmap_HighResolution_653270401_653529601_4FGL_J0159.5+1046_daily_bin1597.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.55
user 0.38
sys 0.17

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

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/534671/ft1_filtered_4FGL_J0159.5+1046_daily_bin1597.fits', '/scratch/kocevski/534671/ft2_4FGL_J0159.5+1046_daily_bin1597.fits', expMap='/scratch/kocevski/534671/expmap_653270401_653529601_4FGL_J0159.5+1046_daily_bin1597.fits', expCube='/scratch/kocevski/534671/ltcube_653270401_653529601_4FGL_J0159.5+1046_daily_bin1597.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/534671/Model_4FGL_J0159.5+1046_daily_bin1597.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/534671/ft1_filtered_4FGL_J0159.5+1046_daily_bin1597.fits
Spacecraft file(s): /scratch/kocevski/534671/ft2_4FGL_J0159.5+1046_daily_bin1597.fits
Exposure map: /scratch/kocevski/534671/expmap_653270401_653529601_4FGL_J0159.5+1046_daily_bin1597.fits
Exposure cube: /scratch/kocevski/534671/ltcube_653270401_653529601_4FGL_J0159.5+1046_daily_bin1597.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/534671/Model_4FGL_J0159.5+1046_daily_bin1597.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) = 7525.59017983

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    13.697       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10073E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    9.0781       1.0000         .10000E-03   10000.    
     5 'norm      '    .10446E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    13.154       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     8 'norm      '    .10003E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    4.5580       1.0000         .10000E-03   10000.    
    10 'norm      '    3.6338       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .36195E-01   1.0000         .10000E-03   10000.    
    12 'Prefactor '    45.706       1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10271E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    4.5255       1.0000         .10000E-03   10000.    
    16 'Prefactor '    15.891       1.0000         .10000E-03   10000.    
    17 'Prefactor '    7.7441       1.0000         .10000E-03   10000.    
    18 'Prefactor '    4.5424       1.0000         .10000E-03   10000.    
    19 'norm      '    .73175       1.0000         .10000E-03   10000.    
    20 'Prefactor '    20.028       1.0000         .10000E-03   10000.    
    21 'Prefactor '    9.2461       1.0000         .10000E-03   10000.    
    22 'norm      '    80.716       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .11154E-03   1.0000         .10000E-03   10000.    
    24 'Normalizat'    .50196       1.0000         .10000E-01   10.000    
    25 'Prefactor '    1.2538       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=   7525.567     FROM MIGRAD    STATUS=CONVERGED    593 CALLS     2952 TOTAL
                     EDM=   .16E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     13.700        13.754        .27057E-02   -.27139E-03
   2  Prefactor     .10003E-03    102.86        .90712E-02** at limit **
   3  Prefactor     .10000E-03    15.004        .90712E-02** at limit **
   4  Prefactor     9.0771        8.7340        .33255E-02   -.22946E-02
   5  norm          .10000E-03    13.222        .90712E-02** at limit **
   6  Prefactor     13.152        9.2870        .27610E-02   -.91595E-04
   7  Prefactor     .10000E-03    1.4549        .90712E-02** at limit **
   8  norm          .10000E-03    2.7117        .90712E-02** at limit **
   9  Prefactor     4.5536        3.7186        .47139E-02    .11344E-02
  10  norm          3.6338        1.2413        .52983E-02    .54327E-03
  11  Prefactor     .10000E-03    31.012        .12208    ** at limit **
  12  Prefactor     45.716        35.475        .14826E-02    .28187E-04
  13  Prefactor     .10000E-03    2.7958        .90712E-02** at limit **
  14  Prefactor     .10000E-03    42.990        .90712E-02** at limit **
  15  Prefactor     4.5264        9.2515        .47312E-02   -.49794E-03
  16  Prefactor     15.885        19.042        .25118E-02    .68604E-03
  17  Prefactor     7.7456        9.7605        .36024E-02    .37875E-03
  18  Prefactor     4.5424        10.546        .47221E-02    .18182E-02
  19  norm          .73172        .59309        .11203E-01    .95487E-03
  20  Prefactor     20.025        35.244        .22375E-02    .33647E-04
  21  Prefactor     9.2331        25.837        .32950E-02   -.53886E-04
  22  norm          80.721        19.394        .11176E-02   -.32898E-03
  23  Prefactor     .10000E-03    54.970        .90712E-02** at limit **
  24  Normalizat    .50188        .22400        .10425        .19699E-03
  25  Prefactor     1.2538        .13256        .33468E-01    .27017E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 13.6996
  Prefactor  = 0.000100025
  Prefactor  = 0.0001
  Prefactor  = 9.07709
  norm       = 0.0001
  Prefactor  = 13.1516
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 4.55362
  norm       = 3.63379
  Prefactor  = 0.0001
  Prefactor  = 45.716
  Prefactor  = 0.0001
  Prefactor  = 0.000100004
  Prefactor  = 4.52636
  Prefactor  = 15.8849
  Prefactor  = 7.74557
  Prefactor  = 4.54244
  norm       = 0.73172
  Prefactor  = 20.0253
  Prefactor  = 9.23309
  norm       = 80.7212
  Prefactor  = 0.000100001
  Normalizat = 0.501879
  Prefactor  = 1.25383
 **********
 **   18 **HESSE 
 **********

 FCN=   7525.567     FROM HESSE     STATUS=OK           429 CALLS     3381 TOTAL
                     EDM=   .14E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     13.700        13.743        .10823E-03   -1.4968    
   2  Prefactor     .10003E-03    103.43        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10000E-03    15.376        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     9.0771        8.7201        .13302E-03   -1.5105    
   5  norm          .10000E-03    13.269        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     13.152        9.2696        .11044E-03   -1.4983    
   7  Prefactor     .10000E-03    1.4807        .10203E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          .10000E-03    2.7352        .13939E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     4.5536        3.4410        .13096E-03   -1.5281    
  10  norm          3.6338        1.2406        .54806E-04   -1.5327    
  11  Prefactor     .10000E-03    227.01        .83478E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     45.716        35.440        .59305E-04   -1.4355    
  13  Prefactor     .10000E-03    2.8004        .14153E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     .10000E-03    43.019        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     4.5264        9.1716        .18925E-03   -1.5282    
  16  Prefactor     15.885        18.789        .10047E-03   -1.4911    
  17  Prefactor     7.7456        9.7445        .14410E-03   -1.5151    
  18  Prefactor     4.5424        10.503        .18889E-03   -1.5282    
  19  norm          .73172        .56725        .51537E-03   -1.5537    
  20  Prefactor     20.025        35.185        .89498E-04   -1.4813    
  21  Prefactor     9.2331        25.740        .13180E-03   -1.5100    
  22  norm          80.721        19.367        .44704E-04   -1.3909    
  23  Prefactor     .10000E-03    55.145        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Normalizat    .50188        .22923        .46224E-03   -1.1233    
  25  Prefactor     1.2538        .14006        .18379E-03   -.84691    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.41476e-08
Minuit parameter uncertainties:
  1  13.7466
  2  0.00322191
  3  0.00011402
  4  8.72132
  5  0.000106945
  6  9.27061
  7  6.32853e-06
  8  1.53022e-05
  9  3.44117
  10  1.24063
  11  6.3396e-05
  12  35.4561
  13  3.8631e-06
  14  0.000838268
  15  9.17446
  16  18.7956
  17  9.74654
  18  10.5077
  19  0.567255
  20  35.2217
  21  25.7706
  22  19.3684
  23  0.000411438
  24  0.229664
  25  0.140106
Done.

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

Extracting fit parameters...

4FGL J0159.5+1046
   Spectrum: PowerLaw
219    Prefactor:  1.315e+01  9.271e+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.254e+00  1.401e-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:  5.019e-01  2.297e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 2.87
Ra Dec: 29.886 10.774
Photon Index (Fixed Index): 1.99 +/- 0.00
Photon Flux (Fixed Index): 6.10e-08 +/- 4.30e-08
Energy Flux (Fixed Index): 4.27e-05 +/- 3.01e-05

TS (Fixed Index): 2.87
Ra Dec: 29.886 10.774
Photon Flux Upper Limit: 1.47e-07 ph cm-2 s-1
Energy Flux Upper Limit: 1.11e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/534671/likelihoodResults_653270401_653529601_4FGL_J0159.5+1046_daily_bin1597.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) = 7524.10160804
delta logL = 1.46537669239

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 7524.05816531
delta logL = 1.50881942973

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    2.8715       1.0000         .10000E-03   10000.    
     2 'Index     '    2.9890       1.0000          .0000       10.000    
     3 'Normalizat'    .39935       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.2915       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=   7524.058     FROM MIGRAD    STATUS=CONVERGED     53 CALLS      253 TOTAL
                     EDM=   .54E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     2.8577        20.754        .59968E-02   -.60357E-03
   2  Index         2.9910        1.8886        .81362E-01    .42854E-04
   3  Normalizat    .39918        .82665E-01    .11617       -.33313E-04
   4  Prefactor     1.2915        .45349E-01    .32759E-01   -.25808E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 2.8577
  Index      = 2.99097
  Normalizat = 0.399179
  Prefactor  = 1.29153
 **********
 **   18 **HESSE 
 **********

 FCN=   7524.058     FROM HESSE     STATUS=NOT POSDEF    31 CALLS      284 TOTAL
                     EDM=   .55E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     2.8577        32.352        .68724E-04   -1.5370    
   2  Index         2.9910        2.6220        .31943E-02   -.41349    
   3  Normalizat    .39918        .27917        .51506E-03   -1.1734    
   4  Prefactor     1.2915        .16674        .18130E-03   -.83559    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 5.52771e-10
Minuit parameter uncertainties:
  1  19.2433
  2  2.79181
  3  0.280151
  4  0.166813
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/534671': 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) = 7524.0581612
delta logL = 1.50882353124

Extracting fit parameters...

4FGL J0159.5+1046
   Spectrum: PowerLaw
219    Prefactor:  2.858e+00  1.924e+01  1.000e-04  1.000e+04 ( 1.000e-13)
220        Index:  2.991e+00  2.792e+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.292e+00  1.668e-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:  3.992e-01  2.802e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 6.12
Ra Dec: 29.886 10.774
Photon Index (Free Index): 2.99 +/- 2.79
Photon Flux (Free Index): 1.42e-07 +/- 9.75e-08
Energy Flux (Free Index): 2.85e-05 +/- 3.00e-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/534671/cmap_HighResolution_653270401_653529601_4FGL_J0159.5+1046_daily_bin1597.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='1.11e-02', comment='SUCCESS', photon_flux='6.10e-08', energy_flux2='2.85e-05', photon_flux_error='4.30e-08', dlogl='1.51e+00', energy_flux='4.27e-05', photon_flux2='1.42e-07', job_status='DONE', time_completed='2021-09-17 00:28:28.622208', photon_index_error2='2.79', photon_index2='2.99', ts='2.87', fit_tolerance='1e-08', GAL='1.25', photon_index_error='0.00', photon_flux_upper_limit='1.47e-07', energy_flux_error2='3.00e-05', EG='0.50', time_epoch_completed='1631863708.62', return_code='0', job_id='534671', GAL2='1.29', EG2='0.40', return_code2='102', energy_flux_error='3.01e-05', photon_flux_error2='9.75e-08', ts2='6.12', photon_index='1.99' WHERE bin_id='1597' AND source_name='4FGL J0159.5+1046' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Fri Sep 17 00:28:28 PDT 2021


------------------------------------------------------------
Sender: LSF System <scs@bullet0119>
Subject: Job 534671: <4FGL_J0159.5+1046_daily_bin1597> in cluster <slac> Done

Job <4FGL_J0159.5+1046_daily_bin1597> was submitted from host <rhel6-64e> by user <kocevski> in cluster <slac> at Fri Sep 17 00:15:16 2021
Job was executed on host(s) <bullet0119>, in queue <medium>, as user <kocevski> in cluster <slac> at Fri Sep 17 00:15:17 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Fri Sep 17 00:15:17 2021
Terminated at Fri Sep 17 00:28:31 2021
Results reported at Fri Sep 17 00:28:31 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J0159.5+1046_daily_bin1597 29.8858 10.7737 653270401 653529601 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 :                                   776.00 sec.
    Max Memory :                                 1094 MB
    Average Memory :                             313.72 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   791 sec.
    Turnaround time :                            795 sec.

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

