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


Performing analysis on: 4FGL_J2359.0+3922_daily_bin494
RA = 359.755, Dec = 39.3669
tmin = 367372801, tmax = 367632001
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='236010', job_status='RUN', time_executed='2021-09-30 11:40:52.214078', time_epoch_executed='1633027252.21' WHERE source_name='4FGL J2359.0+3922' and cadence='daily' and bin_id='494'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/236010

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/236010/ft1_4FGL_J2359.0+3922_daily_bin494.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/236010/ft2_4FGL_J2359.0+3922_daily_bin494.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/236010/ft1_4FGL_J2359.0+3922_daily_bin494.fits outfile=/scratch/kocevski/236010/ft1_filteredMKT_4FGL_J2359.0+3922_daily_bin494.fits ra=359.755 dec=39.3669 rad=12.0 tmin=367372801.0 tmax=367632001.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.40
user 3.19
sys 0.20

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/236010/ft2_4FGL_J2359.0+3922_daily_bin494.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/236010/ft2_4FGL_J2359.0+3922_daily_bin494.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/236010/ft1_filteredMKT_4FGL_J2359.0+3922_daily_bin494.fits evtable="EVENTS" outfile="/scratch/kocevski/236010/ft1_filtered_4FGL_J2359.0+3922_daily_bin494.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.15

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/236010/ft1_filtered_4FGL_J2359.0+3922_daily_bin494.fits" evtable="EVENTS" scfile=/scratch/kocevski/236010/ft2_4FGL_J2359.0+3922_daily_bin494.fits sctable="SC_DATA" outfile=/scratch/kocevski/236010/ltcube_367372801_367632001_4FGL_J2359.0+3922_daily_bin494.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/236010/ft2_4FGL_J2359.0+3922_daily_bin494.fits
.....................!
real 11.84
user 11.47
sys 0.34

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/236010/ft1_filtered_4FGL_J2359.0+3922_daily_bin494.fits evtable="EVENTS" scfile=/scratch/kocevski/236010/ft2_4FGL_J2359.0+3922_daily_bin494.fits sctable="SC_DATA" expcube=/scratch/kocevski/236010/ltcube_367372801_367632001_4FGL_J2359.0+3922_daily_bin494.fits outfile=/scratch/kocevski/236010/expmap_367372801_367632001_4FGL_J2359.0+3922_daily_bin494.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/236010/ltcube_367372801_367632001_4FGL_J2359.0+3922_daily_bin494.fits
.....................!
real 190.47
user 185.12
sys 5.02

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 FHES J2304.0+5406 in ROI with RadialGaussian spatial model.
Extended source CTB 109 in ROI with RadialDisk spatial model.
Added 160 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 J2359.0+3922 @ 359.755 39.3669

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/236010/ft1_filtered_4FGL_J2359.0+3922_daily_bin494.fits scfile=/scratch/kocevski/236010/ft2_4FGL_J2359.0+3922_daily_bin494.fits outfile=/scratch/kocevski/236010/cmap_367372801_367632001_4FGL_J2359.0+3922_daily_bin494.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=359.755 yref=39.3669 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.36
sys 0.16

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/236010/ft1_filtered_4FGL_J2359.0+3922_daily_bin494.fits scfile=/scratch/kocevski/236010/ft2_4FGL_J2359.0+3922_daily_bin494.fits outfile=/scratch/kocevski/236010/cmap_HighResolution_367372801_367632001_4FGL_J2359.0+3922_daily_bin494.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=359.755 yref=39.3669 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.38
sys 0.16

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/236010/ft1_filtered_4FGL_J2359.0+3922_daily_bin494.fits evtable="EVENTS" scfile=/scratch/kocevski/236010/ft2_4FGL_J2359.0+3922_daily_bin494.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/236010/Model_4FGL_J2359.0+3922_daily_bin494.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 CTB 109
adding source EG_v02
adding source FHES J2304.0+5406
adding source GAL_V02
Working on...
/scratch/kocevski/236010/ft1_filtered_4FGL_J2359.0+3922_daily_bin494.fits.....................!
real 91.34
user 90.00
sys 1.17

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/236010/ft1_filtered_4FGL_J2359.0+3922_daily_bin494.fits', '/scratch/kocevski/236010/ft2_4FGL_J2359.0+3922_daily_bin494.fits', expMap='/scratch/kocevski/236010/expmap_367372801_367632001_4FGL_J2359.0+3922_daily_bin494.fits', expCube='/scratch/kocevski/236010/ltcube_367372801_367632001_4FGL_J2359.0+3922_daily_bin494.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/236010/Model_4FGL_J2359.0+3922_daily_bin494.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J2359.0+3922'

4FGL J2359.0+3922
   Spectrum: PowerLaw
518    Prefactor:  1.197e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
519        Index:  2.348e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
520        Scale:  1.622e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/236010/ft1_filtered_4FGL_J2359.0+3922_daily_bin494.fits
Spacecraft file(s): /scratch/kocevski/236010/ft2_4FGL_J2359.0+3922_daily_bin494.fits
Exposure map: /scratch/kocevski/236010/expmap_367372801_367632001_4FGL_J2359.0+3922_daily_bin494.fits
Exposure cube: /scratch/kocevski/236010/ltcube_367372801_367632001_4FGL_J2359.0+3922_daily_bin494.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/236010/Model_4FGL_J2359.0+3922_daily_bin494.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) = 8559.7655706

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10059E-03   1.0000         .10000E-03   10000.    
     3 'norm      '    .10004E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     5 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    7.7580       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .21638       1.0000         .10000E-03   10000.    
     8 'Prefactor '    5.9308       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    11 'norm      '    2.2738       1.0000         .10000E-03   10000.    
    12 'Prefactor '    3.6121       1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    .10007E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    6.6708       1.0000         .10000E-03   10000.    
    16 'norm      '    .10041E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10819E-03   1.0000         .10000E-03   10000.    
    19 'norm      '    4.4106       1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    .12231E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    12.111       1.0000         .10000E-03   10000.    
    23 'Prefactor '    73.879       1.0000         .10000E-03   10000.    
    24 'Prefactor '    3.4365       1.0000         .10000E-03   10000.    
    25 'Normalizat'    1.1303       1.0000         .10000E-01   10.000    
    26 'Prefactor '    .82535       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5320E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   8559.754     FROM MIGRAD    STATUS=CONVERGED    630 CALLS     3809 TOTAL
                     EDM=   .21E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.8%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    13.977        .31778E-05** at limit **
   2  Prefactor     .10000E-03    24.444       -.12259E-05** at limit **
   3  norm          .10000E-03    7.4232        .27932E-06** at limit **
   4  Prefactor     .10000E-03    2.4319       -.22976E-06** at limit **
   5  norm          .10000E-03    1.5842        .15728E-07** at limit **
   6  Prefactor     7.7584        5.9412        .14407E-05   -.29887E-03
   7  Prefactor     .21642        1.8946        .20553E-05   -.25532E-03
   8  Prefactor     5.9314        7.4984       -.11449E-06   -.56478E-04
   9  Prefactor     .10000E-03    8.9784        .23423E-06** at limit **
  10  Prefactor     .10000E-03    13.468       -.66274E-06** at limit **
  11  norm          2.2740        2.3778        .19196E-06   -.53104E-04
  12  Prefactor     3.6123        3.6414        .27263E-06    .50886E-04
  13  Prefactor     .10000E-03    13.167       -.22246E-05** at limit **
  14  norm          .10000E-03    .55520        .56950E-07** at limit **
  15  Prefactor     6.6695        11.287        .44817E-06   -.14925E-04
  16  norm          .10000E-03    3.6493        .18663E-06** at limit **
  17  norm          .10000E-03    2.6261        .28471E-08** at limit **
  18  Prefactor     .10000E-03    44.284        .20405E-05** at limit **
  19  norm          4.4109        2.3039        .12295E-07   -.16349E-04
  20  Prefactor     .10000E-03    3.7450       -.93491E-07** at limit **
  21  Prefactor     .10000E-03    91.593       -.15951E-05** at limit **
  22  Prefactor     12.111        25.268        .12642E-06   -.10787E-04
  23  Prefactor     73.940        86.808        .45200E-05    .10589E-03
  24  Prefactor     3.4291        11.875       -.44286E-06   -.12371E-03
  25  Normalizat    1.1303        .18031       -.14862E-05   -.74533E-04
  26  Prefactor     .82533        .79928E-01   -.12676E-06   -.22079E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 7.75838
  Prefactor  = 0.216419
  Prefactor  = 5.93139
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 2.27404
  Prefactor  = 3.61234
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 6.66951
  norm       = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  norm       = 4.4109
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 12.1111
  Prefactor  = 73.9396
  Prefactor  = 3.42911
  Normalizat = 1.13026
  Prefactor  = 0.825329
 **********
 **   18 **HESSE 
 **********

 FCN=   8559.754     FROM HESSE     STATUS=OK           452 CALLS     4261 TOTAL
                     EDM=   .47E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    14.131        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     .10000E-03    24.732        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm          .10000E-03    7.4322        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    2.4416        .14081E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  norm          .10000E-03    1.6559        .22728E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     7.7584        6.0183        .71983E-03   -1.5151    
   7  Prefactor     .21642        1.9720        .24893E-03   -1.5615    
   8  Prefactor     5.9314        7.4901        .16489E-03   -1.5221    
   9  Prefactor     .10000E-03    8.9905        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .10000E-03    13.488        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  norm          2.2740        2.3692        .14061E-03   -1.5406    
  12  Prefactor     3.6123        3.6463        .17243E-03   -1.5328    
  13  Prefactor     .10000E-03    13.233        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          .10000E-03    .85469        .13388E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     6.6695        11.280        .15536E-03   -1.5191    
  16  norm          .10000E-03    3.7641        .34502E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          .10000E-03    2.6281        .14642E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .10000E-03    46.086        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  norm          4.4109        2.3009        .97558E-04   -1.5288    
  20  Prefactor     .10000E-03    3.7456        .17486E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .10000E-03    92.768        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     12.111        25.319        .11511E-03   -1.5012    
  23  Prefactor     73.940        89.958        .46711E-04   -1.3986    
  24  Prefactor     3.4291        11.987        .21819E-03   -1.5338    
  25  Normalizat    1.1303        .20678        .30803E-03   -.88786    
  26  Prefactor     .82533        .92139E-01    .16492E-03   -.98801    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 4.69164e-10
Minuit parameter uncertainties:
  1  0.000109981
  2  2.1808e-05
  3  3.72052e-05
  4  1.30056e-06
  5  3.81053e-06
  6  6.01875
  7  1.30633
  8  7.4913
  9  9.0504e-06
  10  1.86429e-05
  11  2.36934
  12  3.64652
  13  6.38156e-05
  14  4.96962e-06
  15  11.284
  16  4.45497e-06
  17  7.00597e-07
  18  0.000165568
  19  2.30093
  20  1.76505e-06
  21  1.22229e-05
  22  25.3411
  23  90.124
  24  11.9954
  25  0.206931
  26  0.0921564
Done.

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

Extracting fit parameters...

4FGL J2359.0+3922
   Spectrum: PowerLaw
518    Prefactor:  3.429e+00  1.200e+01  1.000e-04  1.000e+04 ( 1.000e-13)
519        Index:  2.348e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
520        Scale:  1.622e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
529    Prefactor:  8.253e-01  9.216e-02  0.000e+00  1.000e+01 ( 1.000e+00)
530        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
531        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
524   Normalization:  1.130e+00  2.069e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.20
Ra Dec: 359.755 39.367
Photon Flux Upper Limit: 1.07e-07 ph cm-2 s-1
Energy Flux Upper Limit: 8.25e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/236010/likelihoodResults_367372801_367632001_4FGL_J2359.0+3922_daily_bin494.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) = 8559.13275167
delta logL = 0.621385524128

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 8559.12733314
delta logL = 0.626804058498

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .43998       1.0000         .10000E-03   10000.    
     2 'Index     '    3.8356       1.0000          .0000       10.000    
     3 'Normalizat'    1.0748       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .83892       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5320E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   8559.127     FROM MIGRAD    STATUS=CONVERGED     57 CALLS      315 TOTAL
                     EDM=   .62E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .43853        5.0423        .11023E-01    .19817E-02
   2  Index         3.8370        2.1155        .92467E-01    .25217E-03
   3  Normalizat    1.0749        .40400E-01    .71084E-01    .11670E-04
   4  Prefactor     .83891        .18872E-01    .44222E-01   -.68871E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.438527
  Index      = 3.83695
  Normalizat = 1.07487
  Prefactor  = 0.838907
 **********
 **   18 **HESSE 
 **********

 FCN=   8559.127     FROM HESSE     STATUS=NOT POSDEF    33 CALLS      348 TOTAL
                     EDM=   .13E-05    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .43853        16.126        .51995E-04   -1.5576    
   2  Index         3.8370        6.7990        .52097E-02   -.23476    
   3  Normalizat    1.0749        .17442        .31453E-03   -.90563    
   4  Prefactor     .83891        .79903E-01    .16362E-03   -.98310    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 1.2603e-06
Minuit parameter uncertainties:
  1  5.31953
  2  4.98724
  3  0.174514
  4  0.0799136
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/236010': 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): 102
logL (Free Index) = 8559.12733281
delta logL = 0.626804387352

Extracting fit parameters...

4FGL J2359.0+3922
   Spectrum: PowerLaw
518    Prefactor:  4.385e-01  5.320e+00  1.000e-04  1.000e+04 ( 1.000e-13)
519        Index:  3.837e+00  4.987e+00  0.000e+00  1.000e+01 (-1.000e+00)
520        Scale:  1.622e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
529    Prefactor:  8.389e-01  7.991e-02  0.000e+00  1.000e+01 ( 1.000e+00)
530        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
531        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
524   Normalization:  1.075e+00  1.745e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 1.54
Ra Dec: 359.755 39.367
Photon Index (Free Index): 3.84 +/- 4.99
Photon Flux (Free Index): 6.81e-08 +/- 5.84e-08
Energy Flux (Free Index): 1.05e-05 +/- 1.32e-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/236010/cmap_HighResolution_367372801_367632001_4FGL_J2359.0+3922_daily_bin494.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='8.25e-03', comment='SUCCESS', energy_flux2='1.05e-05', dlogl='6.27e-01', photon_flux2='6.81e-08', job_status='DONE', time_completed='2021-09-30 11:56:40.672608', photon_index_error2='4.99', photon_index2='3.84', ts='0.20', fit_tolerance='1e-08', GAL='0.83', photon_index_error='0.00', photon_flux_upper_limit='1.07e-07', energy_flux_error2='1.32e-05', EG='1.13', time_epoch_completed='1633028200.67', return_code='0', job_id='236010', GAL2='0.84', EG2='1.07', return_code2='102', photon_flux_error2='5.84e-08', ts2='1.54', photon_index='2.35' WHERE bin_id='494' AND source_name='4FGL J2359.0+3922' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Sep 30 11:56:40 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0236>
Subject: Job 236010: <4FGL_J2359.0+3922_daily_bin494> in cluster <slac> Done

Job <4FGL_J2359.0+3922_daily_bin494> was submitted from host <rhel6-64d> by user <kocevski> in cluster <slac> at Thu Sep 30 11:40:39 2021
Job was executed on host(s) <bullet0236>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Sep 30 11:40:41 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Thu Sep 30 11:40:41 2021
Terminated at Thu Sep 30 11:56:41 2021
Results reported at Thu Sep 30 11:56:41 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J2359.0+3922_daily_bin494 359.755 39.3669 367372801 367632001 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J2359.0+3922 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   939.01 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             359.68 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   959 sec.
    Turnaround time :                            962 sec.

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

