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


Performing analysis on: 4FGL_J2040.5-1705_daily_bin634
RA = 310.136, Dec = -17.0901
tmin = 403660801, tmax = 403920001
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='108653', job_status='RUN', time_executed='2021-09-25 15:51:44.484240', time_epoch_executed='1632610304.48' WHERE source_name='4FGL J2040.5-1705' and cadence='daily' and bin_id='634'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/108653

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/108653/ft1_4FGL_J2040.5-1705_daily_bin634.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/108653/ft2_4FGL_J2040.5-1705_daily_bin634.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/108653/ft1_4FGL_J2040.5-1705_daily_bin634.fits outfile=/scratch/kocevski/108653/ft1_filteredMKT_4FGL_J2040.5-1705_daily_bin634.fits ra=310.136 dec=-17.0901 rad=12.0 tmin=403660801.0 tmax=403920001.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 7.72
user 7.39
sys 0.27

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/108653/ft2_4FGL_J2040.5-1705_daily_bin634.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/108653/ft2_4FGL_J2040.5-1705_daily_bin634.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/108653/ft1_filteredMKT_4FGL_J2040.5-1705_daily_bin634.fits evtable="EVENTS" outfile="/scratch/kocevski/108653/ft1_filtered_4FGL_J2040.5-1705_daily_bin634.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.54
user 0.34
sys 0.16

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/108653/ft1_filtered_4FGL_J2040.5-1705_daily_bin634.fits" evtable="EVENTS" scfile=/scratch/kocevski/108653/ft2_4FGL_J2040.5-1705_daily_bin634.fits sctable="SC_DATA" outfile=/scratch/kocevski/108653/ltcube_403660801_403920001_4FGL_J2040.5-1705_daily_bin634.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/108653/ft2_4FGL_J2040.5-1705_daily_bin634.fits
.....................!
real 13.16
user 12.76
sys 0.31

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/108653/ft1_filtered_4FGL_J2040.5-1705_daily_bin634.fits evtable="EVENTS" scfile=/scratch/kocevski/108653/ft2_4FGL_J2040.5-1705_daily_bin634.fits sctable="SC_DATA" expcube=/scratch/kocevski/108653/ltcube_403660801_403920001_4FGL_J2040.5-1705_daily_bin634.fits outfile=/scratch/kocevski/108653/expmap_403660801_403920001_4FGL_J2040.5-1705_daily_bin634.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/108653/ltcube_403660801_403920001_4FGL_J2040.5-1705_daily_bin634.fits
.....................!
real 193.12
user 187.62
sys 4.74

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

Setting source of interest to:
4FGL J2040.5-1705 @ 310.136 -17.0901

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/108653/ft1_filtered_4FGL_J2040.5-1705_daily_bin634.fits scfile=/scratch/kocevski/108653/ft2_4FGL_J2040.5-1705_daily_bin634.fits outfile=/scratch/kocevski/108653/cmap_403660801_403920001_4FGL_J2040.5-1705_daily_bin634.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=310.136 yref=-17.0901 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.55
user 0.37
sys 0.17

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/108653/ft1_filtered_4FGL_J2040.5-1705_daily_bin634.fits scfile=/scratch/kocevski/108653/ft2_4FGL_J2040.5-1705_daily_bin634.fits outfile=/scratch/kocevski/108653/cmap_HighResolution_403660801_403920001_4FGL_J2040.5-1705_daily_bin634.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=310.136 yref=-17.0901 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.56
user 0.38
sys 0.17

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/108653/ft1_filtered_4FGL_J2040.5-1705_daily_bin634.fits evtable="EVENTS" scfile=/scratch/kocevski/108653/ft2_4FGL_J2040.5-1705_daily_bin634.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/108653/Model_4FGL_J2040.5-1705_daily_bin634.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/108653/ft1_filtered_4FGL_J2040.5-1705_daily_bin634.fits.....................!
real 52.62
user 51.28
sys 1.22

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/108653/ft1_filtered_4FGL_J2040.5-1705_daily_bin634.fits', '/scratch/kocevski/108653/ft2_4FGL_J2040.5-1705_daily_bin634.fits', expMap='/scratch/kocevski/108653/expmap_403660801_403920001_4FGL_J2040.5-1705_daily_bin634.fits', expCube='/scratch/kocevski/108653/ltcube_403660801_403920001_4FGL_J2040.5-1705_daily_bin634.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/108653/Model_4FGL_J2040.5-1705_daily_bin634.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J2040.5-1705'

4FGL J2040.5-1705
   Spectrum: PowerLaw
323    Prefactor:  1.223e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-12)
324        Index:  2.541e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
325        Scale:  7.724e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/108653/ft1_filtered_4FGL_J2040.5-1705_daily_bin634.fits
Spacecraft file(s): /scratch/kocevski/108653/ft2_4FGL_J2040.5-1705_daily_bin634.fits
Exposure map: /scratch/kocevski/108653/expmap_403660801_403920001_4FGL_J2040.5-1705_daily_bin634.fits
Exposure cube: /scratch/kocevski/108653/ltcube_403660801_403920001_4FGL_J2040.5-1705_daily_bin634.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/108653/Model_4FGL_J2040.5-1705_daily_bin634.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) = 4920.33775478

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10019E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    3.2472       1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10053E-03   1.0000         .10000E-03   10000.    
     5 'norm      '    42.280       1.0000         .10000E-03   10000.    
     6 'norm      '    9.8703       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .92898E-02   1.0000         .10000E-03   10000.    
     8 'norm      '    .10115E-03   1.0000         .10000E-03   10000.    
     9 'norm      '    .10006E-03   1.0000         .10000E-03   10000.    
    10 'norm      '    2.3847       1.0000         .10000E-03   10000.    
    11 'Prefactor '    22.093       1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10007E-03   1.0000         .10000E-03   10000.    
    13 'norm      '    .10988E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10232E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    .10025E-03   1.0000         .10000E-03   10000.    
    17 'Prefactor '    .40301       1.0000         .10000E-03   10000.    
    18 'Prefactor '    17.657       1.0000         .10000E-03   10000.    
    19 'Prefactor '    .12249E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    1.3069       1.0000         .10000E-03   10000.    
    21 'Normalizat'    1.6086       1.0000         .10000E-01   10.000    
    22 'Prefactor '    .77440       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5990E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   4920.296     FROM MIGRAD    STATUS=CONVERGED    502 CALLS     2394 TOTAL
                     EDM=   .80E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  7.9%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    27.603        .10935E-05** at limit **
   2  Prefactor     3.2740        149.95       -.17413E-05   -.13973E-04
   3  Prefactor     .10000E-03    1.1969       -.10861E-06** at limit **
   4  Prefactor     .10000E-03    10.957       -.15475E-06** at limit **
   5  norm          42.258        24.593       -.43474E-06   -.20223E-04
   6  norm          9.8516        15.043       -.78071E-06   -.18100E-03
   7  Prefactor     .10007E-03    1730.0        .97328E-04** at limit **
   8  norm          .10000E-03    5.7426       -.41041E-07** at limit **
   9  norm          .10000E-03    44.569        .25482E-06** at limit **
  10  norm          2.3846        1.6292        .48800E-08   -.33207E-04
  11  Prefactor     22.093        23.955        .11463E-06   -.15785E-04
  12  Prefactor     .10000E-03    4.7550       -.10245E-06** at limit **
  13  norm          .10000E-03    4.3964       -.67622E-06** at limit **
  14  Prefactor     .10000E-03    6.5695       -.43987E-06** at limit **
  15  Prefactor     .10000E-03    28.732       -.15073E-05** at limit **
  16  norm          .10000E-03    9.9439       -.70566E-07** at limit **
  17  Prefactor     .28513        27.888        .39735E-05   -.34908E-03
  18  Prefactor     17.649        11.832        .54024E-07    .64885E-05
  19  Prefactor     .10000E-03    51.241        .36523E-05** at limit **
  20  Prefactor     1.3012        66.839        .13521E-04    .43781E-04
  21  Normalizat    1.6092        .33112       -.11170E-05   -.12192E-03
  22  Prefactor     .77446        .13152        .65240E-06   -.25791E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 3.274
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 42.2578
  norm       = 9.85163
  Prefactor  = 0.000100068
  norm       = 0.0001
  norm       = 0.0001
  norm       = 2.38459
  Prefactor  = 22.0931
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.285129
  Prefactor  = 17.6493
  Prefactor  = 0.0001
  Prefactor  = 1.30119
  Normalizat = 1.60918
  Prefactor  = 0.774461
 **********
 **   18 **HESSE 
 **********

 FCN=   4920.296     FROM HESSE     STATUS=OK           346 CALLS     2740 TOTAL
                     EDM=   .76E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    27.622        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     3.2740        150.82        .22476E-03   -1.5346    
   3  Prefactor     .10000E-03    1.2177        .74864E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    10.981        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  norm          42.258        24.625        .61651E-04   -1.4407    
   6  norm          9.8516        15.127        .63773E-03   -1.5080    
   7  Prefactor     .10007E-03    1729.0        .18211E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          .10000E-03    5.7465        .16418E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  norm          .10000E-03    45.042        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  norm          2.3846        1.6253        .67821E-04   -1.5399    
  11  Prefactor     22.093        23.896        .85216E-04   -1.4768    
  12  Prefactor     .10000E-03    4.7667        .14939E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  norm          .10000E-03    10.418        .28230E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     .10000E-03    6.8203        .35091E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .10000E-03    28.741        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          .10000E-03    9.9451        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  Prefactor     .28513        33.664        .89351E-01   -1.5601    
  18  Prefactor     17.649        11.874        .95316E-04   -1.4867    
  19  Prefactor     .10000E-03    52.041        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     1.3012        66.956        .19300E-02   -1.5480    
  21  Normalizat    1.6092        .40807        .33687E-03   -.74755    
  22  Prefactor     .77446        .16199        .18678E-03   -1.0068    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 7.56974e-10
Minuit parameter uncertainties:
  1  3.34271e-05
  2  44.5623
  3  1.56428e-06
  4  9.10702e-08
  5  24.6305
  6  15.1326
  7  0.0223729
  8  2.35639e-06
  9  3.8852e-05
  10  1.62534
  11  23.9067
  12  4.41813e-06
  13  0.000122324
  14  2.0842e-05
  15  6.29719e-05
  16  3.09525e-06
  17  6.19883
  18  11.8761
  19  4.3016e-05
  20  18.6892
  21  0.408914
  22  0.162086
Done.

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

Extracting fit parameters...

4FGL J2040.5-1705
   Spectrum: PowerLaw
323    Prefactor:  1.000e-04  2.084e-05  1.000e-04  1.000e+04 ( 1.000e-12)
324        Index:  2.541e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
325        Scale:  7.724e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
596    Prefactor:  7.745e-01  1.621e-01  0.000e+00  1.000e+01 ( 1.000e+00)
597        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
598        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
595   Normalization:  1.609e+00  4.089e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 310.136 -17.090
Photon Flux Upper Limit: 1.49e-07 ph cm-2 s-1
Energy Flux Upper Limit: 1.16e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/108653/likelihoodResults_403660801_403920001_4FGL_J2040.5-1705_daily_bin634.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): 102
logL (Free Index) = 4920.29686221
delta logL = -0.000699942251231

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 4920.2961631
delta logL = -8.32974365039e-07

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10283E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.5569       1.0000          .0000       10.000    
     3 'Normalizat'    1.6087       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .77464       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5990E+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=   4920.296     FROM MIGRAD    STATUS=CONVERGED     88 CALLS      246 TOTAL
                     EDM=   .11E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10150E-03    43.721        .35366E-02** at limit **
   2  Index         2.6288        6.2971        .50000       -.16286E-04
   3  Normalizat    1.6092        .20049E-01    .33687E-03    .11633E-03
   4  Prefactor     .77446        .81176E-02    .18679E-03    .16161E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001015
  Index      = 2.62883
  Normalizat = 1.60918
  Prefactor  = 0.774462
 **********
 **   18 **HESSE 
 **********

 FCN=   4920.296     FROM HESSE     STATUS=NOT POSDEF    29 CALLS      275 TOTAL
                     EDM=   .69E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10150E-03    264.51        .70733E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.6288        5.4220        .50000       -.49409    
   3  Normalizat    1.6092        .51060E-01    .67373E-04   -.74755    
   4  Prefactor     .77446        .20673E-01    .37357E-04   -1.0068    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 6.8662e-08
Minuit parameter uncertainties:
  1  0.0400201
  2  690.655
  3  0.0510612
  4  0.0206735
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/108653': 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) = 4920.29616201
delta logL = 2.62994035438e-07

Extracting fit parameters...

4FGL J2040.5-1705
   Spectrum: PowerLaw
323    Prefactor:  1.015e-04  4.002e-02  1.000e-04  1.000e+04 ( 1.000e-12)
324        Index:  2.629e+00  6.907e+02  0.000e+00  1.000e+01 (-1.000e+00)
325        Scale:  7.724e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
596    Prefactor:  7.745e-01  2.067e-02  0.000e+00  1.000e+01 ( 1.000e+00)
597        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
598        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
595   Normalization:  1.609e+00  5.106e-02  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 310.136 -17.090

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/108653/cmap_HighResolution_403660801_403920001_4FGL_J2040.5-1705_daily_bin634.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='1.16e-02', job_status='DONE', photon_flux_upper_limit='1.49e-07', time_completed='2021-09-25 16:01:57.457336', job_id='108653', GAL2='0.77', fit_tolerance='1e-08', EG2='1.61', EG='1.61', time_epoch_completed='1632610917.46', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.77', dlogl='2.63e-07', ts2='-0.00', photon_index_error='0.00', photon_index='2.54' WHERE bin_id='634' AND source_name='4FGL J2040.5-1705' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sat Sep 25 16:01:57 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0021>
Subject: Job 108653: <4FGL_J2040.5-1705_daily_bin634> in cluster <slac> Done

Job <4FGL_J2040.5-1705_daily_bin634> was submitted from host <rhel6-64f> by user <kocevski> in cluster <slac> at Sat Sep 25 15:45:29 2021
Job was executed on host(s) <bullet0021>, in queue <medium>, as user <kocevski> in cluster <slac> at Sat Sep 25 15:48:25 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sat Sep 25 15:48:25 2021
Terminated at Sat Sep 25 16:01:58 2021
Results reported at Sat Sep 25 16:01:58 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J2040.5-1705_daily_bin634 310.136 -17.0901 403660801 403920001 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J2040.5-1705 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   611.40 sec.
    Max Memory :                                 1094 MB
    Average Memory :                             252.46 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   812 sec.
    Turnaround time :                            989 sec.

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

