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


Performing analysis on: 4FGL_J1047.7+7238_daily_bin662
RA = 161.939, Dec = 72.642
tmin = 410918401, tmax = 411177601
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='175575', job_status='RUN', time_executed='2021-09-02 14:19:10.200505', time_epoch_executed='1630617550.2' WHERE source_name='4FGL J1047.7+7238' and cadence='daily' and bin_id='662'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/175575

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/175575/ft1_4FGL_J1047.7+7238_daily_bin662.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/175575/ft2_4FGL_J1047.7+7238_daily_bin662.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/175575/ft1_4FGL_J1047.7+7238_daily_bin662.fits outfile=/scratch/kocevski/175575/ft1_filteredMKT_4FGL_J1047.7+7238_daily_bin662.fits ra=161.939 dec=72.642 rad=12.0 tmin=410918401.0 tmax=411177601.0 emin=100.0 emax=100000.0 zmin=0.0 zmax=90.0 evclass=128 evtype="INDEF" convtype=-1 phasemin=0.0 phasemax=1.0 evtable="EVENTS" chatter=2 clobber=yes debug=no gui=no mode="ql"

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

Done.
real 7.13
user 6.79
sys 0.28

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/175575/ft2_4FGL_J1047.7+7238_daily_bin662.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/175575/ft1_filteredMKT_4FGL_J1047.7+7238_daily_bin662.fits evtable="EVENTS" outfile="/scratch/kocevski/175575/ft1_filtered_4FGL_J1047.7+7238_daily_bin662.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.14

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/175575/ft1_filtered_4FGL_J1047.7+7238_daily_bin662.fits" evtable="EVENTS" scfile=/scratch/kocevski/175575/ft2_4FGL_J1047.7+7238_daily_bin662.fits sctable="SC_DATA" outfile=/scratch/kocevski/175575/ltcube_410918401_411177601_4FGL_J1047.7+7238_daily_bin662.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/175575/ft2_4FGL_J1047.7+7238_daily_bin662.fits
.....................!
real 15.80
user 15.42
sys 0.29

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/175575/ft1_filtered_4FGL_J1047.7+7238_daily_bin662.fits evtable="EVENTS" scfile=/scratch/kocevski/175575/ft2_4FGL_J1047.7+7238_daily_bin662.fits sctable="SC_DATA" expcube=/scratch/kocevski/175575/ltcube_410918401_411177601_4FGL_J1047.7+7238_daily_bin662.fits outfile=/scratch/kocevski/175575/expmap_410918401_411177601_4FGL_J1047.7+7238_daily_bin662.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/175575/ltcube_410918401_411177601_4FGL_J1047.7+7238_daily_bin662.fits
.....................!
real 191.63
user 186.94
sys 4.25

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/175575/ft1_filtered_4FGL_J1047.7+7238_daily_bin662.fits scfile=/scratch/kocevski/175575/ft2_4FGL_J1047.7+7238_daily_bin662.fits outfile=/scratch/kocevski/175575/cmap_410918401_411177601_4FGL_J1047.7+7238_daily_bin662.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.38
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/175575/ft1_filtered_4FGL_J1047.7+7238_daily_bin662.fits scfile=/scratch/kocevski/175575/ft2_4FGL_J1047.7+7238_daily_bin662.fits outfile=/scratch/kocevski/175575/cmap_HighResolution_410918401_411177601_4FGL_J1047.7+7238_daily_bin662.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.55
user 0.40
sys 0.15

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/175575/ft1_filtered_4FGL_J1047.7+7238_daily_bin662.fits evtable="EVENTS" scfile=/scratch/kocevski/175575/ft2_4FGL_J1047.7+7238_daily_bin662.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/175575/Model_4FGL_J1047.7+7238_daily_bin662.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/175575/ft1_filtered_4FGL_J1047.7+7238_daily_bin662.fits.....................!
real 48.26
user 46.99
sys 1.15

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/175575/ft1_filtered_4FGL_J1047.7+7238_daily_bin662.fits', '/scratch/kocevski/175575/ft2_4FGL_J1047.7+7238_daily_bin662.fits', expMap='/scratch/kocevski/175575/expmap_410918401_411177601_4FGL_J1047.7+7238_daily_bin662.fits', expCube='/scratch/kocevski/175575/ltcube_410918401_411177601_4FGL_J1047.7+7238_daily_bin662.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/175575/Model_4FGL_J1047.7+7238_daily_bin662.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/175575/ft1_filtered_4FGL_J1047.7+7238_daily_bin662.fits
Spacecraft file(s): /scratch/kocevski/175575/ft2_4FGL_J1047.7+7238_daily_bin662.fits
Exposure map: /scratch/kocevski/175575/expmap_410918401_411177601_4FGL_J1047.7+7238_daily_bin662.fits
Exposure cube: /scratch/kocevski/175575/ltcube_410918401_411177601_4FGL_J1047.7+7238_daily_bin662.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/175575/Model_4FGL_J1047.7+7238_daily_bin662.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) = 3632.08195131

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    6.0625       1.0000         .10000E-03   10000.    
     3 'norm      '    5.0047       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     6 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
     7 'norm      '    35.241       1.0000         .10000E-03   10000.    
     8 'Prefactor '    26.160       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .19156E-01   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    11 'norm      '    5.3728       1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10033E-03   1.0000         .10000E-03   10000.    
    13 'norm      '    16.568       1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10601E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    13.389       1.0000         .10000E-03   10000.    
    17 'norm      '    7.8383       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10126E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    58.470       1.0000         .10000E-03   10000.    
    21 'Prefactor '    3.6748       1.0000         .10000E-03   10000.    
    22 'Prefactor '    .65508E-02   1.0000         .10000E-03   10000.    
    23 'Prefactor '    67.805       1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10165E-03   1.0000         .10000E-03   10000.    
    25 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    26 'norm      '    4.6303       1.0000         .10000E-03   10000.    
    27 'Prefactor '    .10006E-03   1.0000         .10000E-03   10000.    
    28 'Normalizat'    .39520       1.0000         .10000E-01   10.000    
    29 'Prefactor '    1.3118       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=   3631.994     FROM MIGRAD    STATUS=CONVERGED    750 CALLS     3875 TOTAL
                     EDM=   .11E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  2.2%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    12.233       -.38868E-06** at limit **
   2  Prefactor     6.0624        4.6650       -.47017E-07    .11815E-05
   3  norm          5.0045        2.6106       -.50381E-07   -.10765E-04
   4  Prefactor     .10000E-03    11.902        .38813E-06** at limit **
   5  Prefactor     .10000E-03    4.6719       -.88897E-08** at limit **
   6  norm          .10000E-03    .34631       -.43162E-08** at limit **
   7  norm          35.248        33.538       -.14490E-06   -.28607E-05
   8  Prefactor     26.158        20.582       -.76122E-06   -.34764E-04
   9  Prefactor     .10383E-03    28.528       -.40836E-05** at limit **
  10  Prefactor     .10000E-03    175.52       -.44491E-05** at limit **
  11  norm          5.3727        4.9559       -.61312E-07   -.14785E-04
  12  Prefactor     .10000E-03    30.162        .42277E-06** at limit **
  13  norm          16.582        9.1076        .39950E-06    .13565E-03
  14  Prefactor     .10000E-03    335.26        .31421E-05** at limit **
  15  Prefactor     .10000E-03    3.1150       -.14524E-07** at limit **
  16  norm          13.388        2.5603       -.26215E-08    .11470E-03
  17  norm          7.8396        7.3370       -.47512E-07   -.73644E-05
  18  Prefactor     .10000E-03    29.828       -.27581E-05** at limit **
  19  Prefactor     .10000E-03    21.493       -.48674E-06** at limit **
  20  Prefactor     58.450        73.276       -.29915E-05   -.80819E-04
  21  Prefactor     3.6749        11.004        .54436E-06    .24566E-04
  22  Prefactor     .10212E-03    18.534        .30937E-06** at limit **
  23  Prefactor     67.833        200.43        .88072E-05    .41613E-04
  24  Prefactor     .10000E-03    175.27       -.12816E-05** at limit **
  25  norm          .10000E-03    10.072        .25330E-07** at limit **
  26  norm          4.6302        5.7638        .96869E-06    .71436E-04
  27  Prefactor     .10000E-03    43.416       -.36421E-06** at limit **
  28  Normalizat    .39509        .28377        .12098E-05    .11831E-03
  29  Prefactor     1.3120        .22528        .50601E-06    .27058E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 6.06237
  norm       = 5.00453
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 35.2475
  Prefactor  = 26.1576
  Prefactor  = 0.00010383
  Prefactor  = 0.0001
  norm       = 5.37266
  Prefactor  = 0.0001
  norm       = 16.5824
  Prefactor  = 0.000100002
  Prefactor  = 0.0001
  norm       = 13.3885
  norm       = 7.83964
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 58.4501
  Prefactor  = 3.67485
  Prefactor  = 0.000102125
  Prefactor  = 67.8329
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 4.6302
  Prefactor  = 0.0001
  Normalizat = 0.395091
  Prefactor  = 1.31196
 **********
 **   18 **HESSE 
 **********

 FCN=   3631.994     FROM HESSE     STATUS=OK           557 CALLS     4432 TOTAL
                     EDM=   .11E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    12.238        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     6.0624        4.6653        .11111E-03   -1.5215    
   3  norm          5.0045        2.6002        .66033E-04   -1.5261    
   4  Prefactor     .10000E-03    11.914        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10000E-03    4.6857        .12721E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  norm          .10000E-03    .35606        .69153E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  norm          35.248        33.519        .67506E-04   -1.4520    
   8  Prefactor     26.158        20.314        .78322E-04   -1.4685    
   9  Prefactor     .10383E-03    32.353        .79109E-01   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .10000E-03    174.29        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  norm          5.3727        4.9555        .12496E-03   -1.5244    
  12  Prefactor     .10000E-03    30.173        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  norm          16.582        9.8786        .98398E-04   -1.4893    
  14  Prefactor     .10000E-03    335.35        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .10000E-03    3.1190        .10383E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          13.388        2.5683        .36616E-04   -1.4976    
  17  norm          7.8396        7.3081        .13735E-03   -1.5148    
  18  Prefactor     .10000E-03    30.084        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10000E-03    21.563        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     58.450        73.291        .52467E-04   -1.4177    
  21  Prefactor     3.6749        10.960        .21070E-03   -1.5325    
  22  Prefactor     .10212E-03    200.02        .46295E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     67.833        199.91        .48744E-04   -1.4059    
  24  Prefactor     .10000E-03    176.26        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  norm          .10000E-03    10.140        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  norm          4.6302        5.6694        .15111E-03   -1.5278    
  27  Prefactor     .10000E-03    43.447        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  Normalizat    .39509        .29133        .42629E-03   -1.1756    
  29  Prefactor     1.3120        .23930        .21442E-03   -.82952    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.11867e-08
Minuit parameter uncertainties:
  1  3.88048e-05
  2  4.6656
  3  2.60028
  4  3.24559e-05
  5  3.79395e-06
  6  9.62987e-07
  7  33.5365
  8  20.3198
  9  0.0222736
  10  0.000525859
  11  4.95588
  12  7.72246e-05
  13  9.8796
  14  0.00161123
  15  3.13344e-07
  16  2.56834
  17  7.30893
  18  0.000132586
  19  5.60183e-05
  20  73.4041
  21  10.9662
  22  0.0413683
  23  201.942
  24  0.000507143
  25  2.50207e-05
  26  5.67006
  27  0.000121553
  28  0.292458
  29  0.239498
Done.

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

Extracting fit parameters...

4FGL J1047.7+7238
   Spectrum: PowerLaw
374    Prefactor:  1.000e-04  3.133e-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:  1.312e+00  2.395e-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:  3.951e-01  2.925e-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: 1.17e-07 ph cm-2 s-1
Energy Flux Upper Limit: 8.97e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/175575/likelihoodResults_410918401_411177601_4FGL_J1047.7+7238_daily_bin662.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) = 3631.9950311
delta logL = -0.00140280971664

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 3631.99362797
delta logL = 3.17716057907e-07

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.2123       1.0000          .0000       10.000    
     3 'Normalizat'    .39514       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.3119       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=   3631.994     FROM MIGRAD    STATUS=FAILED        86 CALLS      242 TOTAL
                     EDM=   .28E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10114E-03    35.697        .10613E-02** at limit **
   2  Index         2.1621        8.0894        .50000        .56474E-04
   3  Normalizat    .39509        .20524E-01    .42629E-03   -.33269E-04
   4  Prefactor     1.3120        .18177E-01    .21442E-03   -.43243E-04
                               ERR DEF=  .500    
 START SIMPLEX MINIMIZATION.    CONVERGENCE WHEN EDM .LT.   .20E-04
 SIMPLEX MINIMIZATION HAS CONVERGED.

 FCN=   3631.994     FROM SIMPLEX   STATUS=UNCHANGED    127 CALLS      369 TOTAL
                     EDM=   .16E-04    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10114E-03    35.697        .36300E-03** at limit **
   2  Index         2.1621        8.0894        .77098E-03    .56474E-04
   3  Normalizat    .39509        .20524E-01    .89471E-05   -.33269E-04
   4  Prefactor     1.3120        .18177E-01    .41641E-05   -.43243E-04
                               ERR DEF=  .500    

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   3631.994     FROM MIGRAD    STATUS=CONVERGED     51 CALLS      420 TOTAL
                     EDM=   .54E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    70.481        .21225E-02** at limit **
   2  Index         1.5637        7.2559        .50000       -.15034E-06
   3  Normalizat    .39510        .25092E-01    .17052E-04    .10720E-02
   4  Prefactor     1.3120        .22223E-01    .42884E-04    .20682E-02
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Index      = 1.56366
  Normalizat = 0.395098
  Prefactor  = 1.31196
 **********
 **   18 **HESSE 
 **********

 FCN=   3631.994     FROM HESSE     STATUS=NOT POSDEF    29 CALLS      449 TOTAL
                     EDM=   .25E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    314.37        .42451E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         1.5637        5.4753        .50000       -.75772    
   3  Normalizat    .39510        .57084E-01    .34103E-05   -1.1756    
   4  Prefactor     1.3120        .50558E-01    .85769E-05   -.82952    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 2.50558e-09
Minuit parameter uncertainties:
  1  8.07388e-05
  2  891.141
  3  0.0570924
  4  0.0505601
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/175575': 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) = 3631.99362347
delta logL = 4.82286941406e-06

Extracting fit parameters...

4FGL J1047.7+7238
   Spectrum: PowerLaw
374    Prefactor:  1.000e-04  8.074e-05  1.000e-04  1.000e+04 ( 1.000e-13)
375        Index:  1.564e+00  8.911e+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:  1.312e+00  5.056e-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:  3.951e-01  5.709e-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/175575/cmap_HighResolution_410918401_411177601_4FGL_J1047.7+7238_daily_bin662.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='8.97e-03', job_status='DONE', photon_flux_upper_limit='1.17e-07', time_completed='2021-09-02 14:31:54.792196', job_id='175575', GAL2='1.31', fit_tolerance='1e-08', EG2='0.40', EG='0.40', time_epoch_completed='1630618314.79', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='1.31', dlogl='4.82e-06', ts2='-0.00', photon_index_error='0.00', photon_index='2.23' WHERE bin_id='662' AND source_name='4FGL J1047.7+7238' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Sep  2 14:31:54 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0108>
Subject: Job 175575: <4FGL_J1047.7+7238_daily_bin662> in cluster <slac> Done

Job <4FGL_J1047.7+7238_daily_bin662> was submitted from host <rhel6-64k> by user <kocevski> in cluster <slac> at Thu Sep  2 14:16:14 2021
Job was executed on host(s) <bullet0108>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Sep  2 14:16:54 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:16:54 2021
Terminated at Thu Sep  2 14:31:55 2021
Results reported at Thu Sep  2 14:31:55 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1047.7+7238_daily_bin662 161.939 72.642 410918401 411177601 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 :                                   749.00 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             296.79 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   902 sec.
    Turnaround time :                            941 sec.

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

