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


Performing analysis on: 4FGL_J1238.3-1959_daily_bin588
RA = 189.594, Dec = -19.9945
tmin = 391737601, tmax = 391996801
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='849597', job_status='RUN', time_executed='2021-09-06 02:13:54.831457', time_epoch_executed='1630919634.83' WHERE source_name='4FGL J1238.3-1959' and cadence='daily' and bin_id='588'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/849597

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/849597/ft1_4FGL_J1238.3-1959_daily_bin588.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/849597/ft2_4FGL_J1238.3-1959_daily_bin588.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/849597/ft1_4FGL_J1238.3-1959_daily_bin588.fits outfile=/scratch/kocevski/849597/ft1_filteredMKT_4FGL_J1238.3-1959_daily_bin588.fits ra=189.594 dec=-19.9945 rad=12.0 tmin=391737601.0 tmax=391996801.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.34
user 3.09
sys 0.22

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/849597/ft2_4FGL_J1238.3-1959_daily_bin588.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/849597/ft1_filteredMKT_4FGL_J1238.3-1959_daily_bin588.fits evtable="EVENTS" outfile="/scratch/kocevski/849597/ft1_filtered_4FGL_J1238.3-1959_daily_bin588.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.51
user 0.32
sys 0.16

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/849597/ft1_filtered_4FGL_J1238.3-1959_daily_bin588.fits" evtable="EVENTS" scfile=/scratch/kocevski/849597/ft2_4FGL_J1238.3-1959_daily_bin588.fits sctable="SC_DATA" outfile=/scratch/kocevski/849597/ltcube_391737601_391996801_4FGL_J1238.3-1959_daily_bin588.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/849597/ft2_4FGL_J1238.3-1959_daily_bin588.fits
.....................!
real 12.57
user 12.20
sys 0.32

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/849597/ft1_filtered_4FGL_J1238.3-1959_daily_bin588.fits evtable="EVENTS" scfile=/scratch/kocevski/849597/ft2_4FGL_J1238.3-1959_daily_bin588.fits sctable="SC_DATA" expcube=/scratch/kocevski/849597/ltcube_391737601_391996801_4FGL_J1238.3-1959_daily_bin588.fits outfile=/scratch/kocevski/849597/expmap_391737601_391996801_4FGL_J1238.3-1959_daily_bin588.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/849597/ltcube_391737601_391996801_4FGL_J1238.3-1959_daily_bin588.fits
.....................!
real 191.14
user 185.19
sys 5.43

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/849597/ft1_filtered_4FGL_J1238.3-1959_daily_bin588.fits scfile=/scratch/kocevski/849597/ft2_4FGL_J1238.3-1959_daily_bin588.fits outfile=/scratch/kocevski/849597/cmap_391737601_391996801_4FGL_J1238.3-1959_daily_bin588.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.55
user 0.36
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/849597/ft1_filtered_4FGL_J1238.3-1959_daily_bin588.fits scfile=/scratch/kocevski/849597/ft2_4FGL_J1238.3-1959_daily_bin588.fits outfile=/scratch/kocevski/849597/cmap_HighResolution_391737601_391996801_4FGL_J1238.3-1959_daily_bin588.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.57
user 0.40
sys 0.14

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/849597/ft1_filtered_4FGL_J1238.3-1959_daily_bin588.fits evtable="EVENTS" scfile=/scratch/kocevski/849597/ft2_4FGL_J1238.3-1959_daily_bin588.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/849597/Model_4FGL_J1238.3-1959_daily_bin588.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/849597/ft1_filtered_4FGL_J1238.3-1959_daily_bin588.fits.....................!
real 56.35
user 54.94
sys 1.12

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/849597/ft1_filtered_4FGL_J1238.3-1959_daily_bin588.fits', '/scratch/kocevski/849597/ft2_4FGL_J1238.3-1959_daily_bin588.fits', expMap='/scratch/kocevski/849597/expmap_391737601_391996801_4FGL_J1238.3-1959_daily_bin588.fits', expCube='/scratch/kocevski/849597/ltcube_391737601_391996801_4FGL_J1238.3-1959_daily_bin588.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/849597/Model_4FGL_J1238.3-1959_daily_bin588.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/849597/ft1_filtered_4FGL_J1238.3-1959_daily_bin588.fits
Spacecraft file(s): /scratch/kocevski/849597/ft2_4FGL_J1238.3-1959_daily_bin588.fits
Exposure map: /scratch/kocevski/849597/expmap_391737601_391996801_4FGL_J1238.3-1959_daily_bin588.fits
Exposure cube: /scratch/kocevski/849597/ltcube_391737601_391996801_4FGL_J1238.3-1959_daily_bin588.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/849597/Model_4FGL_J1238.3-1959_daily_bin588.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) = 6705.89766467

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10007E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    14.358       1.0000         .10000E-03   10000.    
     3 'norm      '    8.8573       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10071E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    43.889       1.0000         .10000E-03   10000.    
     6 'Prefactor '    .12047E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .21261E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10188E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    1.9439       1.0000         .10000E-03   10000.    
    10 'Prefactor '    4.7407       1.0000         .10000E-03   10000.    
    11 'Prefactor '    6.5169       1.0000         .10000E-03   10000.    
    12 'Prefactor '    10.481       1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    1.8135       1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    .10006E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    5.6950       1.0000         .10000E-03   10000.    
    18 'Prefactor '    5.0165       1.0000         .10000E-03   10000.    
    19 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    20 'Normalizat'    .52549       1.0000         .10000E-01   10.000    
    21 'Prefactor '    1.1903       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=   6705.895     FROM MIGRAD    STATUS=CONVERGED    443 CALLS     2162 TOTAL
                     EDM=   .29E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .4%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    12.584        .17840E-05** at limit **
   2  Prefactor     14.337        20.317        .52350E-06    .45166E-05
   3  norm          8.8623        6.8813        .21910E-05   -.10949E-03
   4  Prefactor     .10000E-03    3.3824        .55867E-07** at limit **
   5  Prefactor     43.859        48.637       -.29880E-04   -.20435E-04
   6  Prefactor     .10000E-03    73.653       -.15978E-05** at limit **
   7  Prefactor     .10002E-03    70.253        .53369E-05** at limit **
   8  Prefactor     .10000E-03    28.949        .17667E-05** at limit **
   9  Prefactor     1.9339        85.386       -.15741E-04   -.38507E-04
  10  Prefactor     4.7401        5.9612        .21419E-05   -.24314E-03
  11  Prefactor     6.5168        2.6858       -.34210E-06    .68064E-04
  12  Prefactor     10.483        11.636       -.25460E-06   -.11908E-04
  13  Prefactor     .10000E-03    11.092       -.14257E-05** at limit **
  14  norm          1.8136        1.0101        .41475E-07    .74384E-04
  15  Prefactor     .10000E-03    18.846       -.22374E-05** at limit **
  16  norm          .10000E-03    3.5587       -.14860E-06** at limit **
  17  norm          5.6955        4.7365       -.24635E-05   -.56614E-04
  18  Prefactor     5.0170        4.7071       -.12650E-05   -.98785E-04
  19  norm          .10000E-03    1.0461        .39818E-07** at limit **
  20  Normalizat    .52522        .25892       -.13549E-05    .59417E-04
  21  Prefactor     1.1903        .13113        .16726E-05   -.59164E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 14.3373
  norm       = 8.86234
  Prefactor  = 0.0001
  Prefactor  = 43.859
  Prefactor  = 0.000100001
  Prefactor  = 0.000100025
  Prefactor  = 0.0001
  Prefactor  = 1.93385
  Prefactor  = 4.74014
  Prefactor  = 6.51676
  Prefactor  = 10.4829
  Prefactor  = 0.0001
  norm       = 1.81363
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 5.69548
  Prefactor  = 5.01697
  norm       = 0.0001
  Normalizat = 0.525216
  Prefactor  = 1.19033
 **********
 **   18 **HESSE 
 **********

 FCN=   6705.895     FROM HESSE     STATUS=OK           321 CALLS     2483 TOTAL
                     EDM=   .60E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    12.585        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     14.337        20.381        .10570E-03   -1.4950    
   3  norm          8.8623        6.8944        .13468E-03   -1.5112    
   4  Prefactor     .10000E-03    3.4669        .29399E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     43.859        48.680        .60516E-04   -1.4382    
   6  Prefactor     .10000E-03    74.561        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10002E-03    73.561        .36285E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .10000E-03    29.028        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     1.9339        85.769        .29773E-03   -1.5430    
  10  Prefactor     4.7401        5.9249        .18480E-03   -1.5272    
  11  Prefactor     6.5168        2.6844        .80780E-04   -1.5197    
  12  Prefactor     10.483        11.623        .12376E-03   -1.5060    
  13  Prefactor     .10000E-03    11.208        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          1.8136        1.0036        .59089E-04   -1.5439    
  15  Prefactor     .10000E-03    18.844        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          .10000E-03    3.5793        .15085E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          5.6955        4.7306        .15254E-03   -1.5231    
  18  Prefactor     5.0170        4.7019        .16174E-03   -1.5260    
  19  norm          .10000E-03    1.0645        .81777E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Normalizat    .52522        .27144        .47254E-03   -1.1126    
  21  Prefactor     1.1903        .14023        .16672E-03   -.86629    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 5.98885e-10
Minuit parameter uncertainties:
  1  2.91802e-06
  2  20.3908
  3  6.89505
  4  1.65902e-05
  5  48.7246
  6  0.000447042
  7  0.00271227
  8  0.000216136
  9  25.7965
  10  5.92562
  11  2.68442
  12  11.6255
  13  4.36791e-05
  14  1.00357
  15  3.00426e-05
  16  1.4796e-06
  17  4.73089
  18  4.70225
  19  1.75235e-06
  20  0.272131
  21  0.14027
Done.

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

Extracting fit parameters...

4FGL J1238.3-1959
   Spectrum: PowerLaw
307    Prefactor:  1.048e+01  1.163e+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:  1.190e+00  1.403e-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:  5.252e-01  2.721e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 1.30
Ra Dec: 189.594 -19.994
Photon Index (Fixed Index): 2.15 +/- 0.00
Photon Flux (Fixed Index): 3.10e-08 +/- 3.44e-08
Energy Flux (Fixed Index): 1.53e-05 +/- 1.70e-05

TS (Fixed Index): 1.30
Ra Dec: 189.594 -19.994
Photon Flux Upper Limit: 1.15e-07 ph cm-2 s-1
Energy Flux Upper Limit: 8.76e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/849597/likelihoodResults_391737601_391996801_4FGL_J1238.3-1959_daily_bin588.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) = 6705.81416344
delta logL = 0.0804899021186

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 6705.8103785
delta logL = 0.0842748437781

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    8.0179       1.0000         .10000E-03   10000.    
     2 'Index     '    2.4606       1.0000          .0000       10.000    
     3 'Normalizat'    .51121       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.1939       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.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   6705.810     FROM MIGRAD    STATUS=CONVERGED     87 CALLS      298 TOTAL
                     EDM=   .37E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     8.0163        12.362        .14160E-03   -.21790E-03
   2  Index         2.4615        .84345        .67111E-02   -.77316E-04
   3  Normalizat    .51173        .27028        .47845E-03   -.29493E-03
   4  Prefactor     1.1937        .13909        .16650E-03   -.83198E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 8.01633
  Index      = 2.46151
  Normalizat = 0.511728
  Prefactor  = 1.19371
 **********
 **   18 **HESSE 
 **********

 FCN=   6705.810     FROM HESSE     STATUS=OK            25 CALLS      323 TOTAL
                     EDM=   .41E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     8.0163        11.326        .56639E-05   -1.5142    
   2  Index         2.4615        .77292        .26844E-03   -.53251    
   3  Normalizat    .51173        .26997        .19138E-04   -1.1187    
   4  Prefactor     1.1937        .13900        .33300E-04   -.86525    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 4.06724e-10
Minuit parameter uncertainties:
  1  11.3294
  2  0.77713
  3  0.270667
  4  0.139041
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/849597': 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) = 6705.81037494
delta logL = 0.0842784003162

Extracting fit parameters...

4FGL J1238.3-1959
   Spectrum: PowerLaw
307    Prefactor:  8.016e+00  1.133e+01  1.000e-04  1.000e+04 ( 1.000e-13)
308        Index:  2.462e+00  7.771e-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:  1.194e+00  1.390e-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:  5.117e-01  2.707e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 1.47
Ra Dec: 189.594 -19.994
Photon Index (Free Index): 2.46 +/- 0.78
Photon Flux (Free Index): 4.33e-08 +/- 5.09e-08
Energy Flux (Free Index): 1.31e-05 +/- 1.40e-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/849597/cmap_HighResolution_391737601_391996801_4FGL_J1238.3-1959_daily_bin588.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='8.76e-03', comment='SUCCESS', photon_flux='3.10e-08', energy_flux2='1.31e-05', photon_flux_error='3.44e-08', dlogl='8.43e-02', energy_flux='1.53e-05', photon_flux2='4.33e-08', job_status='DONE', time_completed='2021-09-06 02:24:45.614653', photon_index_error2='0.78', photon_index2='2.46', ts='1.30', fit_tolerance='1e-08', GAL='1.19', photon_index_error='0.00', photon_flux_upper_limit='1.15e-07', energy_flux_error2='1.40e-05', EG='0.53', time_epoch_completed='1630920285.61', return_code='0', job_id='849597', GAL2='1.19', EG2='0.51', return_code2='0', energy_flux_error='1.70e-05', photon_flux_error2='5.09e-08', ts2='1.47', photon_index='2.15' WHERE bin_id='588' AND source_name='4FGL J1238.3-1959' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 02:24:45 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0275>
Subject: Job 849597: <4FGL_J1238.3-1959_daily_bin588> in cluster <slac> Done

Job <4FGL_J1238.3-1959_daily_bin588> was submitted from host <rhel6-64e> by user <kocevski> in cluster <slac> at Mon Sep  6 02:10:21 2021
Job was executed on host(s) <bullet0275>, in queue <medium>, as user <kocevski> in cluster <slac> at Mon Sep  6 02:10:41 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:10:41 2021
Terminated at Mon Sep  6 02:24:46 2021
Results reported at Mon Sep  6 02:24:46 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1238.3-1959_daily_bin588 189.594 -19.9945 391737601 391996801 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 :                                   649.02 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             305.85 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   845 sec.
    Turnaround time :                            865 sec.

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

