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


Performing analysis on: 4FGL_J1521.8+4338_daily_bin1035
RA = 230.464, Dec = 43.6344
tmin = 507600001, tmax = 507859201
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='502797', job_status='RUN', time_executed='2021-09-12 01:55:50.566695', time_epoch_executed='1631436950.57' WHERE source_name='4FGL J1521.8+4338' and cadence='daily' and bin_id='1035'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/502797

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/502797/ft1_4FGL_J1521.8+4338_daily_bin1035.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/502797/ft2_4FGL_J1521.8+4338_daily_bin1035.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/502797/ft1_4FGL_J1521.8+4338_daily_bin1035.fits outfile=/scratch/kocevski/502797/ft1_filteredMKT_4FGL_J1521.8+4338_daily_bin1035.fits ra=230.464 dec=43.6344 rad=12.0 tmin=507600001.0 tmax=507859201.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.58
user 3.33
sys 0.22

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

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

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/502797/ft1_filtered_4FGL_J1521.8+4338_daily_bin1035.fits" evtable="EVENTS" scfile=/scratch/kocevski/502797/ft2_4FGL_J1521.8+4338_daily_bin1035.fits sctable="SC_DATA" outfile=/scratch/kocevski/502797/ltcube_507600001_507859201_4FGL_J1521.8+4338_daily_bin1035.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/502797/ft2_4FGL_J1521.8+4338_daily_bin1035.fits
.....................!
real 11.84
user 11.49
sys 0.31

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/502797/ft1_filtered_4FGL_J1521.8+4338_daily_bin1035.fits evtable="EVENTS" scfile=/scratch/kocevski/502797/ft2_4FGL_J1521.8+4338_daily_bin1035.fits sctable="SC_DATA" expcube=/scratch/kocevski/502797/ltcube_507600001_507859201_4FGL_J1521.8+4338_daily_bin1035.fits outfile=/scratch/kocevski/502797/expmap_507600001_507859201_4FGL_J1521.8+4338_daily_bin1035.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/502797/ltcube_507600001_507859201_4FGL_J1521.8+4338_daily_bin1035.fits
.....................!
real 191.94
user 186.83
sys 4.74

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/502797/ft1_filtered_4FGL_J1521.8+4338_daily_bin1035.fits scfile=/scratch/kocevski/502797/ft2_4FGL_J1521.8+4338_daily_bin1035.fits outfile=/scratch/kocevski/502797/cmap_507600001_507859201_4FGL_J1521.8+4338_daily_bin1035.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.53
user 0.40
sys 0.13

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/502797/ft1_filtered_4FGL_J1521.8+4338_daily_bin1035.fits scfile=/scratch/kocevski/502797/ft2_4FGL_J1521.8+4338_daily_bin1035.fits outfile=/scratch/kocevski/502797/cmap_HighResolution_507600001_507859201_4FGL_J1521.8+4338_daily_bin1035.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.55
user 0.39
sys 0.15

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

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/502797/ft1_filtered_4FGL_J1521.8+4338_daily_bin1035.fits', '/scratch/kocevski/502797/ft2_4FGL_J1521.8+4338_daily_bin1035.fits', expMap='/scratch/kocevski/502797/expmap_507600001_507859201_4FGL_J1521.8+4338_daily_bin1035.fits', expCube='/scratch/kocevski/502797/ltcube_507600001_507859201_4FGL_J1521.8+4338_daily_bin1035.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/502797/Model_4FGL_J1521.8+4338_daily_bin1035.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/502797/ft1_filtered_4FGL_J1521.8+4338_daily_bin1035.fits
Spacecraft file(s): /scratch/kocevski/502797/ft2_4FGL_J1521.8+4338_daily_bin1035.fits
Exposure map: /scratch/kocevski/502797/expmap_507600001_507859201_4FGL_J1521.8+4338_daily_bin1035.fits
Exposure cube: /scratch/kocevski/502797/ltcube_507600001_507859201_4FGL_J1521.8+4338_daily_bin1035.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/502797/Model_4FGL_J1521.8+4338_daily_bin1035.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) = 5901.80184546

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    25.544       1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10025E-03   1.0000         .10000E-03   10000.    
     4 'norm      '    4.0121       1.0000         .10000E-03   10000.    
     5 'Prefactor '    2.5633       1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10007E-03   1.0000         .10000E-03   10000.    
     7 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    27.763       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    10 'norm      '    3.5156       1.0000         .10000E-03   10000.    
    11 'Prefactor '    5.8562       1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    13 'norm      '    1.2911       1.0000         .10000E-03   10000.    
    14 'norm      '    .10002E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .18358E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    32.752       1.0000         .10000E-03   10000.    
    17 'Prefactor '    11.444       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10207E-03   1.0000         .10000E-03   10000.    
    19 'norm      '    4.5278       1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
    21 'norm      '    .10010E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10458E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10064E-03   1.0000         .10000E-03   10000.    
    25 'Prefactor '    27.338       1.0000         .10000E-03   10000.    
    26 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    27 'Normalizat'    1.0822       1.0000         .10000E-01   10.000    
    28 'Prefactor '    .77238       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=   5901.793     FROM MIGRAD    STATUS=CONVERGED    666 CALLS     3437 TOTAL
                     EDM=   .32E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.8%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    21.210        .22319E-07** at limit **
   2  Prefactor     25.547        38.536       -.17503E-07    .76129E-05
   3  Prefactor     .10000E-03    25.218       -.16255E-05** at limit **
   4  norm          4.0138        5.0712        .22389E-05   -.31938E-04
   5  Prefactor     2.5032        208.51       -.94357E-05   -.44506E-04
   6  Prefactor     .10000E-03    10.021        .69832E-07** at limit **
   7  norm          .10000E-03    2.3070       -.47807E-07** at limit **
   8  Prefactor     27.764        14.331       -.19692E-06   -.10196E-04
   9  Prefactor     .10000E-03    17.014        .19028E-06** at limit **
  10  norm          3.5154        1.7955        .15117E-07   -.41925E-04
  11  Prefactor     5.8565        4.6833       -.10854E-06   -.16460E-04
  12  Prefactor     .10000E-03    5.2042        .22774E-06** at limit **
  13  norm          1.2910        1.1480       -.72951E-08   -.56067E-04
  14  norm          .10000E-03    .88657        .27565E-07** at limit **
  15  Prefactor     .10002E-03    4.1113        .12672E-05** at limit **
  16  Prefactor     32.762        51.044        .79325E-07    .18573E-04
  17  Prefactor     11.432        17.008        .34319E-06   -.15775E-03
  18  Prefactor     .10000E-03    4.4943        .19427E-08** at limit **
  19  norm          4.5275        2.2153        .56540E-06   -.10717E-03
  20  Prefactor     .10000E-03    15.375        .24781E-06** at limit **
  21  norm          .10000E-03    7.8350        .17318E-06** at limit **
  22  Prefactor     .10000E-03    11.459        .18012E-06** at limit **
  23  Prefactor     .10000E-03    43.500        .39175E-06** at limit **
  24  Prefactor     .10000E-03    3.8118        .56818E-06** at limit **
  25  Prefactor     27.351        24.863        .22406E-06    .14264E-04
  26  Prefactor     .10000E-03    1.4962        .92667E-07** at limit **
  27  Normalizat    1.0822        .17037        .21374E-07   -.17076E-03
  28  Prefactor     .77236        .17344       -.12015E-05   -.97346E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 25.5468
  Prefactor  = 0.0001
  norm       = 4.01376
  Prefactor  = 2.50322
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 27.764
  Prefactor  = 0.0001
  norm       = 3.51539
  Prefactor  = 5.85651
  Prefactor  = 0.0001
  norm       = 1.29105
  norm       = 0.0001
  Prefactor  = 0.000100018
  Prefactor  = 32.7618
  Prefactor  = 11.4323
  Prefactor  = 0.0001
  norm       = 4.52746
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 27.3506
  Prefactor  = 0.0001
  Normalizat = 1.08222
  Prefactor  = 0.772357
 **********
 **   18 **HESSE 
 **********

 FCN=   5901.793     FROM HESSE     STATUS=OK           517 CALLS     3954 TOTAL
                     EDM=   .17E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    21.327        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     25.547        38.527        .79260E-04   -1.4697    
   3  Prefactor     .10000E-03    25.379        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  norm          4.0138        5.1084        .93933E-03   -1.5307    
   5  Prefactor     2.5032        219.70        .25498E-03   -1.5392    
   6  Prefactor     .10000E-03    10.079        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  norm          .10000E-03    2.3072        .11396E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     27.764        14.335        .76033E-04   -1.4654    
   9  Prefactor     .10000E-03    17.193        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  norm          3.5154        1.7933        .70529E-04   -1.5333    
  11  Prefactor     5.8565        4.6829        .14382E-03   -1.5224    
  12  Prefactor     .10000E-03    5.3431        .34219E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  norm          1.2910        1.1474        .38970E-04   -1.5481    
  14  norm          .10000E-03    .89052        .70620E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .10002E-03    11.890        .28593E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     32.762        51.051        .70017E-04   -1.4563    
  17  Prefactor     11.432        16.666        .11843E-03   -1.5032    
  18  Prefactor     .10000E-03    4.5058        .15885E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  norm          4.5275        2.2196        .38421E-03   -1.5282    
  20  Prefactor     .10000E-03    15.443        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  norm          .10000E-03    7.8607        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     .10000E-03    11.496        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .10000E-03    43.549        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     .10000E-03    3.8192        .14598E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     27.351        24.823        .76620E-04   -1.4662    
  26  Prefactor     .10000E-03    1.5007        .91771E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  Normalizat    1.0822        .19824        .21830E-03   -.90325    
  28  Prefactor     .77236        .20051        .26432E-03   -1.0076    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.68725e-09
Minuit parameter uncertainties:
  1  2.40131e-05
  2  38.5648
  3  8.26337e-05
  4  5.10892
  5  47.0804
  6  2.31843e-05
  7  7.54053e-07
  8  14.3366
  9  2.96776e-06
  10  1.79336
  11  4.68318
  12  6.71349e-06
  13  1.14745
  14  6.35516e-07
  15  0.000919032
  16  51.1188
  17  16.673
  18  5.52858e-06
  19  2.21967
  20  1.4556e-05
  21  8.67955e-06
  22  1.92908e-05
  23  7.01894e-05
  24  3.31119e-07
  25  24.8324
  26  7.46066e-07
  27  0.198378
  28  0.200697
Done.

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

Extracting fit parameters...

4FGL J1521.8+4338
   Spectrum: PowerLaw
310    Prefactor:  1.000e-04  5.529e-06  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:  7.724e-01  2.007e-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.082e+00  1.984e-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.14e-08 ph cm-2 s-1
Energy Flux Upper Limit: 4.90e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/502797/likelihoodResults_507600001_507859201_4FGL_J1521.8+4338_daily_bin1035.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) = 5901.79425628
delta logL = -0.00105638584591

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 5901.7931999
delta logL = -5.4387783166e-09

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.9311       1.0000          .0000       10.000    
     3 'Normalizat'    1.0822       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .77237       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=   5901.793     FROM MIGRAD    STATUS=FAILED        96 CALLS      244 TOTAL
                     EDM=   .18E-06    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    548.74        .15901E-02** at limit **
   2  Index         2.6157        7.8111        .50000       -.95308E-06
   3  Normalizat    1.0822        .52531E-01    .21830E-03    .19498E-03
   4  Prefactor     .77236        .54894E-01    .26432E-03    .18172E-03
                               ERR DEF=  .500    
 START SIMPLEX MINIMIZATION.    CONVERGENCE WHEN EDM .LT.   .20E-04
 SIMPLEX MINIMIZATION HAS CONVERGED.

 FCN=   5901.793     FROM SIMPLEX   STATUS=UNCHANGED    207 CALLS      451 TOTAL
                     EDM=   .12E-04    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    548.74        .33285E-03** at limit **
   2  Index         2.6157        7.8111        .20071E-06   -.95308E-06
   3  Normalizat    1.0822        .52531E-01    .52642E-08    .19498E-03
   4  Prefactor     .77236        .54894E-01    .13225E-08    .18172E-03
                               ERR DEF=  .500    

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   5901.793     FROM MIGRAD    STATUS=CONVERGED     36 CALLS      487 TOTAL
                     EDM=   .44E-10    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    7.7110        .31802E-03** at limit **
   2  Index         2.6155        5.8561        .50000       -.14643E-07
   3  Normalizat    1.0822        .19181        .43661E-04    .19404E-03
   4  Prefactor     .77236        .20039        .10573E-04    .18108E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Index      = 2.61545
  Normalizat = 1.08222
  Prefactor  = 0.772358
 **********
 **   18 **HESSE 
 **********

 FCN=   5901.793     FROM HESSE     STATUS=OK            29 CALLS      516 TOTAL
                     EDM=   .42E-10    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    4.7367        .63604E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.6155        8.3190        .50000       -.49713    
   3  Normalizat    1.0822        .19201        .87321E-05   -.90325    
   4  Prefactor     .77236        .20062        .21145E-05   -1.0076    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 4.20108e-11
Minuit parameter uncertainties:
  1  9.45214e-06
  2  181.771
  3  0.192134
  4  0.200812
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/502797': 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) = 5901.79319953
delta logL = 3.7003246689e-07

Extracting fit parameters...

4FGL J1521.8+4338
   Spectrum: PowerLaw
310    Prefactor:  1.000e-04  9.452e-06  1.000e-04  1.000e+04 ( 1.000e-12)
311        Index:  2.615e+00  1.818e+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:  7.724e-01  2.008e-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.082e+00  1.921e-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/502797/cmap_HighResolution_507600001_507859201_4FGL_J1521.8+4338_daily_bin1035.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='4.90e-03', job_status='DONE', photon_flux_upper_limit='6.14e-08', time_completed='2021-09-12 02:09:25.951283', job_id='502797', GAL2='0.77', fit_tolerance='1e-08', EG2='1.08', EG='1.08', time_epoch_completed='1631437765.95', return_code2='0', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.77', dlogl='3.70e-07', ts2='-0.00', photon_index_error='0.00', photon_index='2.94' WHERE bin_id='1035' AND source_name='4FGL J1521.8+4338' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sun Sep 12 02:09:25 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0220>
Subject: Job 502797: <4FGL_J1521.8+4338_daily_bin1035> in cluster <slac> Done

Job <4FGL_J1521.8+4338_daily_bin1035> was submitted from host <rhel6-64o> by user <kocevski> in cluster <slac> at Sun Sep 12 01:55:31 2021
Job was executed on host(s) <bullet0220>, in queue <medium>, as user <kocevski> in cluster <slac> at Sun Sep 12 01:55: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 01:55:33 2021
Terminated at Sun Sep 12 02:09:26 2021
Results reported at Sun Sep 12 02:09:26 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1521.8+4338_daily_bin1035 230.464 43.6344 507600001 507859201 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 :                                   807.30 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             300.54 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   833 sec.
    Turnaround time :                            835 sec.

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

