/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 145 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 = 7412
number of fields = 27
No RA_SUN column yet. Adding RA_SUN/DEC_SUN columns.
Done.


Performing analysis on: 4FGL_J2339.6+0242_daily_bin297
RA = 354.904, Dec = 2.7102
tmin = 316310401, tmax = 316569601
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='70065', job_status='RUN', time_executed='2021-09-30 02:33:22.631525', time_epoch_executed='1632994402.63' WHERE source_name='4FGL J2339.6+0242' and cadence='daily' and bin_id='297'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/70065

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/70065/ft1_4FGL_J2339.6+0242_daily_bin297.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/70065/ft2_4FGL_J2339.6+0242_daily_bin297.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/70065/ft1_4FGL_J2339.6+0242_daily_bin297.fits outfile=/scratch/kocevski/70065/ft1_filteredMKT_4FGL_J2339.6+0242_daily_bin297.fits ra=354.904 dec=2.7102 rad=12.0 tmin=316310401.0 tmax=316569601.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.53
user 3.30
sys 0.21

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/70065/ft2_4FGL_J2339.6+0242_daily_bin297.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/70065/ft2_4FGL_J2339.6+0242_daily_bin297.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/70065/ft1_filteredMKT_4FGL_J2339.6+0242_daily_bin297.fits evtable="EVENTS" outfile="/scratch/kocevski/70065/ft1_filtered_4FGL_J2339.6+0242_daily_bin297.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.49
user 0.32
sys 0.16

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/70065/ft1_filtered_4FGL_J2339.6+0242_daily_bin297.fits" evtable="EVENTS" scfile=/scratch/kocevski/70065/ft2_4FGL_J2339.6+0242_daily_bin297.fits sctable="SC_DATA" outfile=/scratch/kocevski/70065/ltcube_316310401_316569601_4FGL_J2339.6+0242_daily_bin297.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/70065/ft2_4FGL_J2339.6+0242_daily_bin297.fits
.....................!
real 11.81
user 11.44
sys 0.35

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/70065/ft1_filtered_4FGL_J2339.6+0242_daily_bin297.fits evtable="EVENTS" scfile=/scratch/kocevski/70065/ft2_4FGL_J2339.6+0242_daily_bin297.fits sctable="SC_DATA" expcube=/scratch/kocevski/70065/ltcube_316310401_316569601_4FGL_J2339.6+0242_daily_bin297.fits outfile=/scratch/kocevski/70065/expmap_316310401_316569601_4FGL_J2339.6+0242_daily_bin297.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/70065/ltcube_316310401_316569601_4FGL_J2339.6+0242_daily_bin297.fits
.....................!
real 191.41
user 185.97
sys 5.14

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

Setting source of interest to:
4FGL J2339.6+0242 @ 354.904 2.7102

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/70065/ft1_filtered_4FGL_J2339.6+0242_daily_bin297.fits scfile=/scratch/kocevski/70065/ft2_4FGL_J2339.6+0242_daily_bin297.fits outfile=/scratch/kocevski/70065/cmap_316310401_316569601_4FGL_J2339.6+0242_daily_bin297.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=354.904 yref=2.7102 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.37
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/70065/ft1_filtered_4FGL_J2339.6+0242_daily_bin297.fits scfile=/scratch/kocevski/70065/ft2_4FGL_J2339.6+0242_daily_bin297.fits outfile=/scratch/kocevski/70065/cmap_HighResolution_316310401_316569601_4FGL_J2339.6+0242_daily_bin297.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=354.904 yref=2.7102 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.39
sys 0.15

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/70065/ft1_filtered_4FGL_J2339.6+0242_daily_bin297.fits evtable="EVENTS" scfile=/scratch/kocevski/70065/ft2_4FGL_J2339.6+0242_daily_bin297.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/70065/Model_4FGL_J2339.6+0242_daily_bin297.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/70065/ft1_filtered_4FGL_J2339.6+0242_daily_bin297.fits.....................!
real 65.78
user 64.43
sys 1.24

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/70065/ft1_filtered_4FGL_J2339.6+0242_daily_bin297.fits', '/scratch/kocevski/70065/ft2_4FGL_J2339.6+0242_daily_bin297.fits', expMap='/scratch/kocevski/70065/expmap_316310401_316569601_4FGL_J2339.6+0242_daily_bin297.fits', expCube='/scratch/kocevski/70065/ltcube_316310401_316569601_4FGL_J2339.6+0242_daily_bin297.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/70065/Model_4FGL_J2339.6+0242_daily_bin297.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J2339.6+0242'

4FGL J2339.6+0242
   Spectrum: PowerLaw
463    Prefactor:  8.280e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
464        Index:  2.549e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
465        Scale:  7.790e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/70065/ft1_filtered_4FGL_J2339.6+0242_daily_bin297.fits
Spacecraft file(s): /scratch/kocevski/70065/ft2_4FGL_J2339.6+0242_daily_bin297.fits
Exposure map: /scratch/kocevski/70065/expmap_316310401_316569601_4FGL_J2339.6+0242_daily_bin297.fits
Exposure cube: /scratch/kocevski/70065/ltcube_316310401_316569601_4FGL_J2339.6+0242_daily_bin297.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/70065/Model_4FGL_J2339.6+0242_daily_bin297.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) = 6134.20792235

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    11.102       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .41146E-01   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     5 'norm      '    .16371       1.0000         .10000E-03   10000.    
     6 'norm      '    13.164       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10022E-03   1.0000         .10000E-03   10000.    
     8 'norm      '    5.4306       1.0000         .10000E-03   10000.    
     9 'Prefactor '    28.376       1.0000         .10000E-03   10000.    
    10 'Prefactor '    9.1877       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    13 'norm      '    .68884       1.0000         .10000E-03   10000.    
    14 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    6.6761       1.0000         .10000E-03   10000.    
    16 'Prefactor '    38.222       1.0000         .10000E-03   10000.    
    17 'norm      '    .10084E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    3.6390       1.0000         .10000E-03   10000.    
    19 'Prefactor '    .14269E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    5.7567       1.0000         .10000E-03   10000.    
    21 'Prefactor '    10.434       1.0000         .10000E-03   10000.    
    22 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    23 'norm      '    .10002E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10017E-03   1.0000         .10000E-03   10000.    
    25 'Prefactor '    4.2891       1.0000         .10000E-03   10000.    
    26 'Prefactor '    148.91       1.0000         .10000E-03   10000.    
    27 'Prefactor '    17.521       1.0000         .10000E-03   10000.    
    28 'Prefactor '    7.2450       1.0000         .10000E-03   10000.    
    29 'Normalizat'    1.4270       1.0000         .10000E-01   10.000    
    30 'Prefactor '    .83977       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5260E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   6134.181     FROM MIGRAD    STATUS=CONVERGED    128 CALLS     3935 TOTAL
                     EDM=   .73E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  5.0%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     11.096        7.2567        .10332E-04    .62748E-02
   2  Prefactor     .12525E-02    1156.1       -.14432E-03** at limit **
   3  Prefactor     .10000E-03    16.821       -.44227E-05** at limit **
   4  Prefactor     .10000E-03    6.6597       -.32364E-06** at limit **
   5  norm          .16610        4.4386       -.48916E-05    .33606E-04
   6  norm          13.166        6.0513       -.75684E-05   -.25841E-02
   7  Prefactor     .10000E-03    4.5387        .16197E-06** at limit **
   8  norm          5.4322        1.8536       -.25987E-05   -.14501E-02
   9  Prefactor     28.389        2.7352       -.68818E-06    .31349E-02
  10  Prefactor     9.1889        2.3113        .35229E-05   -.44239E-03
  11  Prefactor     .10000E-03    12.861       -.40100E-05** at limit **
  12  Prefactor     .10000E-03    5.0227       -.18623E-07** at limit **
  13  norm          .69061        .86501        .26010E-06    .38306E-03
  14  norm          .10000E-03    2.4241        .32866E-06** at limit **
  15  Prefactor     6.6741        1.2478        .27189E-06    .21495E-02
  16  Prefactor     38.069        30.605       -.61687E-05   -.10852E-01
  17  norm          .10000E-03    6.0610        .13563E-05** at limit **
  18  Prefactor     3.6405        1.0925        .10118E-06    .15942E-02
  19  Prefactor     .10002E-03    130.21        .50525E-06** at limit **
  20  Prefactor     5.7493        9.8837       -.20580E-04    .35336E-04
  21  Prefactor     10.432        4.5849        .58593E-05   -.32761E-02
  22  norm          .10000E-03    5.9215        .37371E-06** at limit **
  23  norm          .10000E-03    14.445        .42648E-05** at limit **
  24  Prefactor     .10000E-03    31.953       -.56392E-06** at limit **
  25  Prefactor     4.2898        3.8841        .23748E-05    .53992E-04
  26  Prefactor     149.01        19.103        .26813E-05    .31908E-02
  27  Prefactor     17.527        2.5872       -.30395E-05    .37328E-02
  28  Prefactor     7.2444        1.0445        .49827E-06    .36758E-03
  29  Normalizat    1.4266        .25684        .69459E-05    .14282E-03
  30  Prefactor     .83990        .17335       -.21867E-05    .12184E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 11.096
  Prefactor  = 0.00125254
  Prefactor  = 0.000100001
  Prefactor  = 0.0001
  norm       = 0.166097
  norm       = 13.1661
  Prefactor  = 0.0001
  norm       = 5.4322
  Prefactor  = 28.3893
  Prefactor  = 9.18887
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.690611
  norm       = 0.0001
  Prefactor  = 6.67407
  Prefactor  = 38.0687
  norm       = 0.0001
  Prefactor  = 3.64054
  Prefactor  = 0.000100017
  Prefactor  = 5.7493
  Prefactor  = 10.4318
  norm       = 0.0001
  norm       = 0.000100001
  Prefactor  = 0.000100003
  Prefactor  = 4.2898
  Prefactor  = 149.008
  Prefactor  = 17.5273
  Prefactor  = 7.24437
  Normalizat = 1.42659
  Prefactor  = 0.8399
 **********
 **   18 **HESSE 
 **********

 FCN=   6134.181     FROM HESSE     STATUS=OK           666 CALLS     4601 TOTAL
                     EDM=   .13E-05    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     11.096        11.364        .30059E-02   -1.5042    
   2  Prefactor     .12525E-02    56.230        .16031       -1.5701    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10000E-03    16.712        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    6.5084        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  norm          .16610        1.1899        .44365E-01   -1.5626    
   6  norm          13.166        6.0752        .27600E-02   -1.4982    
   7  Prefactor     .10000E-03    4.5362        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          5.4322        10.339        .43109E-02   -1.5242    
   9  Prefactor     28.389        33.977        .18802E-02   -1.4642    
  10  Prefactor     9.1889        15.852        .33056E-02   -1.5102    
  11  Prefactor     .10000E-03    12.646        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10000E-03    5.0040        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  norm          .69061        .98661        .18526E-01   -1.5542    
  14  norm          .10000E-03    2.4100        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     6.6741        7.8553        .38825E-02   -1.5191    
  16  Prefactor     38.069        56.788        .16207E-02   -1.4473    
  17  norm          .10000E-03    6.0393        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     3.6405        7.9691        .52943E-02   -1.5326    
  19  Prefactor     .10002E-03    130.45        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     5.7493        14.342        .41850E-02   -1.5228    
  21  Prefactor     10.432        21.035        .31010E-02   -1.5062    
  22  norm          .10000E-03    5.9225        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  norm          .10000E-03    14.474        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     .10000E-03    31.971        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     4.2898        4.0387        .48633E-02   -1.5294    
  26  Prefactor     149.01        68.675        .82564E-03   -1.3260    
  27  Prefactor     17.527        33.183        .23921E-02   -1.4870    
  28  Prefactor     7.2444        10.478        .37255E-02   -1.5170    
  29  Normalizat    1.4266        .23700        .63446E-01   -.79863    
  30  Prefactor     .83990        .15114        .44233E-01   -.98274    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.28948e-06
Minuit parameter uncertainties:
  1  11.3667
  2  0.509622
  3  0.000250105
  4  1.37258e-05
  5  0.888905
  6  6.07546
  7  4.94044e-05
  8  10.3428
  9  34.0002
  10  15.8592
  11  3.98836e-05
  12  6.77808e-06
  13  0.986631
  14  3.25605e-06
  15  7.85649
  16  56.8691
  17  1.87395e-05
  18  7.97143
  19  0.00298405
  20  14.3505
  21  21.05
  22  4.90227e-06
  23  0.000252644
  24  0.000588963
  25  4.03892
  26  68.7119
  27  33.2176
  28  10.4802
  29  0.23718
  30  0.15121
Done.

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

Extracting fit parameters...

4FGL J2339.6+0242
   Spectrum: PowerLaw
463    Prefactor:  1.490e+02  6.871e+01  1.000e-04  1.000e+04 ( 1.000e-13)
464        Index:  2.549e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
465        Scale:  7.790e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
523    Prefactor:  8.399e-01  1.512e-01  0.000e+00  1.000e+01 ( 1.000e+00)
524        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
525        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
522   Normalization:  1.427e+00  2.372e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 7.98
Ra Dec: 354.904 2.710
Photon Index (Fixed Index): 2.55 +/- 0.00
Photon Flux (Fixed Index): 1.80e-07 +/- 8.31e-08
Energy Flux (Fixed Index): 4.97e-05 +/- 2.29e-05

Performing a free index iterative likelihood fit...

Freezing all point sources, except source of interest...

Done.

Freeing candidate source...
Done.

Fit tolerance = 1

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 6130.36638349
delta logL = 3.81457135186

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 6130.35852173
delta logL = 3.82243311523

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    24.868       1.0000         .10000E-03   10000.    
     2 'Index     '    4.0280       1.0000          .0000       10.000    
     3 'Normalizat'    1.2554       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .92473       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5260E+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=   6130.359     FROM MIGRAD    STATUS=CONVERGED     83 CALLS      306 TOTAL
                     EDM=   .15E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     24.864        81.629        .80329E-04    .32551E-04
   2  Index         4.0282        1.8328        .25943E-02   -.68170E-04
   3  Normalizat    1.2555        .26549        .29451E-03   -.35196E-03
   4  Prefactor     .92480        .18196        .23198E-03   -.45587E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 24.8641
  Index      = 4.02819
  Normalizat = 1.25549
  Prefactor  = 0.924797
 **********
 **   18 **HESSE 
 **********

 FCN=   6130.359     FROM HESSE     STATUS=OK            25 CALLS      331 TOTAL
                     EDM=   .53E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     24.864        32.811        .32131E-05   -1.4710    
   2  Index         4.0282        .74881        .10377E-03   -.19561    
   3  Normalizat    1.2555        .26502        .58903E-04   -.84905    
   4  Prefactor     .92480        .17825        .46396E-04   -.95280    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 5.34522e-10
Minuit parameter uncertainties:
  1  32.8346
  2  0.751746
  3  0.265307
  4  0.178363
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/70065': 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) = 6130.35852044
delta logL = 3.82243440223

Extracting fit parameters...

4FGL J2339.6+0242
   Spectrum: PowerLaw
463    Prefactor:  2.486e+01  3.283e+01  1.000e-04  1.000e+04 ( 1.000e-13)
464        Index:  4.028e+00  7.517e-01  0.000e+00  1.000e+01 (-1.000e+00)
465        Scale:  7.790e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
523    Prefactor:  9.248e-01  1.784e-01  0.000e+00  1.000e+01 ( 1.000e+00)
524        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
525        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
522   Normalization:  1.255e+00  2.653e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 16.67
Ra Dec: 354.904 2.710
Photon Index (Free Index): 4.03 +/- 0.75
Photon Flux (Free Index): 3.22e-07 +/- 1.03e-07
Energy Flux (Free Index): 4.79e-05 +/- 1.62e-05

Creating a high resolution counts map...
INFO: Auto-setting vmin to  0.000e+00 [aplpy.core]
INFO: Auto-setting vmax to  0.000e+00 [aplpy.core]
Saving /scratch/kocevski/70065/cmap_HighResolution_316310401_316569601_4FGL_J2339.6+0242_daily_bin297.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET comment='SUCCESS', photon_flux='1.80e-07', energy_flux2='4.79e-05', photon_flux_error='8.31e-08', dlogl='3.82e+00', energy_flux='4.97e-05', photon_flux2='3.22e-07', job_status='DONE', time_completed='2021-09-30 02:45:25.893026', photon_index_error2='0.75', photon_index2='4.03', ts='7.98', fit_tolerance='1e-08', GAL='0.84', photon_index_error='0.00', energy_flux_error2='1.62e-05', EG='1.43', time_epoch_completed='1632995125.89', return_code='0', job_id='70065', GAL2='0.92', EG2='1.26', return_code2='0', energy_flux_error='2.29e-05', photon_flux_error2='1.03e-07', ts2='16.67', photon_index='2.55' WHERE bin_id='297' AND source_name='4FGL J2339.6+0242' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Sep 30 02:45:25 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0299>
Subject: Job 70065: <4FGL_J2339.6+0242_daily_bin297> in cluster <slac> Done

Job <4FGL_J2339.6+0242_daily_bin297> was submitted from host <rhel6-64p> by user <kocevski> in cluster <slac> at Thu Sep 30 02:30:46 2021
Job was executed on host(s) <bullet0299>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Sep 30 02:30:49 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Thu Sep 30 02:30:49 2021
Terminated at Thu Sep 30 02:45:26 2021
Results reported at Thu Sep 30 02:45:26 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J2339.6+0242_daily_bin297 354.904 2.7102 316310401 316569601 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J2339.6+0242 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   720.00 sec.
    Max Memory :                                 1093 MB
    Average Memory :                             279.34 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   877 sec.
    Turnaround time :                            880 sec.

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

