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


Performing analysis on: 4FGL_J1159.0+0939_daily_bin890
RA = 179.751, Dec = 9.6603
tmin = 470016001, tmax = 470275201
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='208647', job_status='RUN', time_executed='2021-09-04 18:09:49.835270', time_epoch_executed='1630804189.84' WHERE source_name='4FGL J1159.0+0939' and cadence='daily' and bin_id='890'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/208647

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/208647/ft1_4FGL_J1159.0+0939_daily_bin890.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/208647/ft2_4FGL_J1159.0+0939_daily_bin890.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/208647/ft1_4FGL_J1159.0+0939_daily_bin890.fits outfile=/scratch/kocevski/208647/ft1_filteredMKT_4FGL_J1159.0+0939_daily_bin890.fits ra=179.751 dec=9.6603 rad=12.0 tmin=470016001.0 tmax=470275201.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.50
user 3.30
sys 0.19

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/208647/ft2_4FGL_J1159.0+0939_daily_bin890.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/208647/ft2_4FGL_J1159.0+0939_daily_bin890.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/208647/ft1_filteredMKT_4FGL_J1159.0+0939_daily_bin890.fits evtable="EVENTS" outfile="/scratch/kocevski/208647/ft1_filtered_4FGL_J1159.0+0939_daily_bin890.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.33
sys 0.16

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/208647/ft1_filtered_4FGL_J1159.0+0939_daily_bin890.fits" evtable="EVENTS" scfile=/scratch/kocevski/208647/ft2_4FGL_J1159.0+0939_daily_bin890.fits sctable="SC_DATA" outfile=/scratch/kocevski/208647/ltcube_470016001_470275201_4FGL_J1159.0+0939_daily_bin890.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/208647/ft2_4FGL_J1159.0+0939_daily_bin890.fits
.....................!
real 12.09
user 11.75
sys 0.31

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/208647/ft1_filtered_4FGL_J1159.0+0939_daily_bin890.fits evtable="EVENTS" scfile=/scratch/kocevski/208647/ft2_4FGL_J1159.0+0939_daily_bin890.fits sctable="SC_DATA" expcube=/scratch/kocevski/208647/ltcube_470016001_470275201_4FGL_J1159.0+0939_daily_bin890.fits outfile=/scratch/kocevski/208647/expmap_470016001_470275201_4FGL_J1159.0+0939_daily_bin890.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/208647/ltcube_470016001_470275201_4FGL_J1159.0+0939_daily_bin890.fits
.....................!
real 192.02
user 187.82
sys 3.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 193 point sources and 0 extended sources

Setting source of interest to:
4FGL J1159.0+0939 @ 179.751 9.6603

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/208647/ft1_filtered_4FGL_J1159.0+0939_daily_bin890.fits scfile=/scratch/kocevski/208647/ft2_4FGL_J1159.0+0939_daily_bin890.fits outfile=/scratch/kocevski/208647/cmap_470016001_470275201_4FGL_J1159.0+0939_daily_bin890.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=179.751 yref=9.6603 axisrot=0.0 rafield="RA" decfield="DEC" proj="AIT" hpx_ordering_scheme="RING" hpx_order=3 hpx_ebin=yes hpx_region="" evtable="EVENTS" sctable="SC_DATA" efield="ENERGY" tfield="TIME" chatter=2 clobber=yes debug=no gui=no mode="ql"

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

This is gtbin version HEAD
real 0.53
user 0.37
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/208647/ft1_filtered_4FGL_J1159.0+0939_daily_bin890.fits scfile=/scratch/kocevski/208647/ft2_4FGL_J1159.0+0939_daily_bin890.fits outfile=/scratch/kocevski/208647/cmap_HighResolution_470016001_470275201_4FGL_J1159.0+0939_daily_bin890.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=179.751 yref=9.6603 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.40
sys 0.13

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/208647/ft1_filtered_4FGL_J1159.0+0939_daily_bin890.fits evtable="EVENTS" scfile=/scratch/kocevski/208647/ft2_4FGL_J1159.0+0939_daily_bin890.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/208647/Model_4FGL_J1159.0+0939_daily_bin890.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/208647/ft1_filtered_4FGL_J1159.0+0939_daily_bin890.fits.....................!
real 55.71
user 54.39
sys 1.07

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/208647/ft1_filtered_4FGL_J1159.0+0939_daily_bin890.fits', '/scratch/kocevski/208647/ft2_4FGL_J1159.0+0939_daily_bin890.fits', expMap='/scratch/kocevski/208647/expmap_470016001_470275201_4FGL_J1159.0+0939_daily_bin890.fits', expCube='/scratch/kocevski/208647/ltcube_470016001_470275201_4FGL_J1159.0+0939_daily_bin890.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/208647/Model_4FGL_J1159.0+0939_daily_bin890.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1159.0+0939'

4FGL J1159.0+0939
   Spectrum: PowerLaw
301    Prefactor:  2.838e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
302        Index:  2.132e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
303        Scale:  1.503e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/208647/ft1_filtered_4FGL_J1159.0+0939_daily_bin890.fits
Spacecraft file(s): /scratch/kocevski/208647/ft2_4FGL_J1159.0+0939_daily_bin890.fits
Exposure map: /scratch/kocevski/208647/expmap_470016001_470275201_4FGL_J1159.0+0939_daily_bin890.fits
Exposure cube: /scratch/kocevski/208647/ltcube_470016001_470275201_4FGL_J1159.0+0939_daily_bin890.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/208647/Model_4FGL_J1159.0+0939_daily_bin890.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) = 5904.84641481

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .75034       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10010E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    1.6311       1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    11.827       1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10006E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    .14119E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .23770E-02   1.0000         .10000E-03   10000.    
    11 'Prefactor '    .55179E-02   1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    13 'Prefactor '    41.429       1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10101E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    .10012E-03   1.0000         .10000E-03   10000.    
    17 'Prefactor '    .10024E-03   1.0000         .10000E-03   10000.    
    18 'norm      '    .10267E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    20 'norm      '    35.726       1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
    22 'norm      '    2.7673       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10041E-03   1.0000         .10000E-03   10000.    
    25 'norm      '    2.3619       1.0000         .10000E-03   10000.    
    26 'Normalizat'    .82899       1.0000         .10000E-01   10.000    
    27 'Prefactor '    1.2803       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6190E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   5904.788     FROM MIGRAD    STATUS=CONVERGED    670 CALLS     2831 TOTAL
                     EDM=   .11E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  3.3%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .10000E-03    2.4974        .10314E-08** at limit **
   2  Prefactor     .10000E-03    18.263       -.43208E-06** at limit **
   3  Prefactor     .75078        2.0208        .21260E-06    .40182E-05
   4  Prefactor     .10000E-03    19.832        .34556E-06** at limit **
   5  Prefactor     1.6328        17.779        .13204E-04    .25226E-04
   6  Prefactor     .10000E-03    55.459        .39565E-05** at limit **
   7  Prefactor     11.800        11.173       -.24627E-06   -.18127E-03
   8  Prefactor     .10000E-03    2.7781        .72688E-08** at limit **
   9  Prefactor     .10000E-03    31.782       -.24768E-06** at limit **
  10  Prefactor     .10027E-03    2.0844        .76371E-06** at limit **
  11  Prefactor     .10000E-03    264.45        .40180E-05** at limit **
  12  Prefactor     .10000E-03    10.669        .51000E-06** at limit **
  13  Prefactor     41.427        25.001       -.19251E-06   -.95814E-05
  14  Prefactor     .10000E-03    1.7499       -.42188E-08** at limit **
  15  Prefactor     .10000E-03    1.0338        .38954E-08** at limit **
  16  Prefactor     .10000E-03    18.637       -.45112E-07** at limit **
  17  Prefactor     .10000E-03    9.1636        .33329E-07** at limit **
  18  norm          .10000E-03    2.1484       -.63002E-07** at limit **
  19  Prefactor     .10000E-03    10.591       -.49168E-06** at limit **
  20  norm          35.722        43.933        .24650E-06    .25361E-05
  21  Prefactor     .10000E-03    69.422       -.40190E-05** at limit **
  22  norm          2.7677        .73025        .97905E-08    .15915E-03
  23  Prefactor     .10000E-03    3.9977        .14774E-07** at limit **
  24  Prefactor     .10000E-03    30.862       -.53962E-06** at limit **
  25  norm          2.3620        1.5999        .28320E-07    .46214E-04
  26  Normalizat    .82880        .18563       -.26759E-06   -.22183E-03
  27  Prefactor     1.2804        .17469       -.38077E-06   -.17910E-03
                               ERR DEF=  .500    
Final values: 
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.750782
  Prefactor  = 0.0001
  Prefactor  = 1.63281
  Prefactor  = 0.000100001
  Prefactor  = 11.8003
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.000100266
  Prefactor  = 0.000100003
  Prefactor  = 0.0001
  Prefactor  = 41.4266
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  norm       = 35.7224
  Prefactor  = 0.000100001
  norm       = 2.76772
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 2.36203
  Normalizat = 0.828795
  Prefactor  = 1.28038
 **********
 **   18 **HESSE 
 **********

 FCN=   5904.788     FROM HESSE     STATUS=OK           480 CALLS     3311 TOTAL
                     EDM=   .32E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          .10000E-03    2.4994        .11860E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     .10000E-03    18.328        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .75078        1.9689        .17267E-03   -1.5535    
   4  Prefactor     .10000E-03    20.334        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     1.6328        17.787        .16555E-02   -1.5452    
   6  Prefactor     .10000E-03    55.558        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     11.800        11.197        .11649E-03   -1.5021    
   8  Prefactor     .10000E-03    2.7847        .12507E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     .10000E-03    32.278        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .10027E-03    77.596        .20786E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .10000E-03    266.95        .19063E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10000E-03    10.676        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     41.427        24.993        .62279E-04   -1.4420    
  14  Prefactor     .10000E-03    1.8221        .19817E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .10000E-03    1.0420        .76267E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     .10000E-03    18.742        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  Prefactor     .10000E-03    9.3155        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  norm          .10000E-03    2.1953        .21903E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10000E-03    10.596        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  norm          35.722        44.154        .67048E-04   -1.4512    
  21  Prefactor     .10000E-03    69.499        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  norm          2.7677        .73380        .31203E-04   -1.5375    
  23  Prefactor     .10000E-03    4.0047        .15004E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     .10000E-03    31.173        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  norm          2.3620        1.5947        .77157E-04   -1.5401    
  26  Normalizat    .82880        .21787        .28578E-03   -.99009    
  27  Prefactor     1.2804        .20756        .22573E-03   -.83892    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 3.23328e-09
Minuit parameter uncertainties:
  1  2.41415e-07
  2  3.54841e-05
  3  1.96903
  4  0.000171873
  5  10.782
  6  0.000407356
  7  11.1993
  8  2.24111e-07
  9  7.67754e-06
  10  0.00910571
  11  0.00164144
  12  2.37917e-05
  13  24.9988
  14  8.2089e-07
  15  7.25292e-08
  16  1.68348e-06
  17  3.9211e-06
  18  5.41683e-06
  19  2.41776e-05
  20  44.1941
  21  0.000462848
  22  0.733799
  23  2.48433e-06
  24  0.00011117
  25  1.59473
  26  0.218096
  27  0.207691
Done.

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

Extracting fit parameters...

4FGL J1159.0+0939
   Spectrum: PowerLaw
301    Prefactor:  1.180e+01  1.120e+01  1.000e-04  1.000e+04 ( 1.000e-13)
302        Index:  2.132e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
303        Scale:  1.503e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
616    Prefactor:  1.280e+00  2.077e-01  0.000e+00  1.000e+01 ( 1.000e+00)
617        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
618        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
615   Normalization:  8.288e-01  2.181e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 1.65
Ra Dec: 179.751 9.660
Photon Index (Fixed Index): 2.13 +/- 0.00
Photon Flux (Fixed Index): 3.37e-08 +/- 3.19e-08
Energy Flux (Fixed Index): 1.73e-05 +/- 1.64e-05

TS (Fixed Index): 1.65
Ra Dec: 179.751 9.660
Photon Flux Upper Limit: 1.05e-07 ph cm-2 s-1
Energy Flux Upper Limit: 7.94e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/208647/likelihoodResults_470016001_470275201_4FGL_J1159.0+0939_daily_bin890.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) = 5900.80736308
delta logL = 3.98078185966

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 5900.70851413
delta logL = 4.07963081188

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .36634E-02   1.0000         .10000E-03   10000.    
     2 'Index     '    6.2315       1.0000          .0000       10.000    
     3 'Normalizat'    .62787       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.4220       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6190E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   5900.709     FROM MIGRAD    STATUS=CONVERGED     57 CALLS      389 TOTAL
                     EDM=   .26E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .36369E-02    .21900E-01    .44880E-03    .72053E-02
   2  Index         6.2344        1.7626        .55035E-01    .19530E-03
   3  Normalizat    .62775        .70857E-01    .73066E-01    .30147E-04
   4  Prefactor     1.4221        .67953E-01    .48827E-01   -.27116E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.00363692
  Index      = 6.2344
  Normalizat = 0.627753
  Prefactor  = 1.42207
 **********
 **   18 **HESSE 
 **********

 FCN=   5900.709     FROM HESSE     STATUS=NOT POSDEF    33 CALLS      422 TOTAL
                     EDM=   .19E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .36369E-02    .32492E-01    .18728E-05   -1.5696    
   2  Index         6.2344        2.2187        .23543E-02    .24946    
   3  Normalizat    .62775        .20357        .32344E-03   -1.0682    
   4  Prefactor     1.4221        .19301        .21584E-03   -.79746    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 1.86184e-10
Minuit parameter uncertainties:
  1  0.0214404
  2  2.30462
  3  0.203817
  4  0.193105
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/208647': 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) = 5900.70851256
delta logL = 4.07963237823

Extracting fit parameters...

4FGL J1159.0+0939
   Spectrum: PowerLaw
301    Prefactor:  3.637e-03  2.144e-02  1.000e-04  1.000e+04 ( 1.000e-13)
302        Index:  6.234e+00  2.305e+00  0.000e+00  1.000e+01 (-1.000e+00)
303        Scale:  1.503e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
616    Prefactor:  1.422e+00  1.931e-01  0.000e+00  1.000e+01 ( 1.000e+00)
617        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
618        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
615   Normalization:  6.278e-01  2.038e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 10.82
Ra Dec: 179.751 9.660
Photon Index (Free Index): 6.23 +/- 2.30
Photon Flux (Free Index): 1.53e-07 +/- 6.38e-08
Energy Flux (Free Index): 1.88e-05 +/- 8.45e-06

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/208647/cmap_HighResolution_470016001_470275201_4FGL_J1159.0+0939_daily_bin890.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='7.94e-03', comment='SUCCESS', photon_flux='3.37e-08', energy_flux2='1.88e-05', photon_flux_error='3.19e-08', dlogl='4.08e+00', energy_flux='1.73e-05', photon_flux2='1.53e-07', job_status='DONE', time_completed='2021-09-04 18:22:30.154979', photon_index_error2='2.30', photon_index2='6.23', ts='1.65', fit_tolerance='1e-08', GAL='1.28', photon_index_error='0.00', photon_flux_upper_limit='1.05e-07', energy_flux_error2='8.45e-06', EG='0.83', time_epoch_completed='1630804950.16', return_code='0', job_id='208647', GAL2='1.42', EG2='0.63', return_code2='102', energy_flux_error='1.64e-05', photon_flux_error2='6.38e-08', ts2='10.82', photon_index='2.13' WHERE bin_id='890' AND source_name='4FGL J1159.0+0939' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sat Sep  4 18:22:30 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0251>
Subject: Job 208647: <4FGL_J1159.0+0939_daily_bin890> in cluster <slac> Done

Job <4FGL_J1159.0+0939_daily_bin890> was submitted from host <rhel6-64e> by user <kocevski> in cluster <slac> at Sat Sep  4 18:05:54 2021
Job was executed on host(s) <bullet0251>, in queue <medium>, as user <kocevski> in cluster <slac> at Sat Sep  4 18:05:56 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sat Sep  4 18:05:56 2021
Terminated at Sat Sep  4 18:22:30 2021
Results reported at Sat Sep  4 18:22:30 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1159.0+0939_daily_bin890 179.751 9.6603 470016001 470275201 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1159.0+0939 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   758.35 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             246.87 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   994 sec.
    Turnaround time :                            996 sec.

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

