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


Performing analysis on: 4FGL_J1047.7+7238_daily_bin806
RA = 161.939, Dec = 72.642
tmin = 448243201, tmax = 448502401
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='177250', job_status='RUN', time_executed='2021-09-02 14:24:12.832430', time_epoch_executed='1630617852.83' WHERE source_name='4FGL J1047.7+7238' and cadence='daily' and bin_id='806'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/177250

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/177250/ft1_4FGL_J1047.7+7238_daily_bin806.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/177250/ft2_4FGL_J1047.7+7238_daily_bin806.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/177250/ft1_4FGL_J1047.7+7238_daily_bin806.fits outfile=/scratch/kocevski/177250/ft1_filteredMKT_4FGL_J1047.7+7238_daily_bin806.fits ra=161.939 dec=72.642 rad=12.0 tmin=448243201.0 tmax=448502401.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 5.29
user 4.98
sys 0.23

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/177250/ft2_4FGL_J1047.7+7238_daily_bin806.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/177250/ft2_4FGL_J1047.7+7238_daily_bin806.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/177250/ft1_filteredMKT_4FGL_J1047.7+7238_daily_bin806.fits evtable="EVENTS" outfile="/scratch/kocevski/177250/ft1_filtered_4FGL_J1047.7+7238_daily_bin806.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/177250/ft1_filtered_4FGL_J1047.7+7238_daily_bin806.fits" evtable="EVENTS" scfile=/scratch/kocevski/177250/ft2_4FGL_J1047.7+7238_daily_bin806.fits sctable="SC_DATA" outfile=/scratch/kocevski/177250/ltcube_448243201_448502401_4FGL_J1047.7+7238_daily_bin806.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/177250/ft2_4FGL_J1047.7+7238_daily_bin806.fits
.....................!
real 14.86
user 14.47
sys 0.32

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/177250/ft1_filtered_4FGL_J1047.7+7238_daily_bin806.fits evtable="EVENTS" scfile=/scratch/kocevski/177250/ft2_4FGL_J1047.7+7238_daily_bin806.fits sctable="SC_DATA" expcube=/scratch/kocevski/177250/ltcube_448243201_448502401_4FGL_J1047.7+7238_daily_bin806.fits outfile=/scratch/kocevski/177250/expmap_448243201_448502401_4FGL_J1047.7+7238_daily_bin806.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/177250/ltcube_448243201_448502401_4FGL_J1047.7+7238_daily_bin806.fits
.....................!
real 191.56
user 186.45
sys 4.29

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

Setting source of interest to:
4FGL J1047.7+7238 @ 161.939 72.642

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/177250/ft1_filtered_4FGL_J1047.7+7238_daily_bin806.fits scfile=/scratch/kocevski/177250/ft2_4FGL_J1047.7+7238_daily_bin806.fits outfile=/scratch/kocevski/177250/cmap_448243201_448502401_4FGL_J1047.7+7238_daily_bin806.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=161.939 yref=72.642 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.39
sys 0.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/177250/ft1_filtered_4FGL_J1047.7+7238_daily_bin806.fits scfile=/scratch/kocevski/177250/ft2_4FGL_J1047.7+7238_daily_bin806.fits outfile=/scratch/kocevski/177250/cmap_HighResolution_448243201_448502401_4FGL_J1047.7+7238_daily_bin806.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=161.939 yref=72.642 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.57
user 0.39
sys 0.15

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/177250/ft1_filtered_4FGL_J1047.7+7238_daily_bin806.fits evtable="EVENTS" scfile=/scratch/kocevski/177250/ft2_4FGL_J1047.7+7238_daily_bin806.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/177250/Model_4FGL_J1047.7+7238_daily_bin806.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/177250/ft1_filtered_4FGL_J1047.7+7238_daily_bin806.fits.....................!
real 50.41
user 48.95
sys 1.14

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/177250/ft1_filtered_4FGL_J1047.7+7238_daily_bin806.fits', '/scratch/kocevski/177250/ft2_4FGL_J1047.7+7238_daily_bin806.fits', expMap='/scratch/kocevski/177250/expmap_448243201_448502401_4FGL_J1047.7+7238_daily_bin806.fits', expCube='/scratch/kocevski/177250/ltcube_448243201_448502401_4FGL_J1047.7+7238_daily_bin806.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/177250/Model_4FGL_J1047.7+7238_daily_bin806.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1047.7+7238'

4FGL J1047.7+7238
   Spectrum: PowerLaw
374    Prefactor:  1.026e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
375        Index:  2.234e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
376        Scale:  2.160e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/177250/ft1_filtered_4FGL_J1047.7+7238_daily_bin806.fits
Spacecraft file(s): /scratch/kocevski/177250/ft2_4FGL_J1047.7+7238_daily_bin806.fits
Exposure map: /scratch/kocevski/177250/expmap_448243201_448502401_4FGL_J1047.7+7238_daily_bin806.fits
Exposure cube: /scratch/kocevski/177250/ltcube_448243201_448502401_4FGL_J1047.7+7238_daily_bin806.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/177250/Model_4FGL_J1047.7+7238_daily_bin806.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) = 3913.01403413

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10598E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     3 'norm      '    2.6387       1.0000         .10000E-03   10000.    
     4 'Prefactor '    18.367       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     6 'norm      '    .50613       1.0000         .10000E-03   10000.    
     7 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    34.490       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10391E-03   1.0000         .10000E-03   10000.    
    11 'norm      '    3.8331       1.0000         .10000E-03   10000.    
    12 'Prefactor '    49.777       1.0000         .10000E-03   10000.    
    13 'norm      '    .10023E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10008E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10007E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    2.7335       1.0000         .10000E-03   10000.    
    17 'norm      '    .13397E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    15.084       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    30.248       1.0000         .10000E-03   10000.    
    25 'norm      '    9.1505       1.0000         .10000E-03   10000.    
    26 'norm      '    .10527E-03   1.0000         .10000E-03   10000.    
    27 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    28 'Normalizat'    .93517       1.0000         .10000E-01   10.000    
    29 'Prefactor '    .97812       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .7030E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   3913.005     FROM MIGRAD    STATUS=CONVERGED    735 CALLS     3774 TOTAL
                     EDM=   .19E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .5%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    107.66        .52565E-04** at limit **
   2  Prefactor     .10000E-03    2.1870        .98709E-09** at limit **
   3  norm          2.6396        3.8049        .35766E-07   -.41450E-03
   4  Prefactor     18.360        29.581       -.15492E-05   -.16905E-04
   5  Prefactor     .10000E-03    5.6561        .48278E-07** at limit **
   6  norm          .50607        .78370       -.89301E-07   -.72222E-03
   7  norm          .10000E-03    37.754       -.41520E-05** at limit **
   8  Prefactor     34.496        18.017       -.55626E-06   -.92059E-04
   9  Prefactor     .10000E-03    13.145        .55382E-05** at limit **
  10  Prefactor     .10000E-03    55.102        .91296E-05** at limit **
  11  norm          3.8333        3.3310        .74403E-08    .65581E-04
  12  Prefactor     49.779        44.026        .85821E-06    .18741E-04
  13  norm          .10000E-03    7.6287        .70243E-05** at limit **
  14  Prefactor     .10000E-03    147.47       -.69742E-04** at limit **
  15  Prefactor     .10000E-03    2.2837        .13591E-07** at limit **
  16  norm          2.7335        1.0772        .81871E-07    .22581E-02
  17  norm          .10004E-03    1.7305       -.11439E-05** at limit **
  18  Prefactor     .10000E-03    7.9928        .49830E-05** at limit **
  19  Prefactor     .10000E-03    4.0048        .11125E-06** at limit **
  20  Prefactor     .10000E-03    15.772       -.98396E-05** at limit **
  21  Prefactor     .10000E-03    3.8003        .60670E-07** at limit **
  22  Prefactor     15.093        14.326        .70350E-06    .53421E-03
  23  Prefactor     .10000E-03    45.118       -.10678E-04** at limit **
  24  Prefactor     30.251        29.985        .37760E-06    .12081E-04
  25  norm          9.1513        6.9852       -.65133E-07    .82646E-05
  26  norm          .10005E-03    4.0844       -.38414E-05** at limit **
  27  Prefactor     .10000E-03    21.104        .82137E-05** at limit **
  28  Normalizat    .93511        .21347        .15564E-06    .16411E-03
  29  Prefactor     .97816        .19108        .17325E-06    .20352E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000100001
  Prefactor  = 0.0001
  norm       = 2.63964
  Prefactor  = 18.3596
  Prefactor  = 0.0001
  norm       = 0.506065
  norm       = 0.0001
  Prefactor  = 34.4957
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 3.83327
  Prefactor  = 49.7789
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 2.73348
  norm       = 0.00010004
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 15.0931
  Prefactor  = 0.0001
  Prefactor  = 30.2508
  norm       = 9.15127
  norm       = 0.000100046
  Prefactor  = 0.0001
  Normalizat = 0.935106
  Prefactor  = 0.978156
 **********
 **   18 **HESSE 
 **********

 FCN=   3913.005     FROM HESSE     STATUS=OK           543 CALLS     4317 TOTAL
                     EDM=   .11E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    108.81        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     .10000E-03    2.1882        .90346E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm          2.6396        3.7640        .12506E-03   -1.5383    
   4  Prefactor     18.360        29.350        .93454E-04   -1.4851    
   5  Prefactor     .10000E-03    5.6645        .14529E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  norm          .50607        .74775        .65494E-03   -1.5566    
   7  norm          .10000E-03    38.297        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     34.496        17.995        .68236E-04   -1.4533    
   9  Prefactor     .10000E-03    13.192        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .10000E-03    55.267        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  norm          3.8333        3.3355        .10325E-03   -1.5316    
  12  Prefactor     49.779        44.025        .56840E-04   -1.4296    
  13  norm          .10000E-03    7.8093        .33597E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     .10000E-03    148.45        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .10000E-03    2.2893        .92192E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          2.7335        1.0334        .24628E-04   -1.5377    
  17  norm          .10004E-03    7.4944        .15090E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .10000E-03    8.0144        .17255E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10000E-03    4.0394        .12185E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .10000E-03    15.811        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .10000E-03    3.8391        .11905E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     15.093        13.844        .10313E-03   -1.4931    
  23  Prefactor     .10000E-03    45.180        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     30.251        30.036        .72850E-04   -1.4607    
  25  norm          9.1513        6.9912        .13249E-03   -1.5103    
  26  norm          .10005E-03    8.2933        .23230E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  Prefactor     .10000E-03    21.120        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  Normalizat    .93511        .23891        .25902E-03   -.95237    
  29  Prefactor     .97816        .21495        .23279E-03   -.93461    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.13898e-08
Minuit parameter uncertainties:
  1  0.00072545
  2  1.52102e-06
  3  3.76435
  4  29.3726
  5  9.58369e-07
  6  0.747762
  7  3.84294e-05
  8  17.9982
  9  3.45864e-05
  10  5.92481e-05
  11  3.33562
  12  44.0538
  13  8.79321e-05
  14  3.89928e-05
  15  6.99257e-07
  16  1.03345
  17  0.00109798
  18  3.02752e-05
  19  2.10673e-05
  20  6.44212e-06
  21  3.33176e-06
  22  13.8474
  23  6.46787e-06
  24  30.051
  25  6.9918
  26  0.00123444
  27  1.52123e-06
  28  0.239185
  29  0.215136
Done.

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

Extracting fit parameters...

4FGL J1047.7+7238
   Spectrum: PowerLaw
374    Prefactor:  1.000e-04  6.993e-07  1.000e-04  1.000e+04 ( 1.000e-13)
375        Index:  2.234e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
376        Scale:  2.160e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
700    Prefactor:  9.782e-01  2.151e-01  0.000e+00  1.000e+01 ( 1.000e+00)
701        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
702        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
699   Normalization:  9.351e-01  2.392e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 161.939 72.642
Photon Flux Upper Limit: 8.05e-08 ph cm-2 s-1
Energy Flux Upper Limit: 6.15e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/177250/likelihoodResults_448243201_448502401_4FGL_J1047.7+7238_daily_bin806.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) = 3913.00706398
delta logL = -0.00204956823382

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 3913.00501391
delta logL = 5.00691839989e-07

Fit tolerance = 1e-08

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

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

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.
 MIGRAD TERMINATED WITHOUT CONVERGENCE.

 FCN=   3913.005     FROM MIGRAD    STATUS=FAILED        84 CALLS      228 TOTAL
                     EDM=   .26E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10158E-03    19.001        .10115E-02** at limit **
   2  Index         2.1200        7.2126        .50000        .13332E-03
   3  Normalizat    .93511        .14252E-01    .25902E-03    .33572E-03
   4  Prefactor     .97815        .13141E-01    .23279E-03    .26330E-03
                               ERR DEF=  .500    
 START SIMPLEX MINIMIZATION.    CONVERGENCE WHEN EDM .LT.   .20E-04
 SIMPLEX MINIMIZATION HAS CONVERGED.

 FCN=   3913.005     FROM SIMPLEX   STATUS=UNCHANGED    122 CALLS      350 TOTAL
                     EDM=   .67E-05    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10158E-03    19.001        .22613E-03** at limit **
   2  Index         2.1200        7.2126        .99760E-03    .13332E-03
   3  Normalizat    .93511        .14252E-01    .13713E-04    .33572E-03
   4  Prefactor     .97815        .13141E-01    .12746E-04    .26330E-03
                               ERR DEF=  .500    

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   3913.005     FROM MIGRAD    STATUS=CONVERGED     58 CALLS      408 TOTAL
                     EDM=   .50E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    35.751        .20229E-02** at limit **
   2  Index         1.5722        8.8035        .50000        .50359E-06
   3  Normalizat    .93510        .14894E-01    .51804E-04   -.20616E-03
   4  Prefactor     .97816        .13733E-01    .46558E-04    .15462E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000100002
  Index      = 1.5722
  Normalizat = 0.9351
  Prefactor  = 0.978161
 **********
 **   18 **HESSE 
 **********

 FCN=   3913.005     FROM HESSE     STATUS=NOT POSDEF    29 CALLS      437 TOTAL
                     EDM=   .24E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    169.26        .40458E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         1.5722        5.0486        .50000       -.75537    
   3  Normalizat    .93510        .33477E-01    .10361E-04   -.95238    
   4  Prefactor     .97816        .30868E-01    .93116E-05   -.93461    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 2.39754e-08
Minuit parameter uncertainties:
  1  0.00108041
  2  326.036
  3  0.0334779
  4  0.0308689
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/177250': 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) = 3913.00500273
delta logL = 1.16809733299e-05

Extracting fit parameters...

4FGL J1047.7+7238
   Spectrum: PowerLaw
374    Prefactor:  1.000e-04  1.080e-03  1.000e-04  1.000e+04 ( 1.000e-13)
375        Index:  1.572e+00  3.260e+02  0.000e+00  1.000e+01 (-1.000e+00)
376        Scale:  2.160e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
700    Prefactor:  9.782e-01  3.087e-02  0.000e+00  1.000e+01 ( 1.000e+00)
701        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
702        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
699   Normalization:  9.351e-01  3.348e-02  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 161.939 72.642

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/177250/cmap_HighResolution_448243201_448502401_4FGL_J1047.7+7238_daily_bin806.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='6.15e-03', job_status='DONE', photon_flux_upper_limit='8.05e-08', time_completed='2021-09-02 14:37:33.946348', job_id='177250', GAL2='0.98', fit_tolerance='1e-08', EG2='0.94', EG='0.94', time_epoch_completed='1630618653.95', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.98', dlogl='1.17e-05', ts2='-0.00', photon_index_error='0.00', photon_index='2.23' WHERE bin_id='806' AND source_name='4FGL J1047.7+7238' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Sep  2 14:37:33 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0172>
Subject: Job 177250: <4FGL_J1047.7+7238_daily_bin806> in cluster <slac> Done

Job <4FGL_J1047.7+7238_daily_bin806> was submitted from host <rhel6-64d> by user <kocevski> in cluster <slac> at Thu Sep  2 14:21:38 2021
Job was executed on host(s) <bullet0172>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Sep  2 14:21:45 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Thu Sep  2 14:21:45 2021
Terminated at Thu Sep  2 14:37:34 2021
Results reported at Thu Sep  2 14:37:34 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1047.7+7238_daily_bin806 161.939 72.642 448243201 448502401 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1047.7+7238 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   758.01 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             283.24 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   949 sec.
    Turnaround time :                            956 sec.

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

