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


Performing analysis on: 4FGL_J2339.6+0242_daily_bin986
RA = 354.904, Dec = 2.7102
tmin = 494899201, tmax = 495158401
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='74557', job_status='RUN', time_executed='2021-09-30 02:48:26.323085', time_epoch_executed='1632995306.32' WHERE source_name='4FGL J2339.6+0242' and cadence='daily' and bin_id='986'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/74557

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/74557/ft1_4FGL_J2339.6+0242_daily_bin986.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/74557/ft2_4FGL_J2339.6+0242_daily_bin986.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/74557/ft1_4FGL_J2339.6+0242_daily_bin986.fits outfile=/scratch/kocevski/74557/ft1_filteredMKT_4FGL_J2339.6+0242_daily_bin986.fits ra=354.904 dec=2.7102 rad=12.0 tmin=494899201.0 tmax=495158401.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.62
user 3.40
sys 0.20

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/74557/ft2_4FGL_J2339.6+0242_daily_bin986.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/74557/ft1_filteredMKT_4FGL_J2339.6+0242_daily_bin986.fits evtable="EVENTS" outfile="/scratch/kocevski/74557/ft1_filtered_4FGL_J2339.6+0242_daily_bin986.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.34
sys 0.13

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/74557/ft1_filtered_4FGL_J2339.6+0242_daily_bin986.fits" evtable="EVENTS" scfile=/scratch/kocevski/74557/ft2_4FGL_J2339.6+0242_daily_bin986.fits sctable="SC_DATA" outfile=/scratch/kocevski/74557/ltcube_494899201_495158401_4FGL_J2339.6+0242_daily_bin986.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/74557/ft2_4FGL_J2339.6+0242_daily_bin986.fits
.....................!
real 11.71
user 11.37
sys 0.31

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/74557/ft1_filtered_4FGL_J2339.6+0242_daily_bin986.fits evtable="EVENTS" scfile=/scratch/kocevski/74557/ft2_4FGL_J2339.6+0242_daily_bin986.fits sctable="SC_DATA" expcube=/scratch/kocevski/74557/ltcube_494899201_495158401_4FGL_J2339.6+0242_daily_bin986.fits outfile=/scratch/kocevski/74557/expmap_494899201_495158401_4FGL_J2339.6+0242_daily_bin986.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/74557/ltcube_494899201_495158401_4FGL_J2339.6+0242_daily_bin986.fits
.....................!
real 189.54
user 185.02
sys 4.17

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/74557/ft1_filtered_4FGL_J2339.6+0242_daily_bin986.fits scfile=/scratch/kocevski/74557/ft2_4FGL_J2339.6+0242_daily_bin986.fits outfile=/scratch/kocevski/74557/cmap_494899201_495158401_4FGL_J2339.6+0242_daily_bin986.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.52
user 0.37
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/74557/ft1_filtered_4FGL_J2339.6+0242_daily_bin986.fits scfile=/scratch/kocevski/74557/ft2_4FGL_J2339.6+0242_daily_bin986.fits outfile=/scratch/kocevski/74557/cmap_HighResolution_494899201_495158401_4FGL_J2339.6+0242_daily_bin986.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.37
sys 0.15

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

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

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10180E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10012E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10020E-03   1.0000         .10000E-03   10000.    
     5 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
     6 'norm      '    .10005E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    10.223       1.0000         .10000E-03   10000.    
     8 'norm      '    24.747       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10926E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    8.6988       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10282E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    3.9084       1.0000         .10000E-03   10000.    
    13 'norm      '    .10007E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    .29266       1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    .10023E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    .29681E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    384.18       1.0000         .10000E-03   10000.    
    20 'Prefactor '    1.5844       1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10384E-03   1.0000         .10000E-03   10000.    
    22 'norm      '    22.960       1.0000         .10000E-03   10000.    
    23 'norm      '    .19036E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10035E-03   1.0000         .10000E-03   10000.    
    25 'Prefactor '    .54097E-03   1.0000         .10000E-03   10000.    
    26 'Prefactor '    45.528       1.0000         .10000E-03   10000.    
    27 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
    28 'Prefactor '    1.0328       1.0000         .10000E-03   10000.    
    29 'Normalizat'    .97959       1.0000         .10000E-01   10.000    
    30 'Prefactor '    .90838       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=   4939.128     FROM MIGRAD    STATUS=CONVERGED    741 CALLS     3941 TOTAL
                     EDM=   .18E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  2.0%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    8.4953       -.77912E-07** at limit **
   2  Prefactor     .10000E-03    25.377        .79810E-08** at limit **
   3  Prefactor     .10000E-03    13.176       -.58547E-07** at limit **
   4  Prefactor     .10000E-03    2.9853       -.36018E-07** at limit **
   5  norm          .10000E-03    .84534       -.43963E-07** at limit **
   6  norm          .10000E-03    1.5203       -.48198E-07** at limit **
   7  Prefactor     10.232        14.505        .14087E-05   -.17120E-03
   8  norm          24.745        15.840        .72956E-07    .73367E-04
   9  Prefactor     .10000E-03    49.463       -.79493E-06** at limit **
  10  Prefactor     8.7027        11.612       -.11230E-06    .15207E-05
  11  Prefactor     .10000E-03    5.3296        .17766E-08** at limit **
  12  Prefactor     3.9112        8.9681        .73989E-06   -.98391E-05
  13  norm          .10000E-03    .39107       -.10500E-05** at limit **
  14  norm          .28243        3.8071        .35319E-06   -.35996E-03
  15  Prefactor     .10000E-03    3.4034        .15055E-07** at limit **
  16  Prefactor     .10000E-03    24.165        .14800E-06** at limit **
  17  norm          .10000E-03    3.2600        .15144E-08** at limit **
  18  Prefactor     .10000E-03    3.7463       -.91017E-07** at limit **
  19  Prefactor     383.81        301.20        .10857E-04    .88662E-04
  20  Prefactor     1.6241        35.354        .60190E-05    .53364E-03
  21  Prefactor     .10000E-03    28.687        .72006E-06** at limit **
  22  norm          22.961        19.823       -.75901E-07    .80349E-05
  23  norm          .10000E-03    44.902       -.12951E-06** at limit **
  24  Prefactor     .10000E-03    21.742       -.36303E-06** at limit **
  25  Prefactor     .10021E-03    3.6101       -.30712E-05** at limit **
  26  Prefactor     45.567        34.749        .97269E-06    .18804E-03
  27  Prefactor     .10000E-03    41.048        .10770E-05** at limit **
  28  Prefactor     1.0317        33.324        .48898E-05   -.80178E-04
  29  Normalizat    .97924        .21306        .23858E-06    .37687E-03
  30  Prefactor     .90855        .14372        .78264E-06    .28521E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 0.0001
  Prefactor  = 10.2323
  norm       = 24.7452
  Prefactor  = 0.0001
  Prefactor  = 8.70271
  Prefactor  = 0.0001
  Prefactor  = 3.91122
  norm       = 0.0001
  norm       = 0.282433
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.000100003
  Prefactor  = 383.807
  Prefactor  = 1.62414
  Prefactor  = 0.0001
  norm       = 22.9611
  norm       = 0.000100002
  Prefactor  = 0.0001
  Prefactor  = 0.000100208
  Prefactor  = 45.5673
  Prefactor  = 0.0001
  Prefactor  = 1.03172
  Normalizat = 0.979235
  Prefactor  = 0.908553
 **********
 **   18 **HESSE 
 **********

 FCN=   4939.128     FROM HESSE     STATUS=OK           582 CALLS     4523 TOTAL
                     EDM=   .11E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    8.5331        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     .10000E-03    25.395        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10000E-03    13.280        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    3.0028        .11859E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  norm          .10000E-03    .85006        .63089E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  norm          .10000E-03    1.5256        .84616E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     10.232        14.433        .62660E-03   -1.5068    
   8  norm          24.745        15.832        .80524E-04   -1.4713    
   9  Prefactor     .10000E-03    49.847        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     8.7027        11.607        .13591E-03   -1.5118    
  11  Prefactor     .10000E-03    5.3331        .15846E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     3.9112        8.9345        .20408E-03   -1.5312    
  13  norm          .10000E-03    .45305        .83107E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          .28243        18.595        .25032E-02   -1.5602    
  15  Prefactor     .10000E-03    3.4098        .12661E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     .10000E-03    24.192        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          .10000E-03    3.3011        .12384E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .10000E-03    18.185        .25844E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     383.81        291.37        .10406E-03   -1.1764    
  20  Prefactor     1.6241        29.533        .33730E-03   -1.5453    
  21  Prefactor     .10000E-03    28.936        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  norm          22.961        19.787        .83594E-04   -1.4749    
  23  norm          .10000E-03    45.088        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     .10000E-03    21.726        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     .10021E-03    27.620        .21321E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  Prefactor     45.567        34.492        .29710E-03   -1.4357    
  27  Prefactor     .10000E-03    41.259        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  Prefactor     1.0317        33.768        .49800E-03   -1.5505    
  29  Normalizat    .97924        .24493        .27031E-03   -.93729    
  30  Prefactor     .90855        .16773        .19712E-03   -.95843    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.09262e-08
Minuit parameter uncertainties:
  1  6.29566e-06
  2  2.38236e-05
  3  1.06504e-05
  4  1.88605e-06
  5  1.91132e-06
  6  2.02251e-06
  7  14.438
  8  15.8347
  9  0.000275761
  10  11.6095
  11  3.3302e-06
  12  8.9375
  13  1.65581e-05
  14  4.58412
  15  4.92212e-06
  16  6.89194e-05
  17  4.53194e-06
  18  0.000447012
  19  292.498
  20  13.859
  21  3.89502e-05
  22  19.793
  23  0.000581899
  24  0.000114357
  25  0.00479951
  26  34.5071
  27  0.000112676
  28  11.8116
  29  0.245212
  30  0.167822
Done.

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

Extracting fit parameters...

4FGL J2339.6+0242
   Spectrum: PowerLaw
463    Prefactor:  4.557e+01  3.451e+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.086e-01  1.678e-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:  9.792e-01  2.452e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 4.07
Ra Dec: 354.904 2.710
Photon Index (Fixed Index): 2.55 +/- 0.00
Photon Flux (Fixed Index): 5.52e-08 +/- 4.17e-08
Energy Flux (Fixed Index): 1.52e-05 +/- 1.15e-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) = 4938.92383195
delta logL = 0.204587654711

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 4938.90484942
delta logL = 0.223570176556

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    55.723       1.0000         .10000E-03   10000.    
     2 'Index     '    2.1088       1.0000          .0000       10.000    
     3 'Normalizat'    .99989       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .89981       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=   4938.905     FROM MIGRAD    STATUS=CONVERGED     79 CALLS      262 TOTAL
                     EDM=   .10E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     55.725        43.175        .26869E-03   -.34559E-03
   2  Index         2.1089        .62206        .81746E-02   -.16626E-03
   3  Normalizat    .99981        .23579        .26781E-03    .97850E-04
   4  Prefactor     .89987        .16608        .19793E-03    .13074E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 55.7246
  Index      = 2.10891
  Normalizat = 0.999807
  Prefactor  = 0.899873
 **********
 **   18 **HESSE 
 **********

 FCN=   4938.905     FROM HESSE     STATUS=OK            23 CALLS      285 TOTAL
                     EDM=   .10E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     55.725        43.083        .53737E-04   -1.4214    
   2  Index         2.1089        .62055        .32698E-03   -.61654    
   3  Normalizat    .99981        .23593        .10712E-04   -.93037    
   4  Prefactor     .89987        .16620        .39587E-04   -.96146    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.04382e-09
Minuit parameter uncertainties:
  1  43.107
  2  0.622965
  3  0.236175
  4  0.16629
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/74557': 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) = 4938.90484934
delta logL = 0.223570261588

Extracting fit parameters...

4FGL J2339.6+0242
   Spectrum: PowerLaw
463    Prefactor:  5.572e+01  4.311e+01  1.000e-04  1.000e+04 ( 1.000e-13)
464        Index:  2.109e+00  6.230e-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:  8.999e-01  1.663e-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:  9.998e-01  2.362e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 4.52
Ra Dec: 354.904 2.710
Photon Index (Free Index): 2.11 +/- 0.62
Photon Flux (Free Index): 3.81e-08 +/- 3.89e-08
Energy Flux (Free Index): 2.05e-05 +/- 2.08e-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/74557/cmap_HighResolution_494899201_495158401_4FGL_J2339.6+0242_daily_bin986.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET comment='SUCCESS', photon_flux='5.52e-08', energy_flux2='2.05e-05', photon_flux_error='4.17e-08', dlogl='2.24e-01', energy_flux='1.52e-05', photon_flux2='3.81e-08', job_status='DONE', time_completed='2021-09-30 03:00:48.429566', photon_index_error2='0.62', photon_index2='2.11', ts='4.07', fit_tolerance='1e-08', GAL='0.91', photon_index_error='0.00', energy_flux_error2='2.08e-05', EG='0.98', time_epoch_completed='1632996048.43', return_code='0', job_id='74557', GAL2='0.90', EG2='1.00', return_code2='0', energy_flux_error='1.15e-05', photon_flux_error2='3.89e-08', ts2='4.52', photon_index='2.55' WHERE bin_id='986' AND source_name='4FGL J2339.6+0242' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Sep 30 03:00:48 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0041>
Subject: Job 74557: <4FGL_J2339.6+0242_daily_bin986> in cluster <slac> Done

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

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J2339.6+0242_daily_bin986 354.904 2.7102 494899201 495158401 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 :                                   629.00 sec.
    Max Memory :                                 1012 MB
    Average Memory :                             234.77 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   931 sec.
    Turnaround time :                            933 sec.

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

