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


Performing analysis on: 4FGL_J1520.5+4209_daily_bin1153
RA = 230.135, Dec = 42.16
tmin = 538185601, tmax = 538444801
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='494580', job_status='RUN', time_executed='2021-09-12 01:34:40.300505', time_epoch_executed='1631435680.3' WHERE source_name='4FGL J1520.5+4209' and cadence='daily' and bin_id='1153'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/494580

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/494580/ft1_4FGL_J1520.5+4209_daily_bin1153.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/494580/ft2_4FGL_J1520.5+4209_daily_bin1153.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/494580/ft1_4FGL_J1520.5+4209_daily_bin1153.fits outfile=/scratch/kocevski/494580/ft1_filteredMKT_4FGL_J1520.5+4209_daily_bin1153.fits ra=230.135 dec=42.16 rad=12.0 tmin=538185601.0 tmax=538444801.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.32
user 5.03
sys 0.22

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/494580/ft2_4FGL_J1520.5+4209_daily_bin1153.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/494580/ft2_4FGL_J1520.5+4209_daily_bin1153.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/494580/ft1_filteredMKT_4FGL_J1520.5+4209_daily_bin1153.fits evtable="EVENTS" outfile="/scratch/kocevski/494580/ft1_filtered_4FGL_J1520.5+4209_daily_bin1153.fits" apply_filter=yes overwrite=yes header_obstimes=yes tstart=0.0 tstop=0.0 gtifile="default" chatter=3 clobber=yes debug=no gui=no mode="ql"

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

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

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/494580/ft1_filtered_4FGL_J1520.5+4209_daily_bin1153.fits" evtable="EVENTS" scfile=/scratch/kocevski/494580/ft2_4FGL_J1520.5+4209_daily_bin1153.fits sctable="SC_DATA" outfile=/scratch/kocevski/494580/ltcube_538185601_538444801_4FGL_J1520.5+4209_daily_bin1153.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/494580/ft2_4FGL_J1520.5+4209_daily_bin1153.fits
.....................!
real 11.93
user 11.49
sys 0.31

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/494580/ft1_filtered_4FGL_J1520.5+4209_daily_bin1153.fits evtable="EVENTS" scfile=/scratch/kocevski/494580/ft2_4FGL_J1520.5+4209_daily_bin1153.fits sctable="SC_DATA" expcube=/scratch/kocevski/494580/ltcube_538185601_538444801_4FGL_J1520.5+4209_daily_bin1153.fits outfile=/scratch/kocevski/494580/expmap_538185601_538444801_4FGL_J1520.5+4209_daily_bin1153.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/494580/ltcube_538185601_538444801_4FGL_J1520.5+4209_daily_bin1153.fits
.....................!
real 192.31
user 185.31
sys 4.81

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

Setting source of interest to:
4FGL J1520.5+4209 @ 230.135 42.16

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/494580/ft1_filtered_4FGL_J1520.5+4209_daily_bin1153.fits scfile=/scratch/kocevski/494580/ft2_4FGL_J1520.5+4209_daily_bin1153.fits outfile=/scratch/kocevski/494580/cmap_538185601_538444801_4FGL_J1520.5+4209_daily_bin1153.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=230.135 yref=42.16 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.37
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/494580/ft1_filtered_4FGL_J1520.5+4209_daily_bin1153.fits scfile=/scratch/kocevski/494580/ft2_4FGL_J1520.5+4209_daily_bin1153.fits outfile=/scratch/kocevski/494580/cmap_HighResolution_538185601_538444801_4FGL_J1520.5+4209_daily_bin1153.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=230.135 yref=42.16 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/494580/ft1_filtered_4FGL_J1520.5+4209_daily_bin1153.fits evtable="EVENTS" scfile=/scratch/kocevski/494580/ft2_4FGL_J1520.5+4209_daily_bin1153.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/494580/Model_4FGL_J1520.5+4209_daily_bin1153.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/494580/ft1_filtered_4FGL_J1520.5+4209_daily_bin1153.fits......................!
real 24.76
user 23.16
sys 1.17

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/494580/ft1_filtered_4FGL_J1520.5+4209_daily_bin1153.fits', '/scratch/kocevski/494580/ft2_4FGL_J1520.5+4209_daily_bin1153.fits', expMap='/scratch/kocevski/494580/expmap_538185601_538444801_4FGL_J1520.5+4209_daily_bin1153.fits', expCube='/scratch/kocevski/494580/ltcube_538185601_538444801_4FGL_J1520.5+4209_daily_bin1153.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/494580/Model_4FGL_J1520.5+4209_daily_bin1153.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1520.5+4209'

4FGL J1520.5+4209
   Spectrum: PowerLaw
308    Prefactor:  3.393e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
309        Index:  2.505e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
310        Scale:  9.357e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/494580/ft1_filtered_4FGL_J1520.5+4209_daily_bin1153.fits
Spacecraft file(s): /scratch/kocevski/494580/ft2_4FGL_J1520.5+4209_daily_bin1153.fits
Exposure map: /scratch/kocevski/494580/expmap_538185601_538444801_4FGL_J1520.5+4209_daily_bin1153.fits
Exposure cube: /scratch/kocevski/494580/ltcube_538185601_538444801_4FGL_J1520.5+4209_daily_bin1153.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/494580/Model_4FGL_J1520.5+4209_daily_bin1153.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) = 1841.80497202

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10011E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10019E-03   1.0000         .10000E-03   10000.    
     3 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    7.6912       1.0000         .10000E-03   10000.    
     6 'norm      '    .10005E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10015E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     9 'norm      '    1.4313       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
    12 'norm      '    2.5151       1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10666E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    17.451       1.0000         .10000E-03   10000.    
    15 'norm      '    .10003E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    .10416E-03   1.0000         .10000E-03   10000.    
    17 'Prefactor '    .10426E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .15238E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    15.105       1.0000         .10000E-03   10000.    
    21 'norm      '    6.7756       1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10006E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    .22903E-03   1.0000         .10000E-03   10000.    
    24 'norm      '    .21505E-01   1.0000         .10000E-03   10000.    
    25 'Prefactor '    .10022E-03   1.0000         .10000E-03   10000.    
    26 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    27 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    28 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    29 'Normalizat'    .94162       1.0000         .10000E-01   10.000    
    30 'Prefactor '    .78529       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6280E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   1841.788     FROM MIGRAD    STATUS=CONVERGED    766 CALLS     3866 TOTAL
                     EDM=   .96E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .7%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    47.806        .24329E-05** at limit **
   2  Prefactor     .10000E-03    25.014       -.20404E-05** at limit **
   3  norm          .10000E-03    22.303        .63929E-05** at limit **
   4  Prefactor     .10000E-03    118.96        .19774E-04** at limit **
   5  Prefactor     7.6622        118.89       -.54901E-04    .40775E-05
   6  norm          .10000E-03    5.3440        .41986E-07** at limit **
   7  Prefactor     .10000E-03    48.072        .18029E-05** at limit **
   8  Prefactor     .10000E-03    18.674       -.70352E-05** at limit **
   9  norm          1.4323        39.002       -.27966E-05   -.14266E-03
  10  Prefactor     .10000E-03    10.028        .26234E-07** at limit **
  11  Prefactor     .10000E-03    17.646        .72531E-05** at limit **
  12  norm          2.5152        3.4818       -.18346E-06   -.14130E-03
  13  Prefactor     .10000E-03    29.562       -.12320E-04** at limit **
  14  Prefactor     17.452        14.582       -.20449E-06   -.14498E-06
  15  norm          .10000E-03    1.8181        .97511E-07** at limit **
  16  norm          .10000E-03    6.4425        .11544E-06** at limit **
  17  Prefactor     .10000E-03    18.195       -.56404E-05** at limit **
  18  Prefactor     .10000E-03    54.572       -.19184E-04** at limit **
  19  Prefactor     .10000E-03    114.83        .15625E-04** at limit **
  20  Prefactor     15.061        24.258       -.13437E-06    .69711E-04
  21  norm          6.7760        2.7586       -.15049E-06   -.39065E-03
  22  Prefactor     .10000E-03    38.163        .90995E-05** at limit **
  23  Prefactor     .10000E-03    140.70        .38770E-04** at limit **
  24  norm          .10263E-03    25.305       -.71421E-05** at limit **
  25  Prefactor     .10000E-03    93.630       -.25253E-04** at limit **
  26  Prefactor     .10000E-03    40.204        .11438E-04** at limit **
  27  Prefactor     .10000E-03    4.9476       -.85938E-07** at limit **
  28  Prefactor     .10000E-03    21.243        .44168E-05** at limit **
  29  Normalizat    .94150        .28083        .35193E-05    .15288E-03
  30  Prefactor     .78536        .28325       -.33768E-06    .20495E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 7.6622
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 1.43226
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 2.51517
  Prefactor  = 0.000100001
  Prefactor  = 17.4518
  norm       = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 15.0611
  norm       = 6.77603
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.000102626
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Normalizat = 0.941497
  Prefactor  = 0.785356
 **********
 **   18 **HESSE 
 **********

 FCN=   1841.788     FROM HESSE     STATUS=OK           570 CALLS     4436 TOTAL
                     EDM=   .13E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    47.841        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     .10000E-03    25.009        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm          .10000E-03    22.311        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    118.99        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     7.6622        119.86        .14460E-03   -1.5154    
   6  norm          .10000E-03    5.3462        .96895E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10000E-03    48.085        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .10000E-03    18.680        .18118E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  norm          1.4323        39.560        .36105E-03   -1.5469    
  10  Prefactor     .10000E-03    10.031        .13275E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .10000E-03    17.659        .17611E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  norm          2.5152        3.4659        .91080E-04   -1.5391    
  13  Prefactor     .10000E-03    30.536        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     17.452        14.571        .95876E-04   -1.4872    
  15  norm          .10000E-03    1.8743        .11293E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          .10000E-03    12.208        .20539E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  Prefactor     .10000E-03    18.439        .17794E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .10000E-03    54.603        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10000E-03    116.49        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     15.061        23.614        .10306E-03   -1.4932    
  21  norm          6.7760        2.7533        .43790E-04   -1.5187    
  22  Prefactor     .10000E-03    38.491        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .10000E-03    142.50        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  norm          .10263E-03    205.53        .40749E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     .10000E-03    94.204        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  Prefactor     .10000E-03    40.204        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  Prefactor     .10000E-03    4.9732        .93220E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  Prefactor     .10000E-03    21.279        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  29  Normalizat    .94150        .33460        .21553E-03   -.95017    
  30  Prefactor     .78536        .33727        .24164E-03   -1.0027    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.27907e-08
Minuit parameter uncertainties:
  1  9.13249e-05
  2  0.000106095
  3  1.67806e-05
  4  8.72227e-06
  5  60.7559
  6  1.89445e-05
  7  0.000116512
  8  2.68794e-06
  9  15.0651
  10  7.91548e-06
  11  1.98447e-06
  12  3.46621
  13  0.00029491
  14  14.5741
  15  7.02886e-06
  16  4.78023e-05
  17  2.53454e-05
  18  2.4281e-06
  19  0.000344011
  20  23.6286
  21  2.75331
  22  9.22464e-05
  23  0.000466385
  24  0.046628
  25  0.000122017
  26  2.4605e-05
  27  1.43232e-05
  28  4.23928e-05
  29  0.335343
  30  0.338159
Done.

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

Extracting fit parameters...

4FGL J1520.5+4209
   Spectrum: PowerLaw
308    Prefactor:  1.000e-04  3.440e-04  1.000e-04  1.000e+04 ( 1.000e-13)
309        Index:  2.505e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
310        Scale:  9.357e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
625    Prefactor:  7.854e-01  3.382e-01  0.000e+00  1.000e+01 ( 1.000e+00)
626        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
627        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
624   Normalization:  9.415e-01  3.353e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 230.135 42.160
Photon Flux Upper Limit: 1.67e-07 ph cm-2 s-1
Energy Flux Upper Limit: 1.30e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/494580/likelihoodResults_538185601_538444801_4FGL_J1520.5+4209_daily_bin1153.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): 102
logL (Free Index) = 1841.78755316
delta logL = -4.07822917623e-05

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 1841.78755316
delta logL = -4.07785282732e-05

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .96347E-02   1.0000         .10000E-03   10000.    
     2 'Index     '    2.5048       1.0000          .0000       10.000    
     3 'Normalizat'    .94151       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .78536       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6280E+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=   1841.757     FROM MIGRAD    STATUS=CONVERGED    168 CALLS      308 TOTAL
                     EDM=   .16E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     10.591        7380.1        .64657E-02    .21528E-04
   2  Index         1.8229        8.1994        .30556       -.18977E-05
   3  Normalizat    .94880        .96418E-01    .21553E-03    .40221E-05
   4  Prefactor     .77121        .12088        .24164E-03   -.64808E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 10.5907
  Index      = 1.8229
  Normalizat = 0.948801
  Prefactor  = 0.771211
 **********
 **   18 **HESSE 
 **********

 FCN=   1841.757     FROM HESSE     STATUS=OK            29 CALLS      337 TOTAL
                     EDM=   .19E-11    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     10.591        49.580        .25863E-03   -1.5057    
   2  Index         1.8229        1.3870        .11490E-01   -.68855    
   3  Normalizat    .94880        .32497        .86211E-05   -.94766    
   4  Prefactor     .77121        .33970        .96657E-05   -1.0080    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.90355e-12
Minuit parameter uncertainties:
  1  45.8915
  2  1.41875
  3  0.32565
  4  0.340629
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/494580': 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) = 1841.75651543
delta logL = 0.0309969465015

Extracting fit parameters...

4FGL J1520.5+4209
   Spectrum: PowerLaw
308    Prefactor:  1.059e+01  4.589e+01  1.000e-04  1.000e+04 ( 1.000e-13)
309        Index:  1.823e+00  1.419e+00  0.000e+00  1.000e+01 (-1.000e+00)
310        Scale:  9.357e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
625    Prefactor:  7.712e-01  3.406e-01  0.000e+00  1.000e+01 ( 1.000e+00)
626        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
627        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
624   Normalization:  9.488e-01  3.256e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 230.135 42.160

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/494580/cmap_HighResolution_538185601_538444801_4FGL_J1520.5+4209_daily_bin1153.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='1.30e-02', job_status='DONE', photon_flux_upper_limit='1.67e-07', time_completed='2021-09-12 01:43:31.676057', job_id='494580', GAL2='0.77', fit_tolerance='1e-08', EG2='0.95', EG='0.94', time_epoch_completed='1631436211.68', return_code2='0', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.79', dlogl='3.10e-02', ts2='0.06', photon_index_error='0.00', photon_index='2.50' WHERE bin_id='1153' AND source_name='4FGL J1520.5+4209' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sun Sep 12 01:43:31 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0231>
Subject: Job 494580: <4FGL_J1520.5+4209_daily_bin1153> in cluster <slac> Done

Job <4FGL_J1520.5+4209_daily_bin1153> was submitted from host <rhel6-64k> by user <kocevski> in cluster <slac> at Sun Sep 12 01:30:29 2021
Job was executed on host(s) <bullet0231>, in queue <medium>, as user <kocevski> in cluster <slac> at Sun Sep 12 01:30:31 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sun Sep 12 01:30:31 2021
Terminated at Sun Sep 12 01:43:32 2021
Results reported at Sun Sep 12 01:43:32 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1520.5+4209_daily_bin1153 230.135 42.16 538185601 538444801 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1520.5+4209 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   499.09 sec.
    Max Memory :                                 1095 MB
    Average Memory :                             230.50 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   780 sec.
    Turnaround time :                            783 sec.

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

