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


Performing analysis on: 4FGL_J1139.0+4033_daily_bin1592
RA = 174.764, Dec = 40.5617
tmin = 651974401, tmax = 652233601
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='991395', job_status='RUN', time_executed='2021-09-04 07:17:29.137307', time_epoch_executed='1630765049.14' WHERE source_name='4FGL J1139.0+4033' and cadence='daily' and bin_id='1592'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/991395

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/991395/ft1_4FGL_J1139.0+4033_daily_bin1592.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/991395/ft2_4FGL_J1139.0+4033_daily_bin1592.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/991395/ft1_4FGL_J1139.0+4033_daily_bin1592.fits outfile=/scratch/kocevski/991395/ft1_filteredMKT_4FGL_J1139.0+4033_daily_bin1592.fits ra=174.764 dec=40.5617 rad=12.0 tmin=651974401.0 tmax=652233601.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.47
user 3.26
sys 0.19

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/991395/ft2_4FGL_J1139.0+4033_daily_bin1592.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/991395/ft2_4FGL_J1139.0+4033_daily_bin1592.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/991395/ft1_filteredMKT_4FGL_J1139.0+4033_daily_bin1592.fits evtable="EVENTS" outfile="/scratch/kocevski/991395/ft1_filtered_4FGL_J1139.0+4033_daily_bin1592.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.32
sys 0.17

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/991395/ft1_filtered_4FGL_J1139.0+4033_daily_bin1592.fits" evtable="EVENTS" scfile=/scratch/kocevski/991395/ft2_4FGL_J1139.0+4033_daily_bin1592.fits sctable="SC_DATA" outfile=/scratch/kocevski/991395/ltcube_651974401_652233601_4FGL_J1139.0+4033_daily_bin1592.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/991395/ft2_4FGL_J1139.0+4033_daily_bin1592.fits
.....................!
real 11.70
user 11.35
sys 0.31

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/991395/ft1_filtered_4FGL_J1139.0+4033_daily_bin1592.fits evtable="EVENTS" scfile=/scratch/kocevski/991395/ft2_4FGL_J1139.0+4033_daily_bin1592.fits sctable="SC_DATA" expcube=/scratch/kocevski/991395/ltcube_651974401_652233601_4FGL_J1139.0+4033_daily_bin1592.fits outfile=/scratch/kocevski/991395/expmap_651974401_652233601_4FGL_J1139.0+4033_daily_bin1592.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/991395/ltcube_651974401_652233601_4FGL_J1139.0+4033_daily_bin1592.fits
.....................!
real 190.99
user 184.97
sys 5.50

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 J1139.0+4033 @ 174.764 40.5617

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/991395/ft1_filtered_4FGL_J1139.0+4033_daily_bin1592.fits scfile=/scratch/kocevski/991395/ft2_4FGL_J1139.0+4033_daily_bin1592.fits outfile=/scratch/kocevski/991395/cmap_651974401_652233601_4FGL_J1139.0+4033_daily_bin1592.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=174.764 yref=40.5617 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.13

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/991395/ft1_filtered_4FGL_J1139.0+4033_daily_bin1592.fits scfile=/scratch/kocevski/991395/ft2_4FGL_J1139.0+4033_daily_bin1592.fits outfile=/scratch/kocevski/991395/cmap_HighResolution_651974401_652233601_4FGL_J1139.0+4033_daily_bin1592.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=174.764 yref=40.5617 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.15

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/991395/ft1_filtered_4FGL_J1139.0+4033_daily_bin1592.fits evtable="EVENTS" scfile=/scratch/kocevski/991395/ft2_4FGL_J1139.0+4033_daily_bin1592.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/991395/Model_4FGL_J1139.0+4033_daily_bin1592.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/991395/ft1_filtered_4FGL_J1139.0+4033_daily_bin1592.fits.....................!
real 59.98
user 58.37
sys 1.33

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/991395/ft1_filtered_4FGL_J1139.0+4033_daily_bin1592.fits', '/scratch/kocevski/991395/ft2_4FGL_J1139.0+4033_daily_bin1592.fits', expMap='/scratch/kocevski/991395/expmap_651974401_652233601_4FGL_J1139.0+4033_daily_bin1592.fits', expCube='/scratch/kocevski/991395/ltcube_651974401_652233601_4FGL_J1139.0+4033_daily_bin1592.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/991395/Model_4FGL_J1139.0+4033_daily_bin1592.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1139.0+4033'

4FGL J1139.0+4033
   Spectrum: PowerLaw
341    Prefactor:  9.736e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
342        Index:  2.720e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
343        Scale:  6.779e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/991395/ft1_filtered_4FGL_J1139.0+4033_daily_bin1592.fits
Spacecraft file(s): /scratch/kocevski/991395/ft2_4FGL_J1139.0+4033_daily_bin1592.fits
Exposure map: /scratch/kocevski/991395/expmap_651974401_652233601_4FGL_J1139.0+4033_daily_bin1592.fits
Exposure cube: /scratch/kocevski/991395/ltcube_651974401_652233601_4FGL_J1139.0+4033_daily_bin1592.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/991395/Model_4FGL_J1139.0+4033_daily_bin1592.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) = 6895.83978009

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    5.3841       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     3 'norm      '    2.2767       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10009E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     7 'norm      '    7.3673       1.0000         .10000E-03   10000.    
     8 'norm      '    .10045E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    7.6266       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10040E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    6.0934       1.0000         .10000E-03   10000.    
    12 'norm      '    7.3700       1.0000         .10000E-03   10000.    
    13 'Prefactor '    8.9832       1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    39.467       1.0000         .10000E-03   10000.    
    16 'norm      '    2.0414       1.0000         .10000E-03   10000.    
    17 'norm      '    .10030E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    34.646       1.0000         .10000E-03   10000.    
    19 'Prefactor '    .40025       1.0000         .10000E-03   10000.    
    20 'Prefactor '    32.683       1.0000         .10000E-03   10000.    
    21 'Prefactor '    95.227       1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10012E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    3.8313       1.0000         .10000E-03   10000.    
    24 'Normalizat'    .99431       1.0000         .10000E-01   10.000    
    25 'Prefactor '    .91641       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6960E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   6895.806     FROM MIGRAD    STATUS=CONVERGED    579 CALLS     2926 TOTAL
                     EDM=   .15E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  2.2%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     5.3821        45.987       -.61659E-07   -.16653E-04
   2  Prefactor     .10000E-03    26.138       -.33052E-05** at limit **
   3  norm          2.2768        .40016        .20210E-08   -.88981E-04
   4  Prefactor     .10000E-03    13.098       -.19941E-06** at limit **
   5  Prefactor     .10000E-03    10.932        .11353E-06** at limit **
   6  Prefactor     .10000E-03    20.631        .29129E-05** at limit **
   7  norm          7.3667        8.9416        .50412E-07   -.67621E-05
   8  norm          .10000E-03    66.260       -.21698E-05** at limit **
   9  Prefactor     7.6265        3.3381        .87982E-07   -.19336E-03
  10  Prefactor     .10001E-03    38.834        .43571E-05** at limit **
  11  Prefactor     6.0834        26.431       -.15406E-06   -.31750E-04
  12  norm          7.3698        3.4500        .10016E-06   -.20266E-03
  13  Prefactor     8.9750        18.969        .40520E-06    .20876E-04
  14  Prefactor     .10000E-03    2.4072        .30457E-07** at limit **
  15  Prefactor     39.456        37.223       -.16426E-05   -.20526E-03
  16  norm          2.0417        1.2115        .34975E-06   -.12988E-03
  17  norm          .10000E-03    2.5559       -.76113E-07** at limit **
  18  Prefactor     34.643        28.244       -.40571E-06   -.52662E-04
  19  Prefactor     .39526        2.1623       -.12550E-06    .21244E-03
  20  Prefactor     32.646        45.528       -.77849E-05   -.46363E-03
  21  Prefactor     95.232        29.964        .33925E-07    .24301E-03
  22  Prefactor     .10000E-03    23.664       -.18462E-05** at limit **
  23  Prefactor     3.8307        6.5397        .55812E-05   -.97423E-03
  24  Normalizat    .99420        .16872       -.97475E-07    .10009E-04
  25  Prefactor     .91653        .19302       -.85655E-06    .42480E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 5.38209
  Prefactor  = 0.000100005
  norm       = 2.27678
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.000100004
  norm       = 7.36675
  norm       = 0.000100002
  Prefactor  = 7.62652
  Prefactor  = 0.000100008
  Prefactor  = 6.08344
  norm       = 7.36978
  Prefactor  = 8.97499
  Prefactor  = 0.0001
  Prefactor  = 39.4557
  norm       = 2.0417
  norm       = 0.0001
  Prefactor  = 34.6426
  Prefactor  = 0.395258
  Prefactor  = 32.6457
  Prefactor  = 95.232
  Prefactor  = 0.000100001
  Prefactor  = 3.83073
  Normalizat = 0.9942
  Prefactor  = 0.916531
 **********
 **   18 **HESSE 
 **********

 FCN=   6895.806     FROM HESSE     STATUS=OK           429 CALLS     3355 TOTAL
                     EDM=   .38E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     5.3821        46.044        .17319E-03   -1.5244    
   2  Prefactor     .10000E-03    26.476        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm          2.2768        .40047        .21252E-04   -1.5406    
   4  Prefactor     .10000E-03    13.202        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10000E-03    10.975        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    20.878        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  norm          7.3667        8.9363        .14777E-03   -1.5165    
   8  norm          .10000E-03    67.403        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     7.6265        3.3332        .91066E-04   -1.5156    
  10  Prefactor     .10001E-03    39.402        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     6.0834        25.384        .16265E-03   -1.5215    
  12  norm          7.3698        3.4454        .94298E-04   -1.5165    
  13  Prefactor     8.9750        18.565        .13373E-03   -1.5109    
  14  Prefactor     .10000E-03    2.4289        .12572E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     39.456        37.389        .63803E-04   -1.4451    
  16  norm          2.0417        1.2157        .60636E-04   -1.5422    
  17  norm          .10000E-03    2.5564        .12965E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     34.643        28.302        .68082E-04   -1.4530    
  19  Prefactor     .39526        7.7899        .20742E-02   -1.5582    
  20  Prefactor     32.646        48.069        .70091E-04   -1.4565    
  21  Prefactor     95.232        29.953        .41187E-04   -1.3753    
  22  Prefactor     .10000E-03    23.842        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     3.8307        6.8276        .10310E-02   -1.5316    
  24  Normalizat    .99420        .19550        .25214E-03   -.93225    
  25  Prefactor     .91653        .22294        .31273E-03   -.95566    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 3.75887e-09
Minuit parameter uncertainties:
  1  31.5166
  2  0.000727399
  3  0.40047
  4  4.07442e-05
  5  1.31949e-05
  6  0.000560356
  7  8.93791
  8  0.000721494
  9  3.33332
  10  0.00114621
  11  24.8711
  12  3.44552
  13  18.577
  14  1.68989e-06
  15  37.4112
  16  1.2157
  17  6.22128e-06
  18  28.313
  19  3.50951
  20  48.1265
  21  29.9573
  22  0.000373622
  23  6.82896
  24  0.195637
  25  0.22316
Done.

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

Extracting fit parameters...

4FGL J1139.0+4033
   Spectrum: PowerLaw
341    Prefactor:  3.946e+01  3.741e+01  1.000e-04  1.000e+04 ( 1.000e-13)
342        Index:  2.720e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
343        Scale:  6.779e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
693    Prefactor:  9.165e-01  2.232e-01  0.000e+00  1.000e+01 ( 1.000e+00)
694        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
695        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
692   Normalization:  9.942e-01  1.956e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 2.17
Ra Dec: 174.764 40.562
Photon Index (Fixed Index): 2.72 +/- 0.00
Photon Flux (Fixed Index): 4.19e-08 +/- 3.97e-08
Energy Flux (Fixed Index): 9.92e-06 +/- 9.41e-06

TS (Fixed Index): 2.17
Ra Dec: 174.764 40.562
Photon Flux Upper Limit: 1.25e-07 ph cm-2 s-1
Energy Flux Upper Limit: 9.83e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/991395/likelihoodResults_651974401_652233601_4FGL_J1139.0+4033_daily_bin1592.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) = 6895.74562418
delta logL = 0.0600473138875

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 6895.74384683
delta logL = 0.061824673272

Fit tolerance = 1e-08

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

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

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   6895.744     FROM MIGRAD    STATUS=CONVERGED     59 CALLS      258 TOTAL
                     EDM=   .22E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     48.127        1272.3        .14460E-02    .72330E-05
   2  Index         2.4307        5.9599        .23794        .34964E-04
   3  Normalizat    1.0024        .84148E-01    .46198E-01   -.12158E-04
   4  Prefactor     .90930        .78178E-01    .70930E-01   -.61820E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 48.1267
  Index      = 2.43072
  Normalizat = 1.00243
  Prefactor  = 0.909298
 **********
 **   18 **HESSE 
 **********

 FCN=   6895.744     FROM HESSE     STATUS=OK            31 CALLS      289 TOTAL
                     EDM=   .23E-11    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     48.127        46.686        .57842E-04   -1.4319    
   2  Index         2.4307        .78604        .99326E-02   -.53967    
   3  Normalizat    1.0024        .18683        .25127E-03   -.92949    
   4  Prefactor     .90930        .22253        .31381E-03   -.95817    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.32491e-12
Minuit parameter uncertainties:
  1  46.7211
  2  0.790507
  3  0.186955
  4  0.222751
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/991395': 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): 0
logL (Free Index) = 6895.74384034
delta logL = 0.0618311595144

Extracting fit parameters...

4FGL J1139.0+4033
   Spectrum: PowerLaw
341    Prefactor:  4.813e+01  4.672e+01  1.000e-04  1.000e+04 ( 1.000e-13)
342        Index:  2.431e+00  7.905e-01  0.000e+00  1.000e+01 (-1.000e+00)
343        Scale:  6.779e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
693    Prefactor:  9.093e-01  2.228e-01  0.000e+00  1.000e+01 ( 1.000e+00)
694        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
695        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
692   Normalization:  1.002e+00  1.870e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 2.28
Ra Dec: 174.764 40.562
Photon Index (Free Index): 2.43 +/- 0.79
Photon Flux (Free Index): 3.53e-08 +/- 3.67e-08
Energy Flux (Free Index): 1.11e-05 +/- 1.09e-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/991395/cmap_HighResolution_651974401_652233601_4FGL_J1139.0+4033_daily_bin1592.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='9.83e-03', comment='SUCCESS', photon_flux='4.19e-08', energy_flux2='1.11e-05', photon_flux_error='3.97e-08', dlogl='6.18e-02', energy_flux='9.92e-06', photon_flux2='3.53e-08', job_status='DONE', time_completed='2021-09-04 07:32:23.887741', photon_index_error2='0.79', photon_index2='2.43', ts='2.17', fit_tolerance='1e-08', GAL='0.92', photon_index_error='0.00', photon_flux_upper_limit='1.25e-07', energy_flux_error2='1.09e-05', EG='0.99', time_epoch_completed='1630765943.89', return_code='0', job_id='991395', GAL2='0.91', EG2='1.00', return_code2='0', energy_flux_error='9.41e-06', photon_flux_error2='3.67e-08', ts2='2.28', photon_index='2.72' WHERE bin_id='1592' AND source_name='4FGL J1139.0+4033' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sat Sep  4 07:32:23 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0057>
Subject: Job 991395: <4FGL_J1139.0+4033_daily_bin1592> in cluster <slac> Done

Job <4FGL_J1139.0+4033_daily_bin1592> was submitted from host <rhel6-64a> by user <kocevski> in cluster <slac> at Sat Sep  4 07:17:12 2021
Job was executed on host(s) <bullet0057>, in queue <medium>, as user <kocevski> in cluster <slac> at Sat Sep  4 07:17:14 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sat Sep  4 07:17:14 2021
Terminated at Sat Sep  4 07:32:24 2021
Results reported at Sat Sep  4 07:32:24 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1139.0+4033_daily_bin1592 174.764 40.5617 651974401 652233601 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1139.0+4033 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   880.00 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             338.28 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   910 sec.
    Turnaround time :                            912 sec.

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

