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


Performing analysis on: 4FGL_J1521.8+4338_daily_bin1301
RA = 230.464, Dec = 43.6344
tmin = 576547201, tmax = 576806401
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='504553', job_status='RUN', time_executed='2021-09-12 02:00:47.987070', time_epoch_executed='1631437247.99' WHERE source_name='4FGL J1521.8+4338' and cadence='daily' and bin_id='1301'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/504553

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/504553/ft1_4FGL_J1521.8+4338_daily_bin1301.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/504553/ft2_4FGL_J1521.8+4338_daily_bin1301.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/504553/ft1_4FGL_J1521.8+4338_daily_bin1301.fits outfile=/scratch/kocevski/504553/ft1_filteredMKT_4FGL_J1521.8+4338_daily_bin1301.fits ra=230.464 dec=43.6344 rad=12.0 tmin=576547201.0 tmax=576806401.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 4.98
user 4.70
sys 0.25

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/504553/ft2_4FGL_J1521.8+4338_daily_bin1301.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/504553/ft2_4FGL_J1521.8+4338_daily_bin1301.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/504553/ft1_filteredMKT_4FGL_J1521.8+4338_daily_bin1301.fits evtable="EVENTS" outfile="/scratch/kocevski/504553/ft1_filtered_4FGL_J1521.8+4338_daily_bin1301.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.34
sys 0.14

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/504553/ft1_filtered_4FGL_J1521.8+4338_daily_bin1301.fits" evtable="EVENTS" scfile=/scratch/kocevski/504553/ft2_4FGL_J1521.8+4338_daily_bin1301.fits sctable="SC_DATA" outfile=/scratch/kocevski/504553/ltcube_576547201_576806401_4FGL_J1521.8+4338_daily_bin1301.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/504553/ft2_4FGL_J1521.8+4338_daily_bin1301.fits
.....................!
real 12.07
user 11.59
sys 0.33

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/504553/ft1_filtered_4FGL_J1521.8+4338_daily_bin1301.fits evtable="EVENTS" scfile=/scratch/kocevski/504553/ft2_4FGL_J1521.8+4338_daily_bin1301.fits sctable="SC_DATA" expcube=/scratch/kocevski/504553/ltcube_576547201_576806401_4FGL_J1521.8+4338_daily_bin1301.fits outfile=/scratch/kocevski/504553/expmap_576547201_576806401_4FGL_J1521.8+4338_daily_bin1301.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/504553/ltcube_576547201_576806401_4FGL_J1521.8+4338_daily_bin1301.fits
.....................!
real 192.77
user 187.49
sys 4.70

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

Setting source of interest to:
4FGL J1521.8+4338 @ 230.464 43.6344

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/504553/ft1_filtered_4FGL_J1521.8+4338_daily_bin1301.fits scfile=/scratch/kocevski/504553/ft2_4FGL_J1521.8+4338_daily_bin1301.fits outfile=/scratch/kocevski/504553/cmap_576547201_576806401_4FGL_J1521.8+4338_daily_bin1301.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.464 yref=43.6344 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.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/504553/ft1_filtered_4FGL_J1521.8+4338_daily_bin1301.fits scfile=/scratch/kocevski/504553/ft2_4FGL_J1521.8+4338_daily_bin1301.fits outfile=/scratch/kocevski/504553/cmap_HighResolution_576547201_576806401_4FGL_J1521.8+4338_daily_bin1301.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.464 yref=43.6344 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.36
sys 0.17

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/504553/ft1_filtered_4FGL_J1521.8+4338_daily_bin1301.fits evtable="EVENTS" scfile=/scratch/kocevski/504553/ft2_4FGL_J1521.8+4338_daily_bin1301.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/504553/Model_4FGL_J1521.8+4338_daily_bin1301.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/504553/ft1_filtered_4FGL_J1521.8+4338_daily_bin1301.fits.....................!
real 53.55
user 52.12
sys 1.26

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/504553/ft1_filtered_4FGL_J1521.8+4338_daily_bin1301.fits', '/scratch/kocevski/504553/ft2_4FGL_J1521.8+4338_daily_bin1301.fits', expMap='/scratch/kocevski/504553/expmap_576547201_576806401_4FGL_J1521.8+4338_daily_bin1301.fits', expCube='/scratch/kocevski/504553/ltcube_576547201_576806401_4FGL_J1521.8+4338_daily_bin1301.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/504553/Model_4FGL_J1521.8+4338_daily_bin1301.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1521.8+4338'

4FGL J1521.8+4338
   Spectrum: PowerLaw
310    Prefactor:  3.344e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-12)
311        Index:  2.936e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
312        Scale:  4.193e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/504553/ft1_filtered_4FGL_J1521.8+4338_daily_bin1301.fits
Spacecraft file(s): /scratch/kocevski/504553/ft2_4FGL_J1521.8+4338_daily_bin1301.fits
Exposure map: /scratch/kocevski/504553/expmap_576547201_576806401_4FGL_J1521.8+4338_daily_bin1301.fits
Exposure cube: /scratch/kocevski/504553/ltcube_576547201_576806401_4FGL_J1521.8+4338_daily_bin1301.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/504553/Model_4FGL_J1521.8+4338_daily_bin1301.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) = 6640.98074837

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    26.495       1.0000         .10000E-03   10000.    
     2 'Prefactor '    78.879       1.0000         .10000E-03   10000.    
     3 'Prefactor '    8.6229       1.0000         .10000E-03   10000.    
     4 'norm      '    6.3141       1.0000         .10000E-03   10000.    
     5 'Prefactor '    75.426       1.0000         .10000E-03   10000.    
     6 'Prefactor '    10.026       1.0000         .10000E-03   10000.    
     7 'norm      '    21.450       1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    10 'norm      '    1.3438       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    2.2498       1.0000         .10000E-03   10000.    
    13 'norm      '    .10063E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    .10002E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    38.691       1.0000         .10000E-03   10000.    
    17 'Prefactor '    .83396       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    19 'norm      '    .32545       1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    21 'norm      '    .10018E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10022E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10027E-03   1.0000         .10000E-03   10000.    
    25 'Prefactor '    3.9140       1.0000         .10000E-03   10000.    
    26 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    27 'Normalizat'    1.4413       1.0000         .10000E-01   10.000    
    28 'Prefactor '    .61568       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6290E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   6640.971     FROM MIGRAD    STATUS=CONVERGED    694 CALLS     3513 TOTAL
                     EDM=   .15E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.6%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     26.506        27.786       -.28950E-06    .60693E-04
   2  Prefactor     78.878        57.486       -.20437E-06   -.21249E-07
   3  Prefactor     8.5087        35.150       -.33022E-05   -.19096E-03
   4  norm          6.3150        7.2498        .10404E-06    .25747E-04
   5  Prefactor     75.455        50.871        .64759E-06    .18645E-03
   6  Prefactor     10.025        12.564       -.14545E-06    .11849E-04
   7  norm          21.450        10.852        .66391E-08    .12071E-04
   8  Prefactor     .10000E-03    4.6849       -.81676E-08** at limit **
   9  Prefactor     .10000E-03    5.1719       -.27433E-07** at limit **
  10  norm          1.3436        1.2408        .29015E-07   -.61770E-04
  11  Prefactor     .10000E-03    1.8141       -.47595E-07** at limit **
  12  Prefactor     2.2499        3.4362        .41505E-05    .44044E-03
  13  norm          .10000E-03    .42116       -.22698E-06** at limit **
  14  norm          .10000E-03    1.1056        .24302E-07** at limit **
  15  Prefactor     .10000E-03    2.4070        .14380E-07** at limit **
  16  Prefactor     38.644        75.244       -.23896E-05   -.99393E-04
  17  Prefactor     .89375        10.099       -.33359E-05    .70397E-03
  18  Prefactor     .10000E-03    3.9475        .30501E-07** at limit **
  19  norm          .32478        1.2753        .11638E-05    .15703E-03
  20  Prefactor     .10000E-03    42.260       -.37497E-06** at limit **
  21  norm          .10000E-03    15.041        .14225E-07** at limit **
  22  Prefactor     .10000E-03    7.0251        .10751E-06** at limit **
  23  Prefactor     .10001E-03    122.72        .32259E-05** at limit **
  24  Prefactor     .10000E-03    6.3380        .46847E-07** at limit **
  25  Prefactor     3.9059        21.844        .60475E-06    .86368E-05
  26  Prefactor     .10000E-03    1.9800        .14504E-06** at limit **
  27  Normalizat    1.4413        .18359        .23732E-05   -.35336E-04
  28  Prefactor     .61583        .17767       -.45372E-05    .15306E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 26.5061
  Prefactor  = 78.8776
  Prefactor  = 8.50871
  norm       = 6.31499
  Prefactor  = 75.4546
  Prefactor  = 10.0252
  norm       = 21.4496
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 1.34364
  Prefactor  = 0.0001
  Prefactor  = 2.24991
  norm       = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 38.6441
  Prefactor  = 0.89375
  Prefactor  = 0.0001
  norm       = 0.324776
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.000100011
  Prefactor  = 0.0001
  Prefactor  = 3.90595
  Prefactor  = 0.0001
  Normalizat = 1.44125
  Prefactor  = 0.61583
 **********
 **   18 **HESSE 
 **********

 FCN=   6640.971     FROM HESSE     STATUS=OK           515 CALLS     4028 TOTAL
                     EDM=   .13E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     26.506        27.892        .77827E-04   -1.4678    
   2  Prefactor     78.878        57.474        .45218E-04   -1.3929    
   3  Prefactor     8.5087        35.619        .13651E-03   -1.5124    
   4  norm          6.3150        7.2464        .15974E-03   -1.5205    
   5  Prefactor     75.455        50.870        .23117E-03   -1.3968    
   6  Prefactor     10.025        12.549        .12655E-03   -1.5075    
   7  norm          21.450        10.850        .86483E-04   -1.4781    
   8  Prefactor     .10000E-03    4.6913        .17226E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     .10000E-03    5.1791        .18097E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  norm          1.3436        1.2214        .84159E-04   -1.5476    
  11  Prefactor     .10000E-03    1.8155        .10719E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     2.2499        3.4893        .92434E-03   -1.5408    
  13  norm          .10000E-03    .42394        .51563E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          .10000E-03    1.1226        .83653E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .10000E-03    2.4193        .12344E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     38.644        75.313        .64437E-04   -1.4464    
  17  Prefactor     .89375        53.712        .46285E-02   -1.5519    
  18  Prefactor     .10000E-03    3.9564        .15804E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  norm          .32478        1.2790        .17544E-03   -1.5594    
  20  Prefactor     .10000E-03    42.899        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  norm          .10000E-03    15.143        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     .10000E-03    7.0404        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .10001E-03    123.45        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     .10000E-03    6.4151        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     3.9059        21.653        .20393E-03   -1.5313    
  26  Prefactor     .10000E-03    2.0004        .11197E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  Normalizat    1.4413        .21721        .21251E-03   -.79443    
  28  Prefactor     .61583        .20787        .31203E-03   -1.0692    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.31818e-08
Minuit parameter uncertainties:
  1  27.9057
  2  57.5145
  3  34.8532
  4  7.2474
  5  50.8991
  6  12.5524
  7  10.8512
  8  3.51048e-08
  9  1.13773e-05
  10  1.2214
  11  6.64805e-07
  12  3.48957
  13  1.05378e-07
  14  1.12613e-06
  15  4.95021e-06
  16  75.4989
  17  13.8695
  18  1.10463e-05
  19  1.27912
  20  9.55698e-05
  21  2.68726e-05
  22  1.0513e-05
  23  0.00232518
  24  4.44436e-06
  25  18.4028
  26  9.85063e-07
  27  0.217345
  28  0.208125
Done.

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

Extracting fit parameters...

4FGL J1521.8+4338
   Spectrum: PowerLaw
310    Prefactor:  1.000e-04  1.105e-05  1.000e-04  1.000e+04 ( 1.000e-12)
311        Index:  2.936e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
312        Scale:  4.193e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
626    Prefactor:  6.158e-01  2.081e-01  0.000e+00  1.000e+01 ( 1.000e+00)
627        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
628        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
625   Normalization:  1.441e+00  2.173e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 230.464 43.634
Photon Flux Upper Limit: 6.02e-08 ph cm-2 s-1
Energy Flux Upper Limit: 4.80e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/504553/likelihoodResults_576547201_576806401_4FGL_J1521.8+4338_daily_bin1301.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) = 6640.97179664
delta logL = -0.00119961617111

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 6640.97059701
delta logL = 1.3101271179e-08

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.9289       1.0000          .0000       10.000    
     3 'Normalizat'    1.4413       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .61583       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6290E+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.
 MIGRAD TERMINATED WITHOUT CONVERGENCE.

 FCN=   6640.971     FROM MIGRAD    STATUS=FAILED        92 CALLS      248 TOTAL
                     EDM=   .20E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10086E-03    150.26        .15835E-02** at limit **
   2  Index         2.8446        8.2169        .50000        .12289E-04
   3  Normalizat    1.4413        .26565E-01    .21251E-03    .10967E-04
   4  Prefactor     .61583        .26741E-01    .31203E-03   -.33520E-05
                               ERR DEF=  .500    
 START SIMPLEX MINIMIZATION.    CONVERGENCE WHEN EDM .LT.   .20E-04
 SIMPLEX MINIMIZATION HAS CONVERGED.

 FCN=   6640.971     FROM SIMPLEX   STATUS=UNCHANGED    146 CALLS      394 TOTAL
                     EDM=   .11E-04    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10086E-03    150.26        .32281E-03** at limit **
   2  Index         2.8446        8.2169        .82018E-04    .12289E-04
   3  Normalizat    1.4413        .26565E-01    .10822E-05    .10967E-04
   4  Prefactor     .61583        .26741E-01    .10313E-05   -.33520E-05
                               ERR DEF=  .500    

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   6640.971     FROM MIGRAD    STATUS=CONVERGED     41 CALLS      435 TOTAL
                     EDM=   .21E-12    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    810.94        .31671E-03** at limit **
   2  Index         2.5894        5.0776        .50000       -.69576E-08
   3  Normalizat    1.4413        .94510E-01    .85003E-05   -.13375E-04
   4  Prefactor     .61583        .95125E-01    .12481E-04   -.10566E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Index      = 2.58941
  Normalizat = 1.44126
  Prefactor  = 0.615826
 **********
 **   18 **HESSE 
 **********

 FCN=   6640.971     FROM HESSE     STATUS=OK            29 CALLS      464 TOTAL
                     EDM=   .24E-12    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    4.5783        .63342E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.5894        8.6430        .50000       -.50307    
   3  Normalizat    1.4413        .20390        .17001E-05   -.79443    
   4  Prefactor     .61583        .20514        .24963E-05   -1.0692    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.35633e-13
Minuit parameter uncertainties:
  1  1.95008e-06
  2  157.038
  3  0.204012
  4  0.205386
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/504553': 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) = 6640.97059639
delta logL = 6.35651304037e-07

Extracting fit parameters...

4FGL J1521.8+4338
   Spectrum: PowerLaw
310    Prefactor:  1.000e-04  1.950e-06  1.000e-04  1.000e+04 ( 1.000e-12)
311        Index:  2.589e+00  1.570e+02  0.000e+00  1.000e+01 (-1.000e+00)
312        Scale:  4.193e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
626    Prefactor:  6.158e-01  2.054e-01  0.000e+00  1.000e+01 ( 1.000e+00)
627        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
628        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
625   Normalization:  1.441e+00  2.040e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 230.464 43.634

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/504553/cmap_HighResolution_576547201_576806401_4FGL_J1521.8+4338_daily_bin1301.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='4.80e-03', job_status='DONE', photon_flux_upper_limit='6.02e-08', time_completed='2021-09-12 02:15:31.552616', job_id='504553', GAL2='0.62', fit_tolerance='1e-08', EG2='1.44', EG='1.44', time_epoch_completed='1631438131.55', return_code2='0', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.62', dlogl='6.36e-07', ts2='-0.00', photon_index_error='0.00', photon_index='2.94' WHERE bin_id='1301' AND source_name='4FGL J1521.8+4338' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sun Sep 12 02:15:31 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0232>
Subject: Job 504553: <4FGL_J1521.8+4338_daily_bin1301> in cluster <slac> Done

Job <4FGL_J1521.8+4338_daily_bin1301> was submitted from host <rhel6-64j> by user <kocevski> in cluster <slac> at Sun Sep 12 02:00:32 2021
Job was executed on host(s) <bullet0232>, in queue <medium>, as user <kocevski> in cluster <slac> at Sun Sep 12 02:00:33 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sun Sep 12 02:00:33 2021
Terminated at Sun Sep 12 02:15:32 2021
Results reported at Sun Sep 12 02:15:32 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1521.8+4338_daily_bin1301 230.464 43.6344 576547201 576806401 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1521.8+4338 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   876.27 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             366.81 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   898 sec.
    Turnaround time :                            900 sec.

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

