/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 12 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 = 31
RA_SUN column already exists. File will not be modified.
Done.


Performing analysis on: 4FGL_J0340.5-2118_daily_bin1602
RA = 55.1477, Dec = -21.3158
tmin = 654566401, tmax = 654825601
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='855442', job_status='RUN', time_executed='2021-10-02 00:01:27.447431', time_epoch_executed='1633158087.45' WHERE source_name='4FGL J0340.5-2118' and cadence='daily' and bin_id='1602'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/855442

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/855442/ft1_4FGL_J0340.5-2118_daily_bin1602.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/855442/ft2_4FGL_J0340.5-2118_daily_bin1602.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/855442/ft1_4FGL_J0340.5-2118_daily_bin1602.fits outfile=/scratch/kocevski/855442/ft1_filteredMKT_4FGL_J0340.5-2118_daily_bin1602.fits ra=55.1477 dec=-21.3158 rad=12.0 tmin=654566401.0 tmax=654825601.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 5.04
user 4.75
sys 0.24

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/855442/ft2_4FGL_J0340.5-2118_daily_bin1602.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/855442/ft2_4FGL_J0340.5-2118_daily_bin1602.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/855442/ft1_filteredMKT_4FGL_J0340.5-2118_daily_bin1602.fits evtable="EVENTS" outfile="/scratch/kocevski/855442/ft1_filtered_4FGL_J0340.5-2118_daily_bin1602.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.54
user 0.31
sys 0.17

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/855442/ft1_filtered_4FGL_J0340.5-2118_daily_bin1602.fits" evtable="EVENTS" scfile=/scratch/kocevski/855442/ft2_4FGL_J0340.5-2118_daily_bin1602.fits sctable="SC_DATA" outfile=/scratch/kocevski/855442/ltcube_654566401_654825601_4FGL_J0340.5-2118_daily_bin1602.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/855442/ft2_4FGL_J0340.5-2118_daily_bin1602.fits
.....................!
real 12.06
user 11.64
sys 0.36

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/855442/ft1_filtered_4FGL_J0340.5-2118_daily_bin1602.fits evtable="EVENTS" scfile=/scratch/kocevski/855442/ft2_4FGL_J0340.5-2118_daily_bin1602.fits sctable="SC_DATA" expcube=/scratch/kocevski/855442/ltcube_654566401_654825601_4FGL_J0340.5-2118_daily_bin1602.fits outfile=/scratch/kocevski/855442/expmap_654566401_654825601_4FGL_J0340.5-2118_daily_bin1602.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/855442/ltcube_654566401_654825601_4FGL_J0340.5-2118_daily_bin1602.fits
.....................!
real 191.33
user 185.51
sys 5.42

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 Fornax A in ROI, make sure /nfs/farm/g/glast/g/LCRepository/Likelihood/ExtendedSources/Extended_archive_v18/Templates/FornaxA.fits is the correct path to the extended template.
Added 157 point sources and 1 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 J0340.5-2118 @ 55.1477 -21.3158

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/855442/ft1_filtered_4FGL_J0340.5-2118_daily_bin1602.fits scfile=/scratch/kocevski/855442/ft2_4FGL_J0340.5-2118_daily_bin1602.fits outfile=/scratch/kocevski/855442/cmap_654566401_654825601_4FGL_J0340.5-2118_daily_bin1602.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=55.1477 yref=-21.3158 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.37
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/855442/ft1_filtered_4FGL_J0340.5-2118_daily_bin1602.fits scfile=/scratch/kocevski/855442/ft2_4FGL_J0340.5-2118_daily_bin1602.fits outfile=/scratch/kocevski/855442/cmap_HighResolution_654566401_654825601_4FGL_J0340.5-2118_daily_bin1602.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=55.1477 yref=-21.3158 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.67
user 0.39
sys 0.15

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/855442/ft1_filtered_4FGL_J0340.5-2118_daily_bin1602.fits evtable="EVENTS" scfile=/scratch/kocevski/855442/ft2_4FGL_J0340.5-2118_daily_bin1602.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/855442/Model_4FGL_J0340.5-2118_daily_bin1602.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 Fornax A
adding source GAL_V02
Working on...
/scratch/kocevski/855442/ft1_filtered_4FGL_J0340.5-2118_daily_bin1602.fits....................!
real 97.89
user 92.08
sys 1.34

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/855442/ft1_filtered_4FGL_J0340.5-2118_daily_bin1602.fits', '/scratch/kocevski/855442/ft2_4FGL_J0340.5-2118_daily_bin1602.fits', expMap='/scratch/kocevski/855442/expmap_654566401_654825601_4FGL_J0340.5-2118_daily_bin1602.fits', expCube='/scratch/kocevski/855442/ltcube_654566401_654825601_4FGL_J0340.5-2118_daily_bin1602.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/855442/Model_4FGL_J0340.5-2118_daily_bin1602.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J0340.5-2118'

4FGL J0340.5-2118
   Spectrum: PowerLaw
267    Prefactor:  1.112e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-12)
268        Index:  2.261e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
269        Scale:  1.008e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/855442/ft1_filtered_4FGL_J0340.5-2118_daily_bin1602.fits
Spacecraft file(s): /scratch/kocevski/855442/ft2_4FGL_J0340.5-2118_daily_bin1602.fits
Exposure map: /scratch/kocevski/855442/expmap_654566401_654825601_4FGL_J0340.5-2118_daily_bin1602.fits
Exposure cube: /scratch/kocevski/855442/ltcube_654566401_654825601_4FGL_J0340.5-2118_daily_bin1602.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/855442/Model_4FGL_J0340.5-2118_daily_bin1602.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) = 4134.34556431

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    .46339E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10051E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10134E-03   1.0000         .10000E-03   10000.    
     4 'norm      '    .66152       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10015E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10023E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .15177       1.0000         .10000E-03   10000.    
     8 'Prefactor '    5.3353       1.0000         .10000E-03   10000.    
     9 'Prefactor '    6.2554       1.0000         .10000E-03   10000.    
    10 'Prefactor '    22.762       1.0000         .10000E-03   10000.    
    11 'Prefactor '    126.30       1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10006E-03   1.0000         .10000E-03   10000.    
    13 'Prefactor '    4.9504       1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10291E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    7.3882       1.0000         .10000E-03   10000.    
    17 'Prefactor '    .10010E-03   1.0000         .10000E-03   10000.    
    18 'norm      '    .42354E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10130E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10036E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    10.621       1.0000         .10000E-03   10000.    
    22 'norm      '    6.4859       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    5.0051       1.0000         .10000E-03   10000.    
    25 'Prefactor '    2.3302       1.0000         .10000E-03   10000.    
    26 'Normalizat'    1.0578       1.0000         .10000E-01   10.000    
    27 'Prefactor '    .85046       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5020E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   4134.340     FROM MIGRAD    STATUS=CONVERGED    683 CALLS     3340 TOTAL
                     EDM=   .48E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.1%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .10000E-03    2.0029        .21393E-06** at limit **
   2  Prefactor     .10000E-03    60.507        .26350E-06** at limit **
   3  Prefactor     .10000E-03    26.119        .50464E-06** at limit **
   4  norm          .66137        3.3125        .16591E-05    .17531E-03
   5  Prefactor     .10000E-03    14.507        .32702E-06** at limit **
   6  Prefactor     .10000E-03    157.40        .38558E-06** at limit **
   7  Prefactor     .14180        4.3008        .25863E-06   -.10786E-04
   8  Prefactor     5.3334        25.588       -.22542E-06   -.58097E-04
   9  Prefactor     6.2520        18.021        .64380E-06   -.96567E-05
  10  Prefactor     22.620        60.451       -.83929E-06   -.51322E-04
  11  Prefactor     126.30        76.200       -.17711E-06   -.58426E-04
  12  Prefactor     .10000E-03    30.159        .14473E-06** at limit **
  13  Prefactor     4.9547        3.8033       -.23198E-06   -.70817E-03
  14  Prefactor     .10004E-03    4.0015        .12945E-05** at limit **
  15  Prefactor     .10000E-03    3.1219        .20735E-06** at limit **
  16  norm          7.3883        1.8220       -.59684E-07   -.12763E-02
  17  Prefactor     .10000E-03    13.945        .11367E-06** at limit **
  18  norm          .10000E-03    1.2610        .30822E-06** at limit **
  19  Prefactor     .10000E-03    64.272       -.33814E-06** at limit **
  20  Prefactor     .10000E-03    20.422        .19868E-06** at limit **
  21  Prefactor     10.623        4.5862       -.12239E-06   -.45571E-03
  22  norm          6.4866        10.226        .19148E-06   -.26012E-04
  23  Prefactor     .10000E-03    12.196        .19048E-06** at limit **
  24  Prefactor     5.0004        13.138        .67884E-06   -.81298E-05
  25  Prefactor     2.3302        3.3014        .16047E-06   -.10678E-04
  26  Normalizat    1.0585        .24794        .24799E-05   -.46341E-03
  27  Prefactor     .84992        .21231       -.41766E-05   -.32860E-03
                               ERR DEF=  .500    
Final values: 
  norm       = 0.000100003
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.661371
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.141797
  Prefactor  = 5.33339
  Prefactor  = 6.25203
  Prefactor  = 22.6195
  Prefactor  = 126.304
  Prefactor  = 0.0001
  Prefactor  = 4.95471
  Prefactor  = 0.000100042
  Prefactor  = 0.0001
  norm       = 7.38827
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 10.6229
  norm       = 6.48663
  Prefactor  = 0.0001
  Prefactor  = 5.00036
  Prefactor  = 2.33018
  Normalizat = 1.05848
  Prefactor  = 0.84992
 **********
 **   18 **HESSE 
 **********

 FCN=   4134.340     FROM HESSE     STATUS=OK           486 CALLS     3826 TOTAL
                     EDM=   .20E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          .10000E-03    8.9713        .17118E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     .10000E-03    60.559        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10000E-03    26.354        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  norm          .66137        3.3234        .22797E-03   -1.5545    
   5  Prefactor     .10000E-03    14.602        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    157.45        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .14180        49.720        .23758E-02   -1.5633    
   8  Prefactor     5.3334        26.505        .17399E-03   -1.5246    
   9  Prefactor     6.2520        18.035        .16050E-03   -1.5208    
  10  Prefactor     22.620        60.595        .83957E-04   -1.4756    
  11  Prefactor     126.30        76.212        .17910E-03   -1.3456    
  12  Prefactor     .10000E-03    30.182        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     4.9547        3.6601        .99656E-04   -1.5263    
  14  Prefactor     .10004E-03    16.744        .21659E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .10000E-03    3.1535        .11085E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          7.3883        1.8076        .40394E-04   -1.5164    
  17  Prefactor     .10000E-03    13.957        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  norm          .10000E-03    5.6312        .13117E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10000E-03    64.281        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .10000E-03    20.486        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     10.623        4.5471        .85085E-04   -1.5056    
  22  norm          6.4866        10.219        .15759E-03   -1.5199    
  23  Prefactor     .10000E-03    12.211        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     5.0004        13.174        .17975E-03   -1.5261    
  25  Prefactor     2.3302        3.2872        .13429E-03   -1.5403    
  26  Normalizat    1.0585        .26199        .26003E-03   -.91096    
  27  Prefactor     .84992        .22421        .25331E-03   -.97914    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.03846e-08
Minuit parameter uncertainties:
  1  0.000339214
  2  2.20034e-05
  3  2.81541e-05
  4  2.96516
  5  4.29525e-05
  6  0.000321094
  7  5.31302
  8  23.796
  9  18.0511
  10  60.7609
  11  76.2715
  12  3.46201e-05
  13  3.66028
  14  0.00168135
  15  2.13481e-06
  16  1.80761
  17  5.34898e-06
  18  3.52511e-05
  19  3.59151e-05
  20  1.23429e-05
  21  4.54722
  22  10.2217
  23  1.35352e-05
  24  13.1821
  25  3.2875
  26  0.262308
  27  0.224448
Done.

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

Extracting fit parameters...

4FGL J0340.5-2118
   Spectrum: PowerLaw
267    Prefactor:  4.955e+00  3.660e+00  1.000e-04  1.000e+04 ( 1.000e-12)
268        Index:  2.261e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
269        Scale:  1.008e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
499    Prefactor:  8.499e-01  2.244e-01  0.000e+00  1.000e+01 ( 1.000e+00)
500        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
501        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
495   Normalization:  1.058e+00  2.623e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 5.27
Ra Dec: 55.148 -21.316
Photon Index (Fixed Index): 2.26 +/- 0.00
Photon Flux (Fixed Index): 7.31e-08 +/- 5.40e-08
Energy Flux (Fixed Index): 2.95e-05 +/- 2.18e-05

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) = 4134.27057387
delta logL = 0.0694867820857

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 4134.26879334
delta logL = 0.0712673092194

Fit tolerance = 1e-08

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

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

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   4134.269     FROM MIGRAD    STATUS=CONVERGED     52 CALLS      227 TOTAL
                     EDM=   .38E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     4.4553        68.298        .47676E-02    .36271E-03
   2  Index         2.4751        6.2375        .15122        .11851E-03
   3  Normalizat    1.0429        .10992        .59156E-01    .59129E-04
   4  Prefactor     .85576        .77998E-01    .44441E-01   -.60511E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 4.45531
  Index      = 2.47512
  Normalizat = 1.04287
  Prefactor  = 0.855759
 **********
 **   18 **HESSE 
 **********

 FCN=   4134.269     FROM HESSE     STATUS=OK            33 CALLS      260 TOTAL
                     EDM=   .12E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     4.4553        3.6561        .87396E-04   -1.5286    
   2  Index         2.4751        .58000        .54388E-02   -.52935    
   3  Normalizat    1.0429        .25056        .26160E-03   -.91608    
   4  Prefactor     .85576        .21826        .25242E-03   -.97705    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.19376e-10
Minuit parameter uncertainties:
  1  3.65625
  2  0.581756
  3  0.250848
  4  0.218481
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/855442': 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) = 4134.26879227
delta logL = 0.0712683873098

Extracting fit parameters...

4FGL J0340.5-2118
   Spectrum: PowerLaw
267    Prefactor:  4.455e+00  3.656e+00  1.000e-04  1.000e+04 ( 1.000e-12)
268        Index:  2.475e+00  5.818e-01  0.000e+00  1.000e+01 (-1.000e+00)
269        Scale:  1.008e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
499    Prefactor:  8.558e-01  2.185e-01  0.000e+00  1.000e+01 ( 1.000e+00)
500        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
501        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
495   Normalization:  1.043e+00  2.508e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 5.40
Ra Dec: 55.148 -21.316
Photon Index (Free Index): 2.48 +/- 0.58
Photon Flux (Free Index): 9.21e-08 +/- 7.73e-08
Energy Flux (Free Index): 2.75e-05 +/- 1.94e-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/855442/cmap_HighResolution_654566401_654825601_4FGL_J0340.5-2118_daily_bin1602.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET comment='SUCCESS', photon_flux='7.31e-08', energy_flux2='2.75e-05', photon_flux_error='5.40e-08', dlogl='7.13e-02', energy_flux='2.95e-05', photon_flux2='9.21e-08', job_status='DONE', time_completed='2021-10-02 00:11:12.097141', photon_index_error2='0.58', photon_index2='2.48', ts='5.27', fit_tolerance='1e-08', GAL='0.85', photon_index_error='0.00', energy_flux_error2='1.94e-05', EG='1.06', time_epoch_completed='1633158672.1', return_code='0', job_id='855442', GAL2='0.86', EG2='1.04', return_code2='0', energy_flux_error='2.18e-05', photon_flux_error2='7.73e-08', ts2='5.40', photon_index='2.26' WHERE bin_id='1602' AND source_name='4FGL J0340.5-2118' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sat Oct  2 00:11:12 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0038>
Subject: Job 855442: <4FGL_J0340.5-2118_daily_bin1602> in cluster <slac> Done

Job <4FGL_J0340.5-2118_daily_bin1602> was submitted from host <rhel6-64f> by user <kocevski> in cluster <slac> at Sat Oct  2 00:00:58 2021
Job was executed on host(s) <bullet0038>, in queue <medium>, as user <kocevski> in cluster <slac> at Sat Oct  2 00:01:00 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sat Oct  2 00:01:00 2021
Terminated at Sat Oct  2 00:11:12 2021
Results reported at Sat Oct  2 00:11:12 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J0340.5-2118_daily_bin1602 55.1477 -21.3158 654566401 654825601 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J0340.5-2118 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   576.05 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             393.74 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   612 sec.
    Turnaround time :                            614 sec.

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

