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


Performing analysis on: 4FGL_J0502.5+1340_daily_bin1496
RA = 75.6341, Dec = 13.6685
tmin = 627091201, tmax = 627350401
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='929134', job_status='RUN', time_executed='2021-08-21 18:25:14.054081', time_epoch_executed='1629595514.05' WHERE source_name='4FGL J0502.5+1340' and cadence='daily' and bin_id='1496'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/929134

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

Retrieving the FT1 file...

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

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

Retrieving 48 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/929134/ft1_4FGL_J0502.5+1340_daily_bin1496.fits


Retrieving the FT1 file...

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

Retrieving 48 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/929134/ft2_4FGL_J0502.5+1340_daily_bin1496.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/929134/ft1_4FGL_J0502.5+1340_daily_bin1496.fits outfile=/scratch/kocevski/929134/ft1_filteredMKT_4FGL_J0502.5+1340_daily_bin1496.fits ra=75.6341 dec=13.6685 rad=12.0 tmin=627091201.0 tmax=627350401.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.92
user 2.70
sys 3.16

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/929134/ft2_4FGL_J0502.5+1340_daily_bin1496.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/929134/ft2_4FGL_J0502.5+1340_daily_bin1496.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/929134/ft1_filteredMKT_4FGL_J0502.5+1340_daily_bin1496.fits evtable="EVENTS" outfile="/scratch/kocevski/929134/ft1_filtered_4FGL_J0502.5+1340_daily_bin1496.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 3.43
user 0.32
sys 3.10

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/929134/ft1_filtered_4FGL_J0502.5+1340_daily_bin1496.fits" evtable="EVENTS" scfile=/scratch/kocevski/929134/ft2_4FGL_J0502.5+1340_daily_bin1496.fits sctable="SC_DATA" outfile=/scratch/kocevski/929134/ltcube_627091201_627350401_4FGL_J0502.5+1340_daily_bin1496.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/929134/ft2_4FGL_J0502.5+1340_daily_bin1496.fits
.....................!
real 15.64
user 11.94
sys 3.66

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/929134/ft1_filtered_4FGL_J0502.5+1340_daily_bin1496.fits evtable="EVENTS" scfile=/scratch/kocevski/929134/ft2_4FGL_J0502.5+1340_daily_bin1496.fits sctable="SC_DATA" expcube=/scratch/kocevski/929134/ltcube_627091201_627350401_4FGL_J0502.5+1340_daily_bin1496.fits outfile=/scratch/kocevski/929134/expmap_627091201_627350401_4FGL_J0502.5+1340_daily_bin1496.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/929134/ltcube_627091201_627350401_4FGL_J0502.5+1340_daily_bin1496.fits
.....................!
real 196.66
user 187.32
sys 9.00

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 S 147 in ROI, make sure /nfs/farm/g/glast/g/LCRepository/Likelihood/ExtendedSources/Extended_archive_v18/Templates/S147.fits is the correct path to the extended template.
Extended source IC 443 in ROI with RadialGaussian spatial model.
Added 161 point sources and 2 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 J0502.5+1340 @ 75.6341 13.6685

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/929134/ft1_filtered_4FGL_J0502.5+1340_daily_bin1496.fits scfile=/scratch/kocevski/929134/ft2_4FGL_J0502.5+1340_daily_bin1496.fits outfile=/scratch/kocevski/929134/cmap_627091201_627350401_4FGL_J0502.5+1340_daily_bin1496.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=75.6341 yref=13.6685 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 3.49
user 0.37
sys 3.02

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/929134/ft1_filtered_4FGL_J0502.5+1340_daily_bin1496.fits scfile=/scratch/kocevski/929134/ft2_4FGL_J0502.5+1340_daily_bin1496.fits outfile=/scratch/kocevski/929134/cmap_HighResolution_627091201_627350401_4FGL_J0502.5+1340_daily_bin1496.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=75.6341 yref=13.6685 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 3.44
user 0.38
sys 3.04

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/929134/ft1_filtered_4FGL_J0502.5+1340_daily_bin1496.fits evtable="EVENTS" scfile=/scratch/kocevski/929134/ft2_4FGL_J0502.5+1340_daily_bin1496.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/929134/Model_4FGL_J0502.5+1340_daily_bin1496.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
adding source IC 443
adding source S 147
Working on...
/scratch/kocevski/929134/ft1_filtered_4FGL_J0502.5+1340_daily_bin1496.fits.....................!
real 92.74
user 87.59
sys 4.94

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/929134/ft1_filtered_4FGL_J0502.5+1340_daily_bin1496.fits', '/scratch/kocevski/929134/ft2_4FGL_J0502.5+1340_daily_bin1496.fits', expMap='/scratch/kocevski/929134/expmap_627091201_627350401_4FGL_J0502.5+1340_daily_bin1496.fits', expCube='/scratch/kocevski/929134/ltcube_627091201_627350401_4FGL_J0502.5+1340_daily_bin1496.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/929134/Model_4FGL_J0502.5+1340_daily_bin1496.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J0502.5+1340'

4FGL J0502.5+1340
   Spectrum: PowerLaw
218    Prefactor:  1.139e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
219        Index:  2.232e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
220        Scale:  1.884e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/929134/ft1_filtered_4FGL_J0502.5+1340_daily_bin1496.fits
Spacecraft file(s): /scratch/kocevski/929134/ft2_4FGL_J0502.5+1340_daily_bin1496.fits
Exposure map: /scratch/kocevski/929134/expmap_627091201_627350401_4FGL_J0502.5+1340_daily_bin1496.fits
Exposure cube: /scratch/kocevski/929134/ltcube_627091201_627350401_4FGL_J0502.5+1340_daily_bin1496.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/929134/Model_4FGL_J0502.5+1340_daily_bin1496.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) = 3533.59206839

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10013E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10097E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    82.469       1.0000         .10000E-03   10000.    
     4 'norm      '    21.668       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .27164E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
     7 'norm      '    .10465       1.0000         .10000E-03   10000.    
     8 'Prefactor '    81.456       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10190E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    66.384       1.0000         .10000E-03   10000.    
    11 'norm      '    .51329       1.0000         .10000E-03   10000.    
    12 'norm      '    17.729       1.0000         .10000E-03   10000.    
    13 'Prefactor '    .90034E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .39496E-01   1.0000         .10000E-03   10000.    
    16 'Prefactor '    95.317       1.0000         .10000E-03   10000.    
    17 'norm      '    9.8307       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    19 'norm      '    4.7642       1.0000         .10000E-03   10000.    
    20 'norm      '    2.3345       1.0000         .10000E-03   10000.    
    21 'Prefactor '    .46090       1.0000         .10000E-03   10000.    
    22 'norm      '    7.0091       1.0000         .10000E-03   10000.    
    23 'Prefactor '    2.7169       1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    25 'Prefactor '    33.202       1.0000         .10000E-03   10000.    
    26 'Prefactor '    .10136E-03   1.0000         .10000E-03   10000.    
    27 'Prefactor '    .10011E-03   1.0000         .10000E-03   10000.    
    28 'Normalizat'    .58880E-01   1.0000         .10000E-01   10.000    
    29 'Prefactor '    1.1012       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5520E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   3533.493     FROM MIGRAD    STATUS=CONVERGED    106 CALLS     3756 TOTAL
                     EDM=   .15E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.6%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .16563E-02    69.267       -.48744E-05** at limit **
   2  Prefactor     .27670E-03    127.19       -.66067E-05** at limit **
   3  Prefactor     82.470        1.0096        .40648E-08   -.24907E-03
   4  norm          21.673        1.3465        .15623E-07    .99334E-03
   5  Prefactor     .11328E-03    2.0062       -.76955E-06** at limit **
   6  Prefactor     .10002E-03    21.032        .11651E-07** at limit **
   7  norm          .10816        .70701        .32278E-06    .23083E-03
   8  Prefactor     81.483        4.3770        .13589E-06   -.73619E-02
   9  Prefactor     .36413E-03    205.31       -.79007E-05** at limit **
  10  Prefactor     66.397        1.9197        .52658E-07    .11024E-02
  11  norm          .51412        1.8652        .43359E-06    .20751E-03
  12  norm          17.733        1.1126        .78403E-08   -.35241E-04
  13  Prefactor     .10258E-03    14.938       -.21889E-05** at limit **
  14  norm          .10000E-03    5.8476       -.79893E-06** at limit **
  15  Prefactor     .45399E-01    4.6740        .12279E-05   -.69050E-03
  16  Prefactor     95.347        4.8397        .14027E-06   -.85561E-02
  17  norm          9.8294        6.7720        .20140E-06    .84142E-03
  18  Prefactor     .10281E-03    48.893       -.41279E-06** at limit **
  19  norm          4.7639        1.0244       -.12930E-07    .65436E-04
  20  norm          2.3347        3.0936        .10569E-05    .95828E-03
  21  Prefactor     .46073        .25158        .55532E-07    .44818E-02
  22  norm          7.0118        5.8532        .24981E-07    .50068E-03
  23  Prefactor     2.7181        2.0639       -.24967E-07    .51049E-03
  24  Prefactor     .10001E-03    19.627        .83350E-06** at limit **
  25  Prefactor     33.196        1.2917       -.35426E-07   -.59381E-03
  26  Prefactor     .10197E-03    44.395       -.41421E-06** at limit **
  27  Prefactor     .10000E-03    4.5070        .19033E-05** at limit **
  28  Normalizat    .56428E-01    6.5035       -.29962E-04    .95674E-05
  29  Prefactor     1.1015        .15314        .11712E-05    .43120E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.00165634
  Prefactor  = 0.000276699
  Prefactor  = 82.4695
  norm       = 21.6727
  Prefactor  = 0.000113284
  Prefactor  = 0.000100016
  norm       = 0.108157
  Prefactor  = 81.4828
  Prefactor  = 0.000364125
  Prefactor  = 66.3968
  norm       = 0.514118
  norm       = 17.7332
  Prefactor  = 0.000102579
  norm       = 0.0001
  Prefactor  = 0.0453989
  Prefactor  = 95.347
  norm       = 9.82939
  Prefactor  = 0.000102814
  norm       = 4.76394
  norm       = 2.33468
  Prefactor  = 0.460729
  norm       = 7.01177
  Prefactor  = 2.71812
  Prefactor  = 0.000100006
  Prefactor  = 33.1958
  Prefactor  = 0.000101971
  Prefactor  = 0.000100001
  Normalizat = 0.0564276
  Prefactor  = 1.10149
 **********
 **   18 **HESSE 
 **********

 FCN=   3533.493     FROM HESSE     STATUS=NOT POSDEF   623 CALLS     4379 TOTAL
                     EDM=   .10E-04    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .16563E-02    766.10        .90712E-02   -1.5700    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     .27670E-03    476.02        .90712E-02   -1.5705    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     82.470        140.45        .11058E-02   -1.3889    
   4  norm          21.673        30.489        .21512E-02   -1.4777    
   5  Prefactor     .11328E-03    837.08        .10716E-01   -1.5707    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10002E-03    19.727        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  norm          .10816        19.014        .95334E-01   -1.5642    
   8  Prefactor     81.483        207.28        .11126E-02   -1.3900    
   9  Prefactor     .36413E-03    292.66        .90712E-02   -1.5711    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     66.397        62.734        .12315E-02   -1.4076    
  11  norm          .51412        5.5597        .11325E-01   -1.5565    
  12  norm          17.733        16.958        .23780E-02   -1.4865    
  13  Prefactor     .10258E-03    41.674        .76352E-01   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          .10000E-03    5.4801        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .45399E-01    17.562        .92187E-01   -1.5665    
  16  Prefactor     95.347        176.53        .10292E-02   -1.3752    
  17  norm          9.8294        6.5405        .31951E-02   -1.5081    
  18  Prefactor     .10281E-03    46.472        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  norm          4.7639        14.163        .46083E-02   -1.5271    
  20  norm          2.3347        6.7077        .67095E-02   -1.5402    
  21  Prefactor     .46073        .24013        .29091E-02   -1.5572    
  22  norm          7.0118        5.1011        .37882E-02   -1.5178    
  23  Prefactor     2.7181        4.5354        .61772E-02   -1.5378    
  24  Prefactor     .10001E-03    18.418        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     33.196        49.050        .17386E-02   -1.4555    
  26  Prefactor     .10197E-03    42.028        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  Prefactor     .10000E-03    4.3075        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  Normalizat    .56428E-01    7.4106        .50000       -1.4343    
  29  Prefactor     1.1015        .81802        .37541E-01   -.89419    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 1.04704e-05
Minuit parameter uncertainties:
  1  2.21276
  2  0.584743
  3  141.021
  4  30.5107
  5  0.213963
  6  0.0011196
  7  2.86774
  8  209.163
  9  0.5588
  10  62.797
  11  3.38141
  12  16.963
  13  0.0207503
  14  6.31517e-05
  15  1.78437
  16  177.514
  17  6.54096
  18  0.0228906
  19  14.1728
  20  6.7099
  21  0.240128
  22  5.10143
  23  4.53598
  24  0.000642135
  25  49.1095
  26  0.0182144
  27  0.000132138
  28  3.31052
  29  0.82763
Done.

MINUIT Return Code (Fixed Index): 102
logL (Fixed Index) = 3533.49347253

Extracting fit parameters...

4FGL J0502.5+1340
   Spectrum: PowerLaw
218    Prefactor:  6.640e+01  6.280e+01  1.000e-04  1.000e+04 ( 1.000e-13)
219        Index:  2.232e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
220        Scale:  1.884e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
541    Prefactor:  1.101e+00  8.276e-01  0.000e+00  1.000e+01 ( 1.000e+00)
542        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
543        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
540   Normalization:  5.643e-02  3.311e+00  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 5.24
Ra Dec: 75.634 13.668
Photon Index (Fixed Index): 2.23 +/- 0.00
Photon Flux (Fixed Index): 3.78e-07 +/- 3.57e-07
Energy Flux (Fixed Index): 1.60e-04 +/- 1.52e-04

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) = 3532.55906307
delta logL = 0.934409456397

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 3532.55692531
delta logL = 0.936547218274

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    106.14       1.0000         .10000E-03   10000.    
     2 'Index     '    1.5687       1.0000          .0000       10.000    
     3 'Normalizat'    .22714       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.0862       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5520E+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=   3532.557     FROM MIGRAD    STATUS=CONVERGED     89 CALLS      323 TOTAL
                     EDM=   .20E-10    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     106.14        69.864        .39034E-04   -.26795E-05
   2  Index         1.5687        .43960        .61693E-02   -.59983E-06
   3  Normalizat    .22720        .89225        .17126E-01    .70995E-05
   4  Prefactor     1.0862        .15718        .15245E-03    .22371E-06
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 106.138
  Index      = 1.56869
  Normalizat = 0.227196
  Prefactor  = 1.08623
 **********
 **   18 **HESSE 
 **********

 FCN=   3532.557     FROM HESSE     STATUS=OK            27 CALLS      350 TOTAL
                     EDM=   .35E-13    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     106.14        70.052        .78069E-05   -1.3644    
   2  Index         1.5687        .44029        .24677E-03   -.75634    
   3  Normalizat    .22720        .80665        .68502E-03   -1.2748    
   4  Prefactor     1.0862        .14864        .60982E-05   -.89908    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 3.45659e-14
Minuit parameter uncertainties:
  1  70.1063
  2  0.441369
  3  0.854863
  4  0.148695
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/929134': 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) = 3532.55692531
delta logL = 0.936547223225

Extracting fit parameters...

4FGL J0502.5+1340
   Spectrum: PowerLaw
218    Prefactor:  1.061e+02  7.011e+01  1.000e-04  1.000e+04 ( 1.000e-13)
219        Index:  1.569e+00  4.414e-01  0.000e+00  1.000e+01 (-1.000e+00)
220        Scale:  1.884e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
541    Prefactor:  1.086e+00  1.487e-01  0.000e+00  1.000e+01 ( 1.000e+00)
542        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
543        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
540   Normalization:  2.272e-01  8.549e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 7.02
Ra Dec: 75.634 13.668
Photon Index (Free Index): 1.57 +/- 0.44
Photon Flux (Free Index): 1.83e-07 +/- 1.71e-07
Energy Flux (Free Index): 4.60e-04 +/- 4.76e-04

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/929134/cmap_HighResolution_627091201_627350401_4FGL_J0502.5+1340_daily_bin1496.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET comment='SUCCESS', photon_flux='3.78e-07', energy_flux2='4.60e-04', photon_flux_error='3.57e-07', dlogl='9.37e-01', energy_flux='1.60e-04', photon_flux2='1.83e-07', job_status='DONE', time_completed='2021-08-21 18:35:45.414588', photon_index_error2='0.44', photon_index2='1.57', ts='5.24', fit_tolerance='1e-08', GAL='1.10', photon_index_error='0.00', energy_flux_error2='4.76e-04', EG='0.06', time_epoch_completed='1629596145.41', return_code='102', job_id='929134', GAL2='1.09', EG2='0.23', return_code2='0', energy_flux_error='1.52e-04', photon_flux_error2='1.71e-07', ts2='7.02', photon_index='2.23' WHERE bin_id='1496' AND source_name='4FGL J0502.5+1340' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sat Aug 21 18:35:45 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0117>
Subject: Job 929134: <4FGL_J0502.5+1340_daily_bin1496> in cluster <slac> Done

Job <4FGL_J0502.5+1340_daily_bin1496> was submitted from host <rhel6-64h> by user <kocevski> in cluster <slac> at Sat Aug 21 18:20:29 2021
Job was executed on host(s) <bullet0117>, in queue <medium>, as user <kocevski> in cluster <slac> at Sat Aug 21 18:20:31 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sat Aug 21 18:20:31 2021
Terminated at Sat Aug 21 18:35:46 2021
Results reported at Sat Aug 21 18:35:46 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J0502.5+1340_daily_bin1496 75.6341 13.6685 627091201 627350401 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J0502.5+1340 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   667.35 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             266.23 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   915 sec.
    Turnaround time :                            917 sec.

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

