/nfs/farm/g/glast/g/LCRepository/bin/miniconda2/envs/fermitools_v1.0.5/lib/python2.7/site-packages/matplotlib/font_manager.py:281: UserWarning: Matplotlib is building the font cache using fc-list. This may take a moment.
  'Matplotlib is building the font cache using fc-list. '
/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 87 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 = 7350
number of fields = 31
RA_SUN column already exists. File will not be modified.
Done.


Performing analysis on: 4FGL_J1238.5-1201_daily_bin1603
RA = 189.625, Dec = -12.028
tmin = 654825601, tmax = 655084801
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='913848', job_status='RUN', time_executed='2021-10-05 00:04:08.349279', time_epoch_executed='1633417448.35' WHERE source_name='4FGL J1238.5-1201' and cadence='daily' and bin_id='1603'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/913848

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/913848/ft1_4FGL_J1238.5-1201_daily_bin1603.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/913848/ft2_4FGL_J1238.5-1201_daily_bin1603.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/913848/ft1_4FGL_J1238.5-1201_daily_bin1603.fits outfile=/scratch/kocevski/913848/ft1_filteredMKT_4FGL_J1238.5-1201_daily_bin1603.fits ra=189.625 dec=-12.028 rad=12.0 tmin=654825601.0 tmax=655084801.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.07
user 2.77
sys 0.21

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/913848/ft2_4FGL_J1238.5-1201_daily_bin1603.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/913848/ft2_4FGL_J1238.5-1201_daily_bin1603.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/913848/ft1_filteredMKT_4FGL_J1238.5-1201_daily_bin1603.fits evtable="EVENTS" outfile="/scratch/kocevski/913848/ft1_filtered_4FGL_J1238.5-1201_daily_bin1603.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.49
user 0.33
sys 0.15

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/913848/ft1_filtered_4FGL_J1238.5-1201_daily_bin1603.fits" evtable="EVENTS" scfile=/scratch/kocevski/913848/ft2_4FGL_J1238.5-1201_daily_bin1603.fits sctable="SC_DATA" outfile=/scratch/kocevski/913848/ltcube_654825601_655084801_4FGL_J1238.5-1201_daily_bin1603.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/913848/ft2_4FGL_J1238.5-1201_daily_bin1603.fits
.....................!
real 12.07
user 11.68
sys 0.36

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/913848/ft1_filtered_4FGL_J1238.5-1201_daily_bin1603.fits evtable="EVENTS" scfile=/scratch/kocevski/913848/ft2_4FGL_J1238.5-1201_daily_bin1603.fits sctable="SC_DATA" expcube=/scratch/kocevski/913848/ltcube_654825601_655084801_4FGL_J1238.5-1201_daily_bin1603.fits outfile=/scratch/kocevski/913848/expmap_654825601_655084801_4FGL_J1238.5-1201_daily_bin1603.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/913848/ltcube_654825601_655084801_4FGL_J1238.5-1201_daily_bin1603.fits
.....................!
real 190.58
user 184.86
sys 5.41

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

Setting source of interest to:
4FGL J1238.5-1201 @ 189.625 -12.028

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/913848/ft1_filtered_4FGL_J1238.5-1201_daily_bin1603.fits scfile=/scratch/kocevski/913848/ft2_4FGL_J1238.5-1201_daily_bin1603.fits outfile=/scratch/kocevski/913848/cmap_654825601_655084801_4FGL_J1238.5-1201_daily_bin1603.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.625 yref=-12.028 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.53
user 0.37
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/913848/ft1_filtered_4FGL_J1238.5-1201_daily_bin1603.fits scfile=/scratch/kocevski/913848/ft2_4FGL_J1238.5-1201_daily_bin1603.fits outfile=/scratch/kocevski/913848/cmap_HighResolution_654825601_655084801_4FGL_J1238.5-1201_daily_bin1603.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.625 yref=-12.028 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.38
sys 0.15

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/913848/ft1_filtered_4FGL_J1238.5-1201_daily_bin1603.fits evtable="EVENTS" scfile=/scratch/kocevski/913848/ft2_4FGL_J1238.5-1201_daily_bin1603.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/913848/Model_4FGL_J1238.5-1201_daily_bin1603.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/913848/ft1_filtered_4FGL_J1238.5-1201_daily_bin1603.fits.........................!
real 19.05
user 17.71
sys 1.25

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/913848/ft1_filtered_4FGL_J1238.5-1201_daily_bin1603.fits', '/scratch/kocevski/913848/ft2_4FGL_J1238.5-1201_daily_bin1603.fits', expMap='/scratch/kocevski/913848/expmap_654825601_655084801_4FGL_J1238.5-1201_daily_bin1603.fits', expCube='/scratch/kocevski/913848/ltcube_654825601_655084801_4FGL_J1238.5-1201_daily_bin1603.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/913848/Model_4FGL_J1238.5-1201_daily_bin1603.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1238.5-1201'

4FGL J1238.5-1201
   Spectrum: PowerLaw
326    Prefactor:  4.386e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-12)
327        Index:  2.660e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
328        Scale:  5.228e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/913848/ft1_filtered_4FGL_J1238.5-1201_daily_bin1603.fits
Spacecraft file(s): /scratch/kocevski/913848/ft2_4FGL_J1238.5-1201_daily_bin1603.fits
Exposure map: /scratch/kocevski/913848/expmap_654825601_655084801_4FGL_J1238.5-1201_daily_bin1603.fits
Exposure cube: /scratch/kocevski/913848/ltcube_654825601_655084801_4FGL_J1238.5-1201_daily_bin1603.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/913848/Model_4FGL_J1238.5-1201_daily_bin1603.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) = 656.996458899

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    25.329       1.0000         .10000E-03   10000.    
     2 'Prefactor '    42.552       1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10074E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    36.830       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10408E-03   1.0000         .10000E-03   10000.    
     6 'norm      '    7.8436       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .14527E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    .43705E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    55.863       1.0000         .10000E-03   10000.    
    10 'Prefactor '   10000.0       1.0000         .10000E-03   10000.    
    11 'Prefactor '   10000.0       1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10030E-03   1.0000         .10000E-03   10000.    
    13 'Prefactor '    630.49       1.0000         .10000E-03   10000.    
    14 'norm      '    231.42       1.0000         .10000E-03   10000.    
    15 'Prefactor '    669.27       1.0000         .10000E-03   10000.    
    16 'norm      '    .10094E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    9999.1       1.0000         .10000E-03   10000.    
    18 'norm      '   10000.0       1.0000         .10000E-03   10000.    
    19 'Prefactor '    1096.7       1.0000         .10000E-03   10000.    
    20 'norm      '    .44917E-02   1.0000         .10000E-03   10000.    
    21 'norm      '    .12195E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    .22796E-02   1.0000         .10000E-03   10000.    
    23 'Prefactor '    121.68       1.0000         .10000E-03   10000.    
    24 'Normalizat'    .10002E-01   1.0000         .10000E-01   10.000    
    25 'Prefactor '    .88241       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6130E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   652.4205     FROM MIGRAD    STATUS=CONVERGED    589 CALLS     3544 TOTAL
                     EDM=   .11E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  2.1%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     25.305        20.240        .33302E-06   -.60694E-04
   2  Prefactor     42.422        88.829       -.21300E-05   -.32813E-04
   3  Prefactor     .10000E-03    82.084       -.41219E-06** at limit **
   4  Prefactor     36.840        62.204       -.93371E-06   -.38646E-04
   5  Prefactor     .10000E-03    57.110       -.20598E-06** at limit **
   6  norm          7.8422        7.4701       -.69959E-07   -.54986E-04
   7  Prefactor     .10000E-03    222.53       -.16073E-05** at limit **
   8  Prefactor     .10001E-03    747.52       -.14494E-04** at limit **
   9  Prefactor     55.885        47.968       -.99613E-06   -.89660E-04
  10  Prefactor    10000.0        6546.6       -.58600E-05** at limit **
  11  Prefactor    10000.0        9098.4       -.85383E-05** at limit **
  12  Prefactor     .10000E-03    38.205        .22046E-05** at limit **
  13  Prefactor     630.24        538.71       -.56114E-05   -.11652E-04
  14  norm          231.14        162.93       -.31666E-05   -.27660E-04
  15  Prefactor    10000.0        9587.3       -.27484E-04** at limit **
  16  norm          .10000E-03    1.5713       -.10289E-05** at limit **
  17  norm         10000.0        6768.0       -.22944E-04** at limit **
  18  norm         10000.0        9988.1       -.11823E-04** at limit **
  19  Prefactor     1098.4        536.25       -.46321E-05   -.19750E-04
  20  norm          .10000E-03    435.93        .83155E-05** at limit **
  21  norm          .10000E-03    90.058       -.49727E-06** at limit **
  22  Prefactor     .10002E-03    1672.2        .26450E-04** at limit **
  23  Prefactor     121.82        133.68       -.18092E-05   -.25937E-04
  24  Normalizat    .10000E-01    .40570        .18236E-04** at limit **
  25  Prefactor     .88275        .44903        .51989E-05   -.56216E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 25.3048
  Prefactor  = 42.4217
  Prefactor  = 0.0001
  Prefactor  = 36.8397
  Prefactor  = 0.0001
  norm       = 7.8422
  Prefactor  = 0.000100003
  Prefactor  = 0.000100006
  Prefactor  = 55.8854
  Prefactor  = 10000
  Prefactor  = 10000
  Prefactor  = 0.0001
  Prefactor  = 630.236
  norm       = 231.142
  Prefactor  = 10000
  norm       = 0.0001
  norm       = 10000
  norm       = 10000
  Prefactor  = 1098.4
  norm       = 0.000100005
  norm       = 0.0001
  Prefactor  = 0.000100017
  Prefactor  = 121.825
  Normalizat = 0.01
  Prefactor  = 0.882754
 **********
 **   18 **HESSE 
 **********

 FCN=   652.4205     FROM HESSE     STATUS=OK           413 CALLS     3957 TOTAL
                     EDM=   .28E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     25.305        20.303        .79595E-04   -1.4701    
   2  Prefactor     42.422        91.350        .61455E-04   -1.4404    
   3  Prefactor     .10000E-03    84.909        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     36.840        63.565        .66039E-04   -1.4493    
   5  Prefactor     .10000E-03    58.473        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  norm          7.8422        7.4821        .65365E-04   -1.5148    
   7  Prefactor     .10000E-03    244.31        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .10001E-03    952.66        .21222E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     55.885        48.725        .53670E-04   -1.4211    
  10  Prefactor    10000.0        6546.2        .20352E-02    1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor    10000.0        9098.4        .20436E-02    1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10000E-03    39.127        .15597E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     630.24        549.02        .82287E-04   -1.0633    
  14  norm          231.14        164.97        .13302E-03   -1.2655    
  15  Prefactor    10000.0        9584.3        .80033E-02    1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          .10000E-03    1.6678        .59581E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm         10000.0        6777.6        .25458E-02    1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  norm         10000.0        9988.4        .18420E-02    1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     1098.4        539.58        .64004E-04   -.89518    
  20  norm          .10000E-03    447.88        .19347E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  norm          .10000E-03    93.345        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     .10002E-03    1702.2        .20108E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     121.82        135.26        .18242E-03   -1.3496    
  24  Normalizat    .10000E-01    .48670        .98618E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     .88275        .46304        .28844E-03   -.96746    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.78189e-10
Minuit parameter uncertainties:
  1  20.3087
  2  91.6536
  3  5.83104e-06
  4  63.6826
  5  6.879e-05
  6  7.48296
  7  0.001698
  8  0.00490058
  9  48.7593
  10  0.0044677
  11  0.0065633
  12  0.000250661
  13  553.805
  14  165.299
  15  0.269585
  16  1.55264e-05
  17  0.0456221
  18  0.0451109
  19  542.294
  20  0.00293521
  21  0.000130837
  22  0.0110419
  23  135.604
  24  1.13509e-05
  25  0.465122
Done.

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

Extracting fit parameters...

4FGL J1238.5-1201
   Spectrum: PowerLaw
326    Prefactor:  1.000e+04  6.563e-03  1.000e-04  1.000e+04 ( 1.000e-12)
327        Index:  2.660e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
328        Scale:  5.228e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
610    Prefactor:  8.828e-01  4.651e-01  0.000e+00  1.000e+01 ( 1.000e+00)
611        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
612        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
609   Normalization:  1.000e-02  1.135e-05  1.000e-02  1.000e+01 ( 1.000e+00)

calc_int error: parameter max 10000.0 is not large enough
delta logLike = 3.71897726836e-07

TS (Fixed Index): 0.90
Ra Dec: 189.625 -12.028
Photon Flux Upper Limit: -1.00e+00 ph cm-2 s-1
Energy Flux Upper Limit: -7.85e+04 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/913848/likelihoodResults_654825601_655084801_4FGL_J1238.5-1201_daily_bin1603.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) = 644.535578284
delta logL = 7.88493572872

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 644.503745538
delta logL = 7.91676847425

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Index     '    10.000       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6130E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   644.5037     FROM MIGRAD    STATUS=CONVERGED     11 CALLS       50 TOTAL
                     EDM=   .83E-17    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1    Index       10.000        .39865        .22515    ** at limit **
                               ERR DEF=  .500    
Final values: 
  Index      = 10
 **********
 **   18 **HESSE 
 **********

 FCN=   644.5037     FROM HESSE     STATUS=OK             5 CALLS       55 TOTAL
                     EDM=   .82E-17    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1    Index       10.000        .39698        .49855E-02    1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 8.17287e-18
Minuit parameter uncertainties:
  1  2.30733e-09
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/913848': 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) = 644.503745538
delta logL = 7.91676847425

Extracting fit parameters...

4FGL J1238.5-1201
   Spectrum: PowerLaw
326    Prefactor:  1.000e+04  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-12) fixed
327        Index:  1.000e+01  2.307e-09  0.000e+00  1.000e+01 (-1.000e+00)
328        Scale:  5.228e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
610    Prefactor:  8.824e-01  0.000e+00  0.000e+00  1.000e+01 ( 1.000e+00) fixed
611        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
612        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
609   Normalization:  1.009e-02  0.000e+00  1.000e-02  1.000e+01 ( 1.000e+00) fixed


TS (Free Index): 16.74
Ra Dec: 189.625 -12.028
Photon Index (Free Index): 10.00 +/- 0.00
Photon Flux (Free Index): 1.75e+00 +/- 6.03e-09
Energy Flux (Free Index): 1.95e+02 +/- 6.72e-07

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/913848/cmap_HighResolution_654825601_655084801_4FGL_J1238.5-1201_daily_bin1603.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='-7.85e+04', comment='SUCCESS', energy_flux2='1.95e+02', dlogl='7.92e+00', photon_flux2='1.75e+00', job_status='DONE', time_completed='2021-10-05 00:10:07.587472', photon_index_error2='0.00', photon_index2='10.00', ts='0.90', fit_tolerance='1e-08', GAL='0.88', photon_index_error='0.00', photon_flux_upper_limit='-1.00e+00', energy_flux_error2='6.72e-07', EG='0.01', time_epoch_completed='1633417807.59', return_code='0', job_id='913848', GAL2='0.88', EG2='0.01', return_code2='0', photon_flux_error2='6.03e-09', ts2='16.74', photon_index='2.66' WHERE bin_id='1603' AND source_name='4FGL J1238.5-1201' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Tue Oct  5 00:10:07 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0050>
Subject: Job 913848: <4FGL_J1238.5-1201_daily_bin1603> in cluster <slac> Done

Job <4FGL_J1238.5-1201_daily_bin1603> was submitted from host <rhel6-64p> by user <kocevski> in cluster <slac> at Tue Oct  5 00:02:28 2021
Job was executed on host(s) <bullet0050>, in queue <medium>, as user <kocevski> in cluster <slac> at Tue Oct  5 00:02:29 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Tue Oct  5 00:02:29 2021
Terminated at Tue Oct  5 00:10:08 2021
Results reported at Tue Oct  5 00:10:08 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1238.5-1201_daily_bin1603 189.625 -12.028 654825601 655084801 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1238.5-1201 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   361.09 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             235.88 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   458 sec.
    Turnaround time :                            460 sec.

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

