/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 93 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 = 7484
number of fields = 22
No RA_SUN column yet. Adding RA_SUN/DEC_SUN columns.
Done.


Performing analysis on: 4FGL_J2339.6+0242_daily_bin99
RA = 354.904, Dec = 2.7102
tmin = 264988801, tmax = 265248001
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='69752', job_status='RUN', time_executed='2021-09-30 02:32:06.411532', time_epoch_executed='1632994326.41' WHERE source_name='4FGL J2339.6+0242' and cadence='daily' and bin_id='99'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/69752

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/69752/ft1_4FGL_J2339.6+0242_daily_bin99.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/69752/ft2_4FGL_J2339.6+0242_daily_bin99.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/69752/ft1_4FGL_J2339.6+0242_daily_bin99.fits outfile=/scratch/kocevski/69752/ft1_filteredMKT_4FGL_J2339.6+0242_daily_bin99.fits ra=354.904 dec=2.7102 rad=12.0 tmin=264988801.0 tmax=265248001.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 1.44
user 1.25
sys 0.18

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

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

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/69752/ft1_filtered_4FGL_J2339.6+0242_daily_bin99.fits" evtable="EVENTS" scfile=/scratch/kocevski/69752/ft2_4FGL_J2339.6+0242_daily_bin99.fits sctable="SC_DATA" outfile=/scratch/kocevski/69752/ltcube_264988801_265248001_4FGL_J2339.6+0242_daily_bin99.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/69752/ft2_4FGL_J2339.6+0242_daily_bin99.fits
.....................!
real 12.40
user 12.09
sys 0.29

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/69752/ft1_filtered_4FGL_J2339.6+0242_daily_bin99.fits evtable="EVENTS" scfile=/scratch/kocevski/69752/ft2_4FGL_J2339.6+0242_daily_bin99.fits sctable="SC_DATA" expcube=/scratch/kocevski/69752/ltcube_264988801_265248001_4FGL_J2339.6+0242_daily_bin99.fits outfile=/scratch/kocevski/69752/expmap_264988801_265248001_4FGL_J2339.6+0242_daily_bin99.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/69752/ltcube_264988801_265248001_4FGL_J2339.6+0242_daily_bin99.fits
.....................!
real 191.13
user 185.88
sys 4.93

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/69752/ft1_filtered_4FGL_J2339.6+0242_daily_bin99.fits scfile=/scratch/kocevski/69752/ft2_4FGL_J2339.6+0242_daily_bin99.fits outfile=/scratch/kocevski/69752/cmap_264988801_265248001_4FGL_J2339.6+0242_daily_bin99.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.49
user 0.34
sys 0.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/69752/ft1_filtered_4FGL_J2339.6+0242_daily_bin99.fits scfile=/scratch/kocevski/69752/ft2_4FGL_J2339.6+0242_daily_bin99.fits outfile=/scratch/kocevski/69752/cmap_HighResolution_264988801_265248001_4FGL_J2339.6+0242_daily_bin99.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.53
user 0.38
sys 0.15

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

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/69752/ft1_filtered_4FGL_J2339.6+0242_daily_bin99.fits', '/scratch/kocevski/69752/ft2_4FGL_J2339.6+0242_daily_bin99.fits', expMap='/scratch/kocevski/69752/expmap_264988801_265248001_4FGL_J2339.6+0242_daily_bin99.fits', expCube='/scratch/kocevski/69752/ltcube_264988801_265248001_4FGL_J2339.6+0242_daily_bin99.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/69752/Model_4FGL_J2339.6+0242_daily_bin99.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/69752/ft1_filtered_4FGL_J2339.6+0242_daily_bin99.fits
Spacecraft file(s): /scratch/kocevski/69752/ft2_4FGL_J2339.6+0242_daily_bin99.fits
Exposure map: /scratch/kocevski/69752/expmap_264988801_265248001_4FGL_J2339.6+0242_daily_bin99.fits
Exposure cube: /scratch/kocevski/69752/ltcube_264988801_265248001_4FGL_J2339.6+0242_daily_bin99.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/69752/Model_4FGL_J2339.6+0242_daily_bin99.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) = 7219.82343738

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    16.468       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     5 'norm      '    .12886E-03   1.0000         .10000E-03   10000.    
     6 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .56431E-03   1.0000         .10000E-03   10000.    
     8 'norm      '    6.7128       1.0000         .10000E-03   10000.    
     9 'Prefactor '    12.365       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10054E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    9.0314       1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10853E-03   1.0000         .10000E-03   10000.    
    13 'norm      '    2.5159       1.0000         .10000E-03   10000.    
    14 'norm      '    .26676E-01   1.0000         .10000E-03   10000.    
    15 'Prefactor '    6.3420       1.0000         .10000E-03   10000.    
    16 'Prefactor '    .10020E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    10.022       1.0000         .10000E-03   10000.    
    18 'Prefactor '    2.4562       1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .27482       1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
    22 'norm      '    .10017E-03   1.0000         .10000E-03   10000.    
    23 'norm      '    .12032E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10026E-03   1.0000         .10000E-03   10000.    
    25 'Prefactor '    .16806E-03   1.0000         .10000E-03   10000.    
    26 'Prefactor '    48.232       1.0000         .10000E-03   10000.    
    27 'Prefactor '    .10015E-03   1.0000         .10000E-03   10000.    
    28 'Prefactor '    .60910       1.0000         .10000E-03   10000.    
    29 'Normalizat'    1.0968       1.0000         .10000E-01   10.000    
    30 'Prefactor '    .98931       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.

 FCN=   7219.816     FROM MIGRAD    STATUS=CONVERGED    788 CALLS     3987 TOTAL
                     EDM=   .10E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .9%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    3.4963       -.28571E-07** at limit **
   2  Prefactor     .10000E-03    16.983        .45394E-05** at limit **
   3  Prefactor     16.472        13.944        .57459E-06    .19926E-03
   4  Prefactor     .10000E-03    2.3025        .27749E-07** at limit **
   5  norm          .10000E-03    1.2770       -.29169E-06** at limit **
   6  norm          .10000E-03    1.2244       -.49572E-08** at limit **
   7  Prefactor     .10001E-03    6.7353       -.70230E-06** at limit **
   8  norm          6.7122        9.0766       -.18469E-06   -.48911E-04
   9  Prefactor     12.361        30.864       -.39196E-05   -.35681E-05
  10  Prefactor     .10000E-03    10.422        .49155E-05** at limit **
  11  Prefactor     9.0293        12.904        .18728E-06   -.69590E-05
  12  Prefactor     .10000E-03    5.4383       -.10744E-06** at limit **
  13  norm          2.5162        1.0348       -.80088E-07    .35977E-03
  14  norm          .10068E-03    5.7196       -.63971E-06** at limit **
  15  Prefactor     6.3388        12.112       -.25578E-06   -.20952E-04
  16  Prefactor     .10000E-03    19.817       -.85742E-05** at limit **
  17  norm          10.027        10.606       -.40801E-06    .96451E-04
  18  Prefactor     2.4498        7.4827       -.46520E-05   -.55632E-03
  19  Prefactor     .10000E-03    50.128       -.15535E-04** at limit **
  20  Prefactor     .31115        7.0176       -.69183E-06   -.55010E-03
  21  Prefactor     .10000E-03    10.749       -.50386E-05** at limit **
  22  norm          .10000E-03    30.512        .14204E-04** at limit **
  23  norm          .10000E-03    59.019        .40181E-04** at limit **
  24  Prefactor     .10000E-03    47.524       -.24393E-04** at limit **
  25  Prefactor     .10000E-03    2.7103       -.45541E-06** at limit **
  26  Prefactor     48.212        39.692       -.76995E-05    .31961E-04
  27  Prefactor     .10000E-03    8.2743        .21040E-06** at limit **
  28  Prefactor     .60302        6.4412       -.90066E-06   -.59789E-04
  29  Normalizat    1.0968        .19434        .24645E-05    .23151E-03
  30  Prefactor     .98937        .13052        .27303E-06    .24631E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 16.4721
  Prefactor  = 0.0001
  norm       = 0.000100001
  norm       = 0.0001
  Prefactor  = 0.000100008
  norm       = 6.71223
  Prefactor  = 12.3605
  Prefactor  = 0.0001
  Prefactor  = 9.0293
  Prefactor  = 0.0001
  norm       = 2.51623
  norm       = 0.000100677
  Prefactor  = 6.33881
  Prefactor  = 0.0001
  norm       = 10.0273
  Prefactor  = 2.44976
  Prefactor  = 0.0001
  Prefactor  = 0.311152
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 0.000100002
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 48.2116
  Prefactor  = 0.0001
  Prefactor  = 0.603017
  Normalizat = 1.09679
  Prefactor  = 0.989372
 **********
 **   18 **HESSE 
 **********

 FCN=   7219.816     FROM HESSE     STATUS=OK           604 CALLS     4591 TOTAL
                     EDM=   .28E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    3.5001        .15517E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     .10000E-03    16.983        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     16.472        13.425        .98697E-04   -1.4896    
   4  Prefactor     .10000E-03    2.3124        .12591E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  norm          .10000E-03    7.1566        .17559E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  norm          .10000E-03    1.2267        .91805E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10001E-03    67.156        .42437E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          6.7122        9.0719        .15487E-03   -1.5190    
   9  Prefactor     12.361        30.874        .11392E-03   -1.5005    
  10  Prefactor     .10000E-03    10.590        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     9.0293        12.897        .13337E-03   -1.5107    
  12  Prefactor     .10000E-03    33.961        .35661E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  norm          2.5162        1.0302        .51992E-04   -1.5391    
  14  norm          .10068E-03    6.6924        .51796E-01   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     6.3388        12.044        .15939E-03   -1.5204    
  16  Prefactor     .10000E-03    19.802        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          10.027        10.337        .12657E-03   -1.5075    
  18  Prefactor     2.4498        7.4304        .26098E-03   -1.5395    
  19  Prefactor     .10000E-03    50.068        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .31115        49.055        .40280E-02   -1.5596    
  21  Prefactor     .10000E-03    10.744        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  norm          .10000E-03    30.733        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  norm          .10000E-03    59.211        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     .10000E-03    47.479        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     .10000E-03    5.3921        .25589E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  Prefactor     48.212        39.640        .57739E-04   -1.4318    
  27  Prefactor     .10000E-03    8.2979        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  Prefactor     .60302        46.317        .41148E-02   -1.5553    
  29  Normalizat    1.0968        .22361        .28575E-03   -.89855    
  30  Prefactor     .98937        .15228        .21266E-03   -.93085    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.81441e-08
Minuit parameter uncertainties:
  1  2.94839e-06
  2  8.85788e-06
  3  13.427
  4  3.18829e-06
  5  0.00012083
  6  1.02542e-06
  7  0.00151149
  8  9.07378
  9  30.9135
  10  2.69723e-05
  11  12.9012
  12  0.000207257
  13  1.03018
  14  0.00425903
  15  12.0482
  16  1.39103e-05
  17  10.3386
  18  7.43316
  19  1.03537e-05
  20  7.81896
  21  3.47453e-05
  22  4.93137e-05
  23  0.000699945
  24  1.85879e-05
  25  0.000103106
  26  39.6618
  27  1.20624e-05
  28  10.5774
  29  0.223807
  30  0.152349
Done.

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

Extracting fit parameters...

4FGL J2339.6+0242
   Spectrum: PowerLaw
463    Prefactor:  4.821e+01  3.966e+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:  9.894e-01  1.523e-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.097e+00  2.238e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 1.94
Ra Dec: 354.904 2.710
Photon Index (Fixed Index): 2.55 +/- 0.00
Photon Flux (Fixed Index): 5.84e-08 +/- 4.80e-08
Energy Flux (Fixed Index): 1.61e-05 +/- 1.32e-05

TS (Fixed Index): 1.94
Ra Dec: 354.904 2.710
Photon Flux Upper Limit: 1.54e-07 ph cm-2 s-1
Energy Flux Upper Limit: 1.20e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/69752/likelihoodResults_264988801_265248001_4FGL_J2339.6+0242_daily_bin99.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): 0
logL (Free Index) = 7219.53832445
delta logL = 0.277865308963

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 7219.53713202
delta logL = 0.279057735085

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    66.778       1.0000         .10000E-03   10000.    
     2 'Index     '    2.0753       1.0000          .0000       10.000    
     3 'Normalizat'    1.1199       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .97683       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=   7219.537     FROM MIGRAD    STATUS=CONVERGED     83 CALLS      300 TOTAL
                     EDM=   .62E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     66.782        51.738        .49115E-04   -.80159E-03
   2  Index         2.0752        .56505        .94398E-02   -.44876E-03
   3  Normalizat    1.1198        .21335        .28313E-03   -.12664E-03
   4  Prefactor     .97687        .15148        .21375E-03    .31509E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 66.7815
  Index      = 2.0752
  Normalizat = 1.11982
  Prefactor  = 0.976871
 **********
 **   18 **HESSE 
 **********

 FCN=   7219.537     FROM HESSE     STATUS=OK            23 CALLS      323 TOTAL
                     EDM=   .65E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     66.782        51.565        .98229E-05   -1.4072    
   2  Index         2.0752        .56299        .37759E-03   -.62483    
   3  Normalizat    1.1198        .21346        .11325E-04   -.89118    
   4  Prefactor     .97687        .15156        .42750E-04   -.93505    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 6.48e-09
Minuit parameter uncertainties:
  1  51.5999
  2  0.564811
  3  0.213627
  4  0.151626
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/69752': 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) = 7219.53713198
delta logL = 0.279057770788

Extracting fit parameters...

4FGL J2339.6+0242
   Spectrum: PowerLaw
463    Prefactor:  6.678e+01  5.160e+01  1.000e-04  1.000e+04 ( 1.000e-13)
464        Index:  2.075e+00  5.648e-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.769e-01  1.516e-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.120e+00  2.136e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 2.49
Ra Dec: 354.904 2.710
Photon Index (Free Index): 2.08 +/- 0.56
Photon Flux (Free Index): 4.40e-08 +/- 4.27e-08
Energy Flux (Free Index): 2.55e-05 +/- 2.60e-05

Creating a high resolution counts map...
INFO: Auto-setting vmin to -1.000e-01 [aplpy.core]
INFO: Auto-setting vmax to  1.110e+00 [aplpy.core]
Saving /scratch/kocevski/69752/cmap_HighResolution_264988801_265248001_4FGL_J2339.6+0242_daily_bin99.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='1.20e-02', comment='SUCCESS', photon_flux='5.84e-08', energy_flux2='2.55e-05', photon_flux_error='4.80e-08', dlogl='2.79e-01', energy_flux='1.61e-05', photon_flux2='4.40e-08', job_status='DONE', time_completed='2021-09-30 02:46:48.950464', photon_index_error2='0.56', photon_index2='2.08', ts='1.94', fit_tolerance='1e-08', GAL='0.99', photon_index_error='0.00', photon_flux_upper_limit='1.54e-07', energy_flux_error2='2.60e-05', EG='1.10', time_epoch_completed='1632995208.95', return_code='0', job_id='69752', GAL2='0.98', EG2='1.12', return_code2='0', energy_flux_error='1.32e-05', photon_flux_error2='4.27e-08', ts2='2.49', photon_index='2.55' WHERE bin_id='99' AND source_name='4FGL J2339.6+0242' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Sep 30 02:46:48 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0123>
Subject: Job 69752: <4FGL_J2339.6+0242_daily_bin99> in cluster <slac> Done

Job <4FGL_J2339.6+0242_daily_bin99> was submitted from host <rhel6-64p> by user <kocevski> in cluster <slac> at Thu Sep 30 02:30:21 2021
Job was executed on host(s) <bullet0123>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Sep 30 02:30:23 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:23 2021
Terminated at Thu Sep 30 02:46:49 2021
Results reported at Thu Sep 30 02:46:49 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J2339.6+0242_daily_bin99 354.904 2.7102 264988801 265248001 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 :                                   881.00 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             284.27 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   986 sec.
    Turnaround time :                            988 sec.

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

