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


Performing analysis on: 4FGL_J1338.0-4159_daily_bin1482
RA = 204.522, Dec = -41.9953
tmin = 623462401, tmax = 623721601
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='837187', job_status='RUN', time_executed='2021-09-08 06:42:45.103394', time_epoch_executed='1631108565.1' WHERE source_name='4FGL J1338.0-4159' and cadence='daily' and bin_id='1482'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/837187

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/837187/ft1_4FGL_J1338.0-4159_daily_bin1482.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/837187/ft2_4FGL_J1338.0-4159_daily_bin1482.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/837187/ft1_4FGL_J1338.0-4159_daily_bin1482.fits outfile=/scratch/kocevski/837187/ft1_filteredMKT_4FGL_J1338.0-4159_daily_bin1482.fits ra=204.522 dec=-41.9953 rad=12.0 tmin=623462401.0 tmax=623721601.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 2.74
user 2.51
sys 0.19

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/837187/ft2_4FGL_J1338.0-4159_daily_bin1482.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/837187/ft2_4FGL_J1338.0-4159_daily_bin1482.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/837187/ft1_filteredMKT_4FGL_J1338.0-4159_daily_bin1482.fits evtable="EVENTS" outfile="/scratch/kocevski/837187/ft1_filtered_4FGL_J1338.0-4159_daily_bin1482.fits" apply_filter=yes overwrite=yes header_obstimes=yes tstart=0.0 tstop=0.0 gtifile="default" chatter=3 clobber=yes debug=no gui=no mode="ql"

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

This is gtmktime version HEAD
Applying GTI filter:
IN_SAA!=T && LIVETIME>0 && gtifilter('/nfs/farm/g/glast/g/LCRepository/Likelihood/GTIs/nogrb.gti',(START+STOP)/2) && (angsep(RA_SUN,DEC_SUN,RA_ZENITH,DEC_ZENITH)>115 || gtifilter('/nfs/farm/g/glast/g/LCRepository/Likelihood/GTIs/nosolarflares.gti',(START+STOP)/2))
real 0.50
user 0.34
sys 0.15

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/837187/ft1_filtered_4FGL_J1338.0-4159_daily_bin1482.fits" evtable="EVENTS" scfile=/scratch/kocevski/837187/ft2_4FGL_J1338.0-4159_daily_bin1482.fits sctable="SC_DATA" outfile=/scratch/kocevski/837187/ltcube_623462401_623721601_4FGL_J1338.0-4159_daily_bin1482.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/837187/ft2_4FGL_J1338.0-4159_daily_bin1482.fits
.....................!
real 15.16
user 14.76
sys 0.33

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/837187/ft1_filtered_4FGL_J1338.0-4159_daily_bin1482.fits evtable="EVENTS" scfile=/scratch/kocevski/837187/ft2_4FGL_J1338.0-4159_daily_bin1482.fits sctable="SC_DATA" expcube=/scratch/kocevski/837187/ltcube_623462401_623721601_4FGL_J1338.0-4159_daily_bin1482.fits outfile=/scratch/kocevski/837187/expmap_623462401_623721601_4FGL_J1338.0-4159_daily_bin1482.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/837187/ltcube_623462401_623721601_4FGL_J1338.0-4159_daily_bin1482.fits
.....................!
real 191.99
user 185.86
sys 4.46

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
Extended source CenA Lobes in ROI, make sure /nfs/farm/g/glast/g/LCRepository/Likelihood/ExtendedSources/Extended_archive_v18/Templates/CenALobes.fits is the correct path to the extended template.
Extended source G296.5+10.0 in ROI with RadialDisk spatial model.
Extended source HESS J1303-631 in ROI with RadialGaussian spatial model.
Extended source FGES J1409.1-6121 in ROI with RadialDisk spatial model.
Extended source HESS J1420-607 in ROI with RadialDisk spatial model.
Added 268 point sources and 5 extended sources
If using unbinned likelihood you will need to rerun gtdiffrsp for the extended sources or rerun the makeModel function with optional argument psForce=True

Setting source of interest to:
4FGL J1338.0-4159 @ 204.522 -41.9953

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/837187/ft1_filtered_4FGL_J1338.0-4159_daily_bin1482.fits scfile=/scratch/kocevski/837187/ft2_4FGL_J1338.0-4159_daily_bin1482.fits outfile=/scratch/kocevski/837187/cmap_623462401_623721601_4FGL_J1338.0-4159_daily_bin1482.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=204.522 yref=-41.9953 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.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/837187/ft1_filtered_4FGL_J1338.0-4159_daily_bin1482.fits scfile=/scratch/kocevski/837187/ft2_4FGL_J1338.0-4159_daily_bin1482.fits outfile=/scratch/kocevski/837187/cmap_HighResolution_623462401_623721601_4FGL_J1338.0-4159_daily_bin1482.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=204.522 yref=-41.9953 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.14

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/837187/ft1_filtered_4FGL_J1338.0-4159_daily_bin1482.fits evtable="EVENTS" scfile=/scratch/kocevski/837187/ft2_4FGL_J1338.0-4159_daily_bin1482.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/837187/Model_4FGL_J1338.0-4159_daily_bin1482.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 CenA Lobes
adding source EG_v02
adding source FGES J1409.1-6121
adding source G296.5+10.0
adding source GAL_V02
adding source HESS J1303-631
adding source HESS J1420-607
Working on...
/scratch/kocevski/837187/ft1_filtered_4FGL_J1338.0-4159_daily_bin1482.fits....................!
real 99.74
user 98.12
sys 1.18

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/837187/ft1_filtered_4FGL_J1338.0-4159_daily_bin1482.fits', '/scratch/kocevski/837187/ft2_4FGL_J1338.0-4159_daily_bin1482.fits', expMap='/scratch/kocevski/837187/expmap_623462401_623721601_4FGL_J1338.0-4159_daily_bin1482.fits', expCube='/scratch/kocevski/837187/ltcube_623462401_623721601_4FGL_J1338.0-4159_daily_bin1482.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/837187/Model_4FGL_J1338.0-4159_daily_bin1482.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1338.0-4159'

4FGL J1338.0-4159
   Spectrum: PowerLaw
369    Prefactor:  9.822e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-15)
370        Index:  1.972e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
371        Scale:  4.081e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/837187/ft1_filtered_4FGL_J1338.0-4159_daily_bin1482.fits
Spacecraft file(s): /scratch/kocevski/837187/ft2_4FGL_J1338.0-4159_daily_bin1482.fits
Exposure map: /scratch/kocevski/837187/expmap_623462401_623721601_4FGL_J1338.0-4159_daily_bin1482.fits
Exposure cube: /scratch/kocevski/837187/ltcube_623462401_623721601_4FGL_J1338.0-4159_daily_bin1482.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/837187/Model_4FGL_J1338.0-4159_daily_bin1482.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) = 4661.47181163

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10943E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    45.384       1.0000         .10000E-03   10000.    
     3 'Prefactor '    29.830       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     5 'norm      '    33.412       1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10379E-03   1.0000         .10000E-03   10000.    
     7 'norm      '    14.004       1.0000         .10000E-03   10000.    
     8 'norm      '    4.4596       1.0000         .10000E-03   10000.    
     9 'Prefactor '    298.44       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10527E-03   1.0000         .10000E-03   10000.    
    11 'norm      '    .10558E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10699E-03   1.0000         .10000E-03   10000.    
    13 'Prefactor '    194.30       1.0000         .10000E-03   10000.    
    14 'Prefactor '    .13130E-02   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .11117E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    .10090E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    .10101E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10032E-03   1.0000         .10000E-03   10000.    
    19 'Normalizat'    2.1277       1.0000         .10000E-01   10.000    
    20 'Prefactor '    .92755       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .9490E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   4661.245     FROM MIGRAD    STATUS=CONVERGED    382 CALLS     2267 TOTAL
                     EDM=   .36E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .1%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    24.523        .85599E-05** at limit **
   2  Prefactor     45.166        172.23       -.31856E-03    .11045E-04
   3  Prefactor     29.814        38.093       -.17109E-04   -.97542E-08
   4  Prefactor     .10000E-03    6.8593        .13802E-06** at limit **
   5  norm          33.408        46.897       -.36426E-05   -.68624E-04
   6  Prefactor     .10000E-03    40.937        .11802E-04** at limit **
   7  norm          14.000        24.182       -.26970E-05   -.35233E-05
   8  norm          4.4659        10.554       -.16851E-05   -.10424E-03
   9  Prefactor     298.50        515.44        .34516E-04    .27434E-05
  10  Prefactor     .10000E-03    60.063       -.11928E-04** at limit **
  11  norm          .10000E-03    38.431        .86803E-06** at limit **
  12  Prefactor     .10000E-03    38.481        .10394E-05** at limit **
  13  Prefactor     194.34        155.15        .28749E-04    .67192E-05
  14  Prefactor     .10000E-03    617.53       -.51150E-03** at limit **
  15  Prefactor     .10000E-03    31.821       -.24362E-04** at limit **
  16  Prefactor     .10000E-03    16.220       -.63913E-06** at limit **
  17  norm          .10000E-03    .67816E-01   -.11147E-06** at limit **
  18  Prefactor     .10000E-03    49.257        .19749E-04** at limit **
  19  Normalizat    2.1303        .51923        .29254E-05    .11150E-03
  20  Prefactor     .92704        .11878        .32201E-05   -.11341E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 45.1655
  Prefactor  = 29.8143
  Prefactor  = 0.0001
  norm       = 33.4083
  Prefactor  = 0.0001
  norm       = 14
  norm       = 4.46589
  Prefactor  = 298.5
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 194.339
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Normalizat = 2.13028
  Prefactor  = 0.927043
 **********
 **   18 **HESSE 
 **********

 FCN=   4661.245     FROM HESSE     STATUS=OK           283 CALLS     2550 TOTAL
                     EDM=   .88E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    24.547        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     45.166        172.60        .29757E-03   -1.4363    
   3  Prefactor     29.814        38.108        .73357E-04   -1.4615    
   4  Prefactor     .10000E-03    6.8611        .17464E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  norm          33.408        46.812        .69324E-04   -1.4551    
   6  Prefactor     .10000E-03    41.534        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  norm          14.000        24.284        .10703E-03   -1.4959    
   8  norm          4.4659        10.623        .19067E-03   -1.5285    
   9  Prefactor     298.50        516.19        .11754E-03   -1.2235    
  10  Prefactor     .10000E-03    60.068        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  norm          .10000E-03    38.448        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10000E-03    38.492        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     194.34        155.41        .14490E-03   -1.2911    
  14  Prefactor     .10000E-03    617.75        .20572E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .10000E-03    31.825        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     .10000E-03    16.277        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          .10000E-03    .81912E-01    .34422E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .10000E-03    49.266        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Normalizat    2.1303        .62041        .50264E-03   -.61324    
  20  Prefactor     .92704        .14272        .16221E-03   -.95202    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 8.81606e-10
Minuit parameter uncertainties:
  1  0.000213418
  2  174.567
  3  38.1388
  4  5.17574e-05
  5  46.8639
  6  0.000131528
  7  24.3007
  8  10.6272
  9  524.456
  10  8.307e-05
  11  6.97414e-05
  12  7.04763e-05
  13  155.745
  14  0.000313068
  15  3.50661e-05
  16  8.90629e-05
  17  2.93047e-06
  18  7.95131e-05
  19  0.622824
  20  0.142776
Done.

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

Extracting fit parameters...

4FGL J1338.0-4159
   Spectrum: PowerLaw
369    Prefactor:  2.985e+02  5.245e+02  1.000e-04  1.000e+04 ( 1.000e-15)
370        Index:  1.972e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
371        Scale:  4.081e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
940    Prefactor:  9.270e-01  1.428e-01  0.000e+00  1.000e+01 ( 1.000e+00)
941        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
942        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
932   Normalization:  2.130e+00  6.228e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.46
Ra Dec: 204.522 -41.995
Photon Flux Upper Limit: 2.60e-07 ph cm-2 s-1
Energy Flux Upper Limit: 1.95e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/837187/likelihoodResults_623462401_623721601_4FGL_J1338.0-4159_daily_bin1482.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) = 4660.34268952
delta logL = 0.902558864969

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 4660.31920888
delta logL = 0.926039504669

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    51.765       1.0000         .10000E-03   10000.    
     2 'Index     '    3.0530       1.0000          .0000       10.000    
     3 'Normalizat'    1.9526       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .94906       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .9490E+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.

 FCN=   4660.319     FROM MIGRAD    STATUS=CONVERGED     91 CALLS      316 TOTAL
                     EDM=   .96E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     51.864        1471.0        .55743E-04    .34671E-05
   2  Index         3.0526        3.2519        .29732E-02    .29893E-04
   3  Normalizat    1.9508        .65653        .51841E-03   -.50307E-04
   4  Prefactor     .94942        .14562        .16030E-03    .18967E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 51.8643
  Index      = 3.05257
  Normalizat = 1.95083
  Prefactor  = 0.949424
 **********
 **   18 **HESSE 
 **********

 FCN=   4660.319     FROM HESSE     STATUS=OK            25 CALLS      341 TOTAL
                     EDM=   .27E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     51.864        129.73        .22297E-05   -1.4266    
   2  Index         3.0526        .82270        .11893E-03   -.40007    
   3  Normalizat    1.9508        .62089        .20737E-04   -.65789    
   4  Prefactor     .94942        .13966        .32061E-04   -.94435    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.69698e-10
Minuit parameter uncertainties:
  1  130.445
  2  0.827142
  3  0.623473
  4  0.13971
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/837187': 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) = 4660.31920454
delta logL = 0.926043846275

Extracting fit parameters...

4FGL J1338.0-4159
   Spectrum: PowerLaw
369    Prefactor:  5.186e+01  1.304e+02  1.000e-04  1.000e+04 ( 1.000e-15)
370        Index:  3.053e+00  8.271e-01  0.000e+00  1.000e+01 (-1.000e+00)
371        Scale:  4.081e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
940    Prefactor:  9.494e-01  1.397e-01  0.000e+00  1.000e+01 ( 1.000e+00)
941        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
942        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
932   Normalization:  1.951e+00  6.235e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 2.41
Ra Dec: 204.522 -41.995
Photon Index (Free Index): 3.05 +/- 0.83
Photon Flux (Free Index): 2.09e-07 +/- 1.78e-07
Energy Flux (Free Index): 4.07e-05 +/- 3.30e-05

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/837187/cmap_HighResolution_623462401_623721601_4FGL_J1338.0-4159_daily_bin1482.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='1.95e-02', comment='SUCCESS', energy_flux2='4.07e-05', dlogl='9.26e-01', photon_flux2='2.09e-07', job_status='DONE', time_completed='2021-09-08 06:56:38.800215', photon_index_error2='0.83', photon_index2='3.05', ts='0.46', fit_tolerance='1e-08', GAL='0.93', photon_index_error='0.00', photon_flux_upper_limit='2.60e-07', energy_flux_error2='3.30e-05', EG='2.13', time_epoch_completed='1631109398.8', return_code='0', job_id='837187', GAL2='0.95', EG2='1.95', return_code2='0', photon_flux_error2='1.78e-07', ts2='2.41', photon_index='1.97' WHERE bin_id='1482' AND source_name='4FGL J1338.0-4159' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Wed Sep  8 06:56:38 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0298>
Subject: Job 837187: <4FGL_J1338.0-4159_daily_bin1482> in cluster <slac> Done

Job <4FGL_J1338.0-4159_daily_bin1482> was submitted from host <rhel6-64f> by user <kocevski> in cluster <slac> at Wed Sep  8 06:40:27 2021
Job was executed on host(s) <bullet0298>, in queue <medium>, as user <kocevski> in cluster <slac> at Wed Sep  8 06:41:11 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Wed Sep  8 06:41:11 2021
Terminated at Wed Sep  8 06:56:39 2021
Results reported at Wed Sep  8 06:56:39 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1338.0-4159_daily_bin1482 204.522 -41.9953 623462401 623721601 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1338.0-4159 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   773.04 sec.
    Max Memory :                                 1258 MB
    Average Memory :                             351.73 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   928 sec.
    Turnaround time :                            972 sec.

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

