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


Performing analysis on: 4FGL_J1040.5+0617_daily_bin1072
RA = 160.15, Dec = 6.2848
tmin = 517190401, tmax = 517449601
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='67985', job_status='RUN', time_executed='2021-09-02 08:35:58.835338', time_epoch_executed='1630596958.84' WHERE source_name='4FGL J1040.5+0617' and cadence='daily' and bin_id='1072'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/67985

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/67985/ft1_4FGL_J1040.5+0617_daily_bin1072.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/67985/ft2_4FGL_J1040.5+0617_daily_bin1072.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/67985/ft1_4FGL_J1040.5+0617_daily_bin1072.fits outfile=/scratch/kocevski/67985/ft1_filteredMKT_4FGL_J1040.5+0617_daily_bin1072.fits ra=160.15 dec=6.2848 rad=12.0 tmin=517190401.0 tmax=517449601.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 4.67
user 4.39
sys 0.23

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/67985/ft2_4FGL_J1040.5+0617_daily_bin1072.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/67985/ft2_4FGL_J1040.5+0617_daily_bin1072.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/67985/ft1_filteredMKT_4FGL_J1040.5+0617_daily_bin1072.fits evtable="EVENTS" outfile="/scratch/kocevski/67985/ft1_filtered_4FGL_J1040.5+0617_daily_bin1072.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.59
user 0.35
sys 0.15

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/67985/ft1_filtered_4FGL_J1040.5+0617_daily_bin1072.fits" evtable="EVENTS" scfile=/scratch/kocevski/67985/ft2_4FGL_J1040.5+0617_daily_bin1072.fits sctable="SC_DATA" outfile=/scratch/kocevski/67985/ltcube_517190401_517449601_4FGL_J1040.5+0617_daily_bin1072.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/67985/ft2_4FGL_J1040.5+0617_daily_bin1072.fits
.....................!
real 15.23
user 14.86
sys 0.31

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/67985/ft1_filtered_4FGL_J1040.5+0617_daily_bin1072.fits evtable="EVENTS" scfile=/scratch/kocevski/67985/ft2_4FGL_J1040.5+0617_daily_bin1072.fits sctable="SC_DATA" expcube=/scratch/kocevski/67985/ltcube_517190401_517449601_4FGL_J1040.5+0617_daily_bin1072.fits outfile=/scratch/kocevski/67985/expmap_517190401_517449601_4FGL_J1040.5+0617_daily_bin1072.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/67985/ltcube_517190401_517449601_4FGL_J1040.5+0617_daily_bin1072.fits
.....................!
real 189.99
user 185.30
sys 4.29

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

Setting source of interest to:
4FGL J1040.5+0617 @ 160.15 6.2848

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/67985/ft1_filtered_4FGL_J1040.5+0617_daily_bin1072.fits scfile=/scratch/kocevski/67985/ft2_4FGL_J1040.5+0617_daily_bin1072.fits outfile=/scratch/kocevski/67985/cmap_517190401_517449601_4FGL_J1040.5+0617_daily_bin1072.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=160.15 yref=6.2848 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.39
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/67985/ft1_filtered_4FGL_J1040.5+0617_daily_bin1072.fits scfile=/scratch/kocevski/67985/ft2_4FGL_J1040.5+0617_daily_bin1072.fits outfile=/scratch/kocevski/67985/cmap_HighResolution_517190401_517449601_4FGL_J1040.5+0617_daily_bin1072.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=160.15 yref=6.2848 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.40
sys 0.15

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/67985/ft1_filtered_4FGL_J1040.5+0617_daily_bin1072.fits evtable="EVENTS" scfile=/scratch/kocevski/67985/ft2_4FGL_J1040.5+0617_daily_bin1072.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/67985/Model_4FGL_J1040.5+0617_daily_bin1072.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/67985/ft1_filtered_4FGL_J1040.5+0617_daily_bin1072.fits....................!
real 49.85
user 48.46
sys 1.28

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/67985/ft1_filtered_4FGL_J1040.5+0617_daily_bin1072.fits', '/scratch/kocevski/67985/ft2_4FGL_J1040.5+0617_daily_bin1072.fits', expMap='/scratch/kocevski/67985/expmap_517190401_517449601_4FGL_J1040.5+0617_daily_bin1072.fits', expCube='/scratch/kocevski/67985/ltcube_517190401_517449601_4FGL_J1040.5+0617_daily_bin1072.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/67985/Model_4FGL_J1040.5+0617_daily_bin1072.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1040.5+0617'

4FGL J1040.5+0617
   Spectrum: PowerLaw
216    Prefactor:  2.877e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-12)
217        Index:  2.368e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
218        Scale:  8.643e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/67985/ft1_filtered_4FGL_J1040.5+0617_daily_bin1072.fits
Spacecraft file(s): /scratch/kocevski/67985/ft2_4FGL_J1040.5+0617_daily_bin1072.fits
Exposure map: /scratch/kocevski/67985/expmap_517190401_517449601_4FGL_J1040.5+0617_daily_bin1072.fits
Exposure cube: /scratch/kocevski/67985/ltcube_517190401_517449601_4FGL_J1040.5+0617_daily_bin1072.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/67985/Model_4FGL_J1040.5+0617_daily_bin1072.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) = 4828.68397298

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    5.9666       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10086E-03   1.0000         .10000E-03   10000.    
     3 'norm      '    21.682       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10166E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .72383E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10142E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10024E-03   1.0000         .10000E-03   10000.    
     8 'norm      '    2.2700       1.0000         .10000E-03   10000.    
     9 'Prefactor '    7.5116       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .51512E-01   1.0000         .10000E-03   10000.    
    11 'Prefactor '    1.9677       1.0000         .10000E-03   10000.    
    12 'Prefactor '    2.2713       1.0000         .10000E-03   10000.    
    13 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    .26421E-02   1.0000         .10000E-03   10000.    
    15 'norm      '    .10003E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    86.435       1.0000         .10000E-03   10000.    
    17 'norm      '    9.7075       1.0000         .10000E-03   10000.    
    18 'Normalizat'    1.0191       1.0000         .10000E-01   10.000    
    19 'Prefactor '    .97331       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5360E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   4828.652     FROM MIGRAD    STATUS=CONVERGED    390 CALLS     1674 TOTAL
                     EDM=   .16E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.1%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     5.9324        19.829       -.87409E-05    .21073E-03
   2  Prefactor     .10000E-03    66.820        .14461E-04** at limit **
   3  norm          21.685        21.252        .96651E-05    .65122E-03
   4  Prefactor     .10000E-03    4.2525       -.13277E-06** at limit **
   5  Prefactor     .10001E-03    190.19       -.12994E-03** at limit **
   6  Prefactor     .10000E-03    21.449       -.16778E-05** at limit **
   7  Prefactor     .10000E-03    6.7406       -.47250E-06** at limit **
   8  norm          2.2697        1.6515       -.24021E-06   -.67544E-04
   9  Prefactor     7.5095        8.2339        .36690E-05   -.10123E-03
  10  Prefactor     .62232E-01    2.3286        .39014E-06    .35977E-03
  11  Prefactor     1.9653        7.2580       -.53180E-05   -.49509E-03
  12  Prefactor     2.2742        12.143       -.81546E-05   -.31885E-03
  13  norm          .10000E-03    .20963        .50365E-07** at limit **
  14  Prefactor     .10011E-03    6.4406       -.33157E-06** at limit **
  15  norm          .10000E-03    .58784        .12794E-06** at limit **
  16  Prefactor     86.444        36.482        .46769E-05    .58343E-04
  17  norm          9.7052        13.398       -.12394E-07   -.36503E-04
  18  Normalizat    1.0191        .21985        .21958E-06    .41235E-03
  19  Prefactor     .97339        .17492        .11723E-06    .38460E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 5.93244
  Prefactor  = 0.0001
  norm       = 21.685
  Prefactor  = 0.0001
  Prefactor  = 0.000100009
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 2.26974
  Prefactor  = 7.50947
  Prefactor  = 0.0622317
  Prefactor  = 1.96532
  Prefactor  = 2.2742
  norm       = 0.0001
  Prefactor  = 0.00010011
  norm       = 0.0001
  Prefactor  = 86.4442
  norm       = 9.70524
  Normalizat = 1.0191
  Prefactor  = 0.973394
 **********
 **   18 **HESSE 
 **********

 FCN=   4828.652     FROM HESSE     STATUS=OK           270 CALLS     1944 TOTAL
                     EDM=   .89E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     5.9324        19.696        .16439E-03   -1.5221    
   2  Prefactor     .10000E-03    66.907        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm          21.685        21.351        .86020E-04   -1.4776    
   4  Prefactor     .10000E-03    4.2565        .13992E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10001E-03    188.83        .41921E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    21.455        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10000E-03    6.7449        .17620E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          2.2697        1.6479        .72676E-04   -1.5407    
   9  Prefactor     7.5095        8.1996        .14633E-03   -1.5160    
  10  Prefactor     .62232E-01    63.311        .19003E-02   -1.5658    
  11  Prefactor     1.9653        7.3059        .29563E-03   -1.5428    
  12  Prefactor     2.2742        12.128        .27250E-03   -1.5406    
  13  norm          .10000E-03    .22908        .60864E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     .10011E-03    43.840        .33201E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  norm          .10000E-03    .60159        .10391E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     86.444        36.499        .43212E-04   -1.3846    
  17  norm          9.7052        13.397        .12862E-03   -1.5085    
  18  Normalizat    1.0191        .25266        .26593E-03   -.92393    
  19  Prefactor     .97339        .20094        .23052E-03   -.93622    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 8.93545e-09
Minuit parameter uncertainties:
  1  19.7177
  2  0.000133526
  3  21.3585
  4  3.39072e-06
  5  0.0026107
  6  8.85807e-06
  7  1.91222e-06
  8  1.64794
  9  8.20086
  10  3.97087
  11  7.30925
  12  10.5068
  13  3.85536e-06
  14  0.00438823
  15  6.82437e-07
  16  36.508
  17  13.4015
  18  0.252957
  19  0.201094
Done.

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

Extracting fit parameters...

4FGL J1040.5+0617
   Spectrum: PowerLaw
216    Prefactor:  6.223e-02  3.971e+00  1.000e-04  1.000e+04 ( 1.000e-12)
217        Index:  2.368e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
218        Scale:  8.643e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
533    Prefactor:  9.734e-01  2.011e-01  0.000e+00  1.000e+01 ( 1.000e+00)
534        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
535        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
532   Normalization:  1.019e+00  2.530e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.00
Ra Dec: 160.150 6.285
Photon Flux Upper Limit: 1.16e-07 ph cm-2 s-1
Energy Flux Upper Limit: 8.95e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/67985/likelihoodResults_517190401_517449601_4FGL_J1040.5+0617_daily_bin1072.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) = 4828.39170694
delta logL = 0.260658563153

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 4828.38457942
delta logL = 0.267786082508

Fit tolerance = 1e-08

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

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

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   4828.385     FROM MIGRAD    STATUS=CONVERGED     51 CALLS      235 TOTAL
                     EDM=   .66E-10    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .67287        20.342        .11957E-01    .10437E-02
   2  Index         3.5062        3.8717        .14799        .92255E-04
   3  Normalizat    .96728        .44908E-01    .45756E-01    .10680E-04
   4  Prefactor     .99449        .38462E-01    .46198E-01    .50602E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.672868
  Index      = 3.50616
  Normalizat = 0.967276
  Prefactor  = 0.994488
 **********
 **   18 **HESSE 
 **********

 FCN=   4828.385     FROM HESSE     STATUS=OK            33 CALLS      268 TOTAL
                     EDM=   .30E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .67287        2.8610        .77699E-04   -1.5544    
   2  Index         3.5062        2.1442        .81516E-02   -.30340    
   3  Normalizat    .96728        .24446        .27203E-03   -.94135    
   4  Prefactor     .99449        .20254        .22826E-03   -.92913    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.98948e-08
Minuit parameter uncertainties:
  1  2.77498
  2  2.2238
  3  0.24474
  4  0.202693
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/67985': 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) = 4828.38457941
delta logL = 0.267786089949

Extracting fit parameters...

4FGL J1040.5+0617
   Spectrum: PowerLaw
216    Prefactor:  6.729e-01  2.775e+00  1.000e-04  1.000e+04 ( 1.000e-12)
217        Index:  3.506e+00  2.224e+00  0.000e+00  1.000e+01 (-1.000e+00)
218        Scale:  8.643e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
533    Prefactor:  9.945e-01  2.027e-01  0.000e+00  1.000e+01 ( 1.000e+00)
534        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
535        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
532   Normalization:  9.673e-01  2.447e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 0.00
Ra Dec: 160.150 6.285

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/67985/cmap_HighResolution_517190401_517449601_4FGL_J1040.5+0617_daily_bin1072.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='8.95e-03', job_status='DONE', photon_flux_upper_limit='1.16e-07', time_completed='2021-09-02 08:44:55.466020', job_id='67985', GAL2='0.99', fit_tolerance='1e-08', EG2='0.97', EG='1.02', time_epoch_completed='1630597495.47', return_code2='0', ts='0.00', comment='SUCCESS', return_code='0', GAL='0.97', dlogl='2.68e-01', ts2='0.57', photon_index_error='0.00', photon_index='2.37' WHERE bin_id='1072' AND source_name='4FGL J1040.5+0617' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Sep  2 08:44:55 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0270>
Subject: Job 67985: <4FGL_J1040.5+0617_daily_bin1072> in cluster <slac> Done

Job <4FGL_J1040.5+0617_daily_bin1072> was submitted from host <rhel6-64j> by user <kocevski> in cluster <slac> at Thu Sep  2 08:31:28 2021
Job was executed on host(s) <bullet0270>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Sep  2 08:32:41 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Thu Sep  2 08:32:41 2021
Terminated at Thu Sep  2 08:44:56 2021
Results reported at Thu Sep  2 08:44:56 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1040.5+0617_daily_bin1072 160.15 6.2848 517190401 517449601 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1040.5+0617 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   511.00 sec.
    Max Memory :                                 1094 MB
    Average Memory :                             272.96 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   734 sec.
    Turnaround time :                            808 sec.

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

