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


Performing analysis on: 4FGL_J1238.3-1959_daily_bin1186
RA = 189.594, Dec = -19.9945
tmin = 546739201, tmax = 546998401
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='853031', job_status='RUN', time_executed='2021-09-06 02:22:50.406246', time_epoch_executed='1630920170.41' WHERE source_name='4FGL J1238.3-1959' and cadence='daily' and bin_id='1186'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/853031

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/853031/ft1_4FGL_J1238.3-1959_daily_bin1186.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/853031/ft2_4FGL_J1238.3-1959_daily_bin1186.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/853031/ft1_4FGL_J1238.3-1959_daily_bin1186.fits outfile=/scratch/kocevski/853031/ft1_filteredMKT_4FGL_J1238.3-1959_daily_bin1186.fits ra=189.594 dec=-19.9945 rad=12.0 tmin=546739201.0 tmax=546998401.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.70
user 3.44
sys 0.22

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/853031/ft2_4FGL_J1238.3-1959_daily_bin1186.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/853031/ft2_4FGL_J1238.3-1959_daily_bin1186.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/853031/ft1_filteredMKT_4FGL_J1238.3-1959_daily_bin1186.fits evtable="EVENTS" outfile="/scratch/kocevski/853031/ft1_filtered_4FGL_J1238.3-1959_daily_bin1186.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.53
user 0.35
sys 0.15

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/853031/ft1_filtered_4FGL_J1238.3-1959_daily_bin1186.fits" evtable="EVENTS" scfile=/scratch/kocevski/853031/ft2_4FGL_J1238.3-1959_daily_bin1186.fits sctable="SC_DATA" outfile=/scratch/kocevski/853031/ltcube_546739201_546998401_4FGL_J1238.3-1959_daily_bin1186.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/853031/ft2_4FGL_J1238.3-1959_daily_bin1186.fits
.....................!
real 13.81
user 13.40
sys 0.36

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/853031/ft1_filtered_4FGL_J1238.3-1959_daily_bin1186.fits evtable="EVENTS" scfile=/scratch/kocevski/853031/ft2_4FGL_J1238.3-1959_daily_bin1186.fits sctable="SC_DATA" expcube=/scratch/kocevski/853031/ltcube_546739201_546998401_4FGL_J1238.3-1959_daily_bin1186.fits outfile=/scratch/kocevski/853031/expmap_546739201_546998401_4FGL_J1238.3-1959_daily_bin1186.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/853031/ltcube_546739201_546998401_4FGL_J1238.3-1959_daily_bin1186.fits
.....................!
real 191.66
user 186.36
sys 4.80

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

Setting source of interest to:
4FGL J1238.3-1959 @ 189.594 -19.9945

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/853031/ft1_filtered_4FGL_J1238.3-1959_daily_bin1186.fits scfile=/scratch/kocevski/853031/ft2_4FGL_J1238.3-1959_daily_bin1186.fits outfile=/scratch/kocevski/853031/cmap_546739201_546998401_4FGL_J1238.3-1959_daily_bin1186.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=189.594 yref=-19.9945 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.54
user 0.39
sys 0.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/853031/ft1_filtered_4FGL_J1238.3-1959_daily_bin1186.fits scfile=/scratch/kocevski/853031/ft2_4FGL_J1238.3-1959_daily_bin1186.fits outfile=/scratch/kocevski/853031/cmap_HighResolution_546739201_546998401_4FGL_J1238.3-1959_daily_bin1186.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=189.594 yref=-19.9945 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.15

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/853031/ft1_filtered_4FGL_J1238.3-1959_daily_bin1186.fits evtable="EVENTS" scfile=/scratch/kocevski/853031/ft2_4FGL_J1238.3-1959_daily_bin1186.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/853031/Model_4FGL_J1238.3-1959_daily_bin1186.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/853031/ft1_filtered_4FGL_J1238.3-1959_daily_bin1186.fits.....................!
real 49.79
user 48.41
sys 1.22

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/853031/ft1_filtered_4FGL_J1238.3-1959_daily_bin1186.fits', '/scratch/kocevski/853031/ft2_4FGL_J1238.3-1959_daily_bin1186.fits', expMap='/scratch/kocevski/853031/expmap_546739201_546998401_4FGL_J1238.3-1959_daily_bin1186.fits', expCube='/scratch/kocevski/853031/ltcube_546739201_546998401_4FGL_J1238.3-1959_daily_bin1186.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/853031/Model_4FGL_J1238.3-1959_daily_bin1186.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1238.3-1959'

4FGL J1238.3-1959
   Spectrum: PowerLaw
307    Prefactor:  3.073e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
308        Index:  2.151e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
309        Scale:  1.503e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/853031/ft1_filtered_4FGL_J1238.3-1959_daily_bin1186.fits
Spacecraft file(s): /scratch/kocevski/853031/ft2_4FGL_J1238.3-1959_daily_bin1186.fits
Exposure map: /scratch/kocevski/853031/expmap_546739201_546998401_4FGL_J1238.3-1959_daily_bin1186.fits
Exposure cube: /scratch/kocevski/853031/ltcube_546739201_546998401_4FGL_J1238.3-1959_daily_bin1186.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/853031/Model_4FGL_J1238.3-1959_daily_bin1186.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) = 5580.47667574

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

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 'Prefactor '    12.609       1.0000         .10000E-03   10000.    
     3 'norm      '    5.6022       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10025E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    31.484       1.0000         .10000E-03   10000.    
     8 'Prefactor '    8.8963       1.0000         .10000E-03   10000.    
     9 'Prefactor '    17.101       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    2.5304       1.0000         .10000E-03   10000.    
    12 'Prefactor '    12.479       1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    1.8010       1.0000         .10000E-03   10000.    
    15 'Prefactor '    46.749       1.0000         .10000E-03   10000.    
    16 'norm      '    13.338       1.0000         .10000E-03   10000.    
    17 'norm      '    .10044E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    12.288       1.0000         .10000E-03   10000.    
    19 'norm      '    1.4519       1.0000         .10000E-03   10000.    
    20 'Normalizat'    1.8281       1.0000         .10000E-01   10.000    
    21 'Prefactor '    .74759       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6030E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   5580.469     FROM MIGRAD    STATUS=CONVERGED    423 CALLS     2154 TOTAL
                     EDM=   .35E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .2%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    15.955       -.51348E-05** at limit **
   2  Prefactor     12.607        20.768       -.15730E-05    .58149E-05
   3  norm          5.6022        6.7371        .16832E-05   -.12434E-03
   4  Prefactor     .10000E-03    1.9771        .28914E-07** at limit **
   5  Prefactor     .10000E-03    28.746        .55318E-06** at limit **
   6  Prefactor     .10000E-03    17.180        .43038E-05** at limit **
   7  Prefactor     31.497        30.751        .22270E-04    .74991E-04
   8  Prefactor     8.8558        65.365       -.11732E-03   -.92073E-05
   9  Prefactor     17.100        37.638       -.30918E-05   -.97629E-06
  10  Prefactor     .10000E-03    2.4086       -.20817E-07** at limit **
  11  Prefactor     2.5304        1.7081       -.34984E-07    .77726E-04
  12  Prefactor     12.479        13.083        .10196E-07    .12406E-04
  13  Prefactor     .10000E-03    13.264        .88667E-06** at limit **
  14  norm          1.8010        1.3817       -.65654E-08   -.13665E-03
  15  Prefactor     46.743        86.636       -.84247E-05    .29317E-05
  16  norm          13.338        11.705       -.36504E-06   -.17061E-04
  17  norm          .10000E-03    3.4723        .79399E-07** at limit **
  18  Prefactor     12.287        7.7020       -.19825E-06   -.89501E-03
  19  norm          1.4518        2.8489       -.50314E-06   -.66966E-03
  20  Normalizat    1.8282        .28931        .35788E-06    .55479E-04
  21  Prefactor     .74755        .13980        .18310E-05    .35190E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 12.6071
  norm       = 5.60223
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 31.4966
  Prefactor  = 8.85575
  Prefactor  = 17.0997
  Prefactor  = 0.0001
  Prefactor  = 2.53039
  Prefactor  = 12.4792
  Prefactor  = 0.0001
  norm       = 1.80098
  Prefactor  = 46.7428
  norm       = 13.3383
  norm       = 0.0001
  Prefactor  = 12.2872
  norm       = 1.45182
  Normalizat = 1.82818
  Prefactor  = 0.747549
 **********
 **   18 **HESSE 
 **********

 FCN=   5580.469     FROM HESSE     STATUS=OK           317 CALLS     2471 TOTAL
                     EDM=   .68E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    15.954        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     12.607        20.773        .11281E-03   -1.4998    
   3  norm          5.6022        6.7295        .16973E-03   -1.5235    
   4  Prefactor     .10000E-03    1.9814        .10258E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10000E-03    28.759        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    17.194        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     31.497        30.758        .71409E-04   -1.4585    
   8  Prefactor     8.8558        65.569        .13438E-03   -1.5113    
   9  Prefactor     17.100        37.664        .96851E-04   -1.4881    
  10  Prefactor     .10000E-03    2.4171        .11320E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     2.5304        1.7082        .78098E-04   -1.5390    
  12  Prefactor     12.479        13.084        .11339E-03   -1.5001    
  13  Prefactor     .10000E-03    13.428        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          1.8010        1.3736        .73838E-04   -1.5440    
  15  Prefactor     46.743        86.602        .58643E-04   -1.4340    
  16  norm          13.338        11.709        .10967E-03   -1.4977    
  17  norm          .10000E-03    3.4806        .13575E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     12.287        7.6955        .57138E-03   -1.5007    
  19  norm          1.4518        2.8231        .17013E-03   -1.5467    
  20  Normalizat    1.8282        .33776        .32184E-03   -.68930    
  21  Prefactor     .74755        .16303        .22479E-03   -1.0169    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 6.82874e-10
Minuit parameter uncertainties:
  1  9.81743e-07
  2  20.7846
  3  6.73038
  4  3.46664e-06
  5  2.39376e-05
  6  2.27569e-05
  7  30.7731
  8  48.2678
  9  37.7168
  10  3.77216e-06
  11  1.70827
  12  13.0871
  13  4.60017e-05
  14  1.3736
  15  86.8365
  16  11.711
  17  1.29346e-05
  18  7.69616
  19  2.82333
  20  0.338196
  21  0.16313
Done.

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

Extracting fit parameters...

4FGL J1238.3-1959
   Spectrum: PowerLaw
307    Prefactor:  1.248e+01  1.309e+01  1.000e-04  1.000e+04 ( 1.000e-13)
308        Index:  2.151e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
309        Scale:  1.503e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
600    Prefactor:  7.475e-01  1.631e-01  0.000e+00  1.000e+01 ( 1.000e+00)
601        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
602        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
599   Normalization:  1.828e+00  3.382e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 2.45
Ra Dec: 189.594 -19.994
Photon Index (Fixed Index): 2.15 +/- 0.00
Photon Flux (Fixed Index): 3.69e-08 +/- 3.87e-08
Energy Flux (Fixed Index): 1.82e-05 +/- 1.91e-05

TS (Fixed Index): 2.45
Ra Dec: 189.594 -19.994
Photon Flux Upper Limit: 1.47e-07 ph cm-2 s-1
Energy Flux Upper Limit: 1.12e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/853031/likelihoodResults_546739201_546998401_4FGL_J1238.3-1959_daily_bin1186.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) = 5580.23691705
delta logL = 0.232569628639

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 5580.22237589
delta logL = 0.247110785888

Fit tolerance = 1e-08

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

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

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   5580.222     FROM MIGRAD    STATUS=CONVERGED     57 CALLS      239 TOTAL
                     EDM=   .91E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     15.740        45.868        .25246E-02    .99969E-05
   2  Index         1.6851        1.4794        .20799        .29251E-04
   3  Normalizat    1.8422        .29452        .72533E-01    .67208E-03
   4  Prefactor     .74424        .13807        .42986E-01    .83070E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 15.7399
  Index      = 1.6851
  Normalizat = 1.84223
  Prefactor  = 0.744244
 **********
 **   18 **HESSE 
 **********

 FCN=   5580.222     FROM HESSE     STATUS=OK            29 CALLS      268 TOTAL
                     EDM=   .88E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     15.740        16.388        .10099E-03   -1.4914    
   2  Index         1.6851        .62647        .10450E-01   -.72479    
   3  Normalizat    1.8422        .33418        .32087E-03   -.68566    
   4  Prefactor     .74424        .15944        .22523E-03   -1.0182    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 8.78558e-10
Minuit parameter uncertainties:
  1  16.3929
  2  0.629427
  3  0.334599
  4  0.159535
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/853031': 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) = 5580.22237348
delta logL = 0.247113197133

Extracting fit parameters...

4FGL J1238.3-1959
   Spectrum: PowerLaw
307    Prefactor:  1.574e+01  1.639e+01  1.000e-04  1.000e+04 ( 1.000e-13)
308        Index:  1.685e+00  6.294e-01  0.000e+00  1.000e+01 (-1.000e+00)
309        Scale:  1.503e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
600    Prefactor:  7.442e-01  1.595e-01  0.000e+00  1.000e+01 ( 1.000e+00)
601        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
602        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
599   Normalization:  1.842e+00  3.346e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 2.94
Ra Dec: 189.594 -19.994
Photon Index (Free Index): 1.69 +/- 0.63
Photon Flux (Free Index): 2.19e-08 +/- 2.98e-08
Energy Flux (Free Index): 3.75e-05 +/- 5.82e-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/853031/cmap_HighResolution_546739201_546998401_4FGL_J1238.3-1959_daily_bin1186.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='1.12e-02', comment='SUCCESS', photon_flux='3.69e-08', energy_flux2='3.75e-05', photon_flux_error='3.87e-08', dlogl='2.47e-01', energy_flux='1.82e-05', photon_flux2='2.19e-08', job_status='DONE', time_completed='2021-09-06 02:32:50.288577', photon_index_error2='0.63', photon_index2='1.69', ts='2.45', fit_tolerance='1e-08', GAL='0.75', photon_index_error='0.00', photon_flux_upper_limit='1.47e-07', energy_flux_error2='5.82e-05', EG='1.83', time_epoch_completed='1630920770.29', return_code='0', job_id='853031', GAL2='0.74', EG2='1.84', return_code2='0', energy_flux_error='1.91e-05', photon_flux_error2='2.98e-08', ts2='2.94', photon_index='2.15' WHERE bin_id='1186' AND source_name='4FGL J1238.3-1959' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 02:32:50 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0153>
Subject: Job 853031: <4FGL_J1238.3-1959_daily_bin1186> in cluster <slac> Done

Job <4FGL_J1238.3-1959_daily_bin1186> was submitted from host <rhel6-64h> by user <kocevski> in cluster <slac> at Mon Sep  6 02:20:44 2021
Job was executed on host(s) <bullet0153>, in queue <medium>, as user <kocevski> in cluster <slac> at Mon Sep  6 02:21:26 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Mon Sep  6 02:21:26 2021
Terminated at Mon Sep  6 02:32:51 2021
Results reported at Mon Sep  6 02:32:51 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1238.3-1959_daily_bin1186 189.594 -19.9945 546739201 546998401 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1238.3-1959 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   596.27 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             265.78 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   684 sec.
    Turnaround time :                            727 sec.

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

