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


Performing analysis on: 4FGL_J1040.5+0617_daily_bin731
RA = 160.15, Dec = 6.2848
tmin = 428803201, tmax = 429062401
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='65684', job_status='RUN', time_executed='2021-09-02 08:24:19.945033', time_epoch_executed='1630596259.95' WHERE source_name='4FGL J1040.5+0617' and cadence='daily' and bin_id='731'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/65684

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/65684/ft1_4FGL_J1040.5+0617_daily_bin731.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/65684/ft2_4FGL_J1040.5+0617_daily_bin731.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/65684/ft1_4FGL_J1040.5+0617_daily_bin731.fits outfile=/scratch/kocevski/65684/ft1_filteredMKT_4FGL_J1040.5+0617_daily_bin731.fits ra=160.15 dec=6.2848 rad=12.0 tmin=428803201.0 tmax=429062401.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 5.16
user 4.89
sys 0.23

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/65684/ft2_4FGL_J1040.5+0617_daily_bin731.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/65684/ft1_filteredMKT_4FGL_J1040.5+0617_daily_bin731.fits evtable="EVENTS" outfile="/scratch/kocevski/65684/ft1_filtered_4FGL_J1040.5+0617_daily_bin731.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.42
user 0.27
sys 0.13

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/65684/ft1_filtered_4FGL_J1040.5+0617_daily_bin731.fits" evtable="EVENTS" scfile=/scratch/kocevski/65684/ft2_4FGL_J1040.5+0617_daily_bin731.fits sctable="SC_DATA" outfile=/scratch/kocevski/65684/ltcube_428803201_429062401_4FGL_J1040.5+0617_daily_bin731.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/65684/ft2_4FGL_J1040.5+0617_daily_bin731.fits
.....................!
real 10.15
user 9.87
sys 0.26

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/65684/ft1_filtered_4FGL_J1040.5+0617_daily_bin731.fits evtable="EVENTS" scfile=/scratch/kocevski/65684/ft2_4FGL_J1040.5+0617_daily_bin731.fits sctable="SC_DATA" expcube=/scratch/kocevski/65684/ltcube_428803201_429062401_4FGL_J1040.5+0617_daily_bin731.fits outfile=/scratch/kocevski/65684/expmap_428803201_429062401_4FGL_J1040.5+0617_daily_bin731.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/65684/ltcube_428803201_429062401_4FGL_J1040.5+0617_daily_bin731.fits
.....................!
real 155.84
user 151.49
sys 4.06

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/65684/ft1_filtered_4FGL_J1040.5+0617_daily_bin731.fits scfile=/scratch/kocevski/65684/ft2_4FGL_J1040.5+0617_daily_bin731.fits outfile=/scratch/kocevski/65684/cmap_428803201_429062401_4FGL_J1040.5+0617_daily_bin731.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.48
user 0.32
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/65684/ft1_filtered_4FGL_J1040.5+0617_daily_bin731.fits scfile=/scratch/kocevski/65684/ft2_4FGL_J1040.5+0617_daily_bin731.fits outfile=/scratch/kocevski/65684/cmap_HighResolution_428803201_429062401_4FGL_J1040.5+0617_daily_bin731.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.86
user 0.33
sys 0.18

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

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/65684/ft1_filtered_4FGL_J1040.5+0617_daily_bin731.fits', '/scratch/kocevski/65684/ft2_4FGL_J1040.5+0617_daily_bin731.fits', expMap='/scratch/kocevski/65684/expmap_428803201_429062401_4FGL_J1040.5+0617_daily_bin731.fits', expCube='/scratch/kocevski/65684/ltcube_428803201_429062401_4FGL_J1040.5+0617_daily_bin731.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/65684/Model_4FGL_J1040.5+0617_daily_bin731.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/65684/ft1_filtered_4FGL_J1040.5+0617_daily_bin731.fits
Spacecraft file(s): /scratch/kocevski/65684/ft2_4FGL_J1040.5+0617_daily_bin731.fits
Exposure map: /scratch/kocevski/65684/expmap_428803201_429062401_4FGL_J1040.5+0617_daily_bin731.fits
Exposure cube: /scratch/kocevski/65684/ltcube_428803201_429062401_4FGL_J1040.5+0617_daily_bin731.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/65684/Model_4FGL_J1040.5+0617_daily_bin731.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) = 3932.13210065

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    10.582       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10426E-03   1.0000         .10000E-03   10000.    
     3 'norm      '    .12003E-01   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .12998E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .31409E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .34079E-02   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .12255E-03   1.0000         .10000E-03   10000.    
     8 'norm      '    1.5234       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    2.2475       1.0000         .10000E-03   10000.    
    11 'Prefactor '    8.3085       1.0000         .10000E-03   10000.    
    12 'Prefactor '    4.6798       1.0000         .10000E-03   10000.    
    13 'norm      '    .99207       1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10019E-03   1.0000         .10000E-03   10000.    
    15 'norm      '    1.9549       1.0000         .10000E-03   10000.    
    16 'Prefactor '    36.717       1.0000         .10000E-03   10000.    
    17 'norm      '    2.1150       1.0000         .10000E-03   10000.    
    18 'Normalizat'    1.2081       1.0000         .10000E-01   10.000    
    19 'Prefactor '    1.1039       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=   3932.080     FROM MIGRAD    STATUS=CONVERGED    404 CALLS     1683 TOTAL
                     EDM=   .63E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  2.0%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     10.531        21.783       -.10510E-04   -.27068E-03
   2  Prefactor     .10000E-03    33.744        .86321E-07** at limit **
   3  norm          .10192E-03    20.201        .91325E-05** at limit **
   4  Prefactor     .10000E-03    17.645       -.13197E-06** at limit **
   5  Prefactor     .10000E-03    88.605        .66513E-06** at limit **
   6  Prefactor     .10011E-03    793.68       -.20530E-04** at limit **
   7  Prefactor     .10000E-03    55.487       -.23160E-05** at limit **
   8  norm          1.5238        1.6348       -.32706E-07    .16633E-03
   9  Prefactor     .10000E-03    3.8331       -.10896E-07** at limit **
  10  Prefactor     2.2467        4.3124        .22221E-06   -.55646E-04
  11  Prefactor     8.3109        8.1310        .37961E-06   -.55558E-05
  12  Prefactor     4.6889        13.766        .66639E-06   -.14877E-05
  13  norm          .99188        .80818        .75567E-07   -.44113E-04
  14  Prefactor     .10000E-03    15.841        .50848E-07** at limit **
  15  norm          1.9549        1.3431        .39525E-07   -.40978E-04
  16  Prefactor     36.686        29.440        .44900E-06    .18618E-04
  17  norm          2.1167        17.158        .13348E-05   -.34551E-04
  18  Normalizat    1.2079        .26606       -.31720E-05    .23403E-04
  19  Prefactor     1.1041        .22157        .72854E-06   -.19651E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 10.5309
  Prefactor  = 0.0001
  norm       = 0.000101918
  Prefactor  = 0.000100001
  Prefactor  = 0.000100002
  Prefactor  = 0.000100106
  Prefactor  = 0.000100002
  norm       = 1.52378
  Prefactor  = 0.0001
  Prefactor  = 2.24673
  Prefactor  = 8.31089
  Prefactor  = 4.68885
  norm       = 0.991878
  Prefactor  = 0.0001
  norm       = 1.95493
  Prefactor  = 36.6857
  norm       = 2.11671
  Normalizat = 1.20789
  Prefactor  = 1.10414
 **********
 **   18 **HESSE 
 **********

 FCN=   3932.080     FROM HESSE     STATUS=OK           272 CALLS     1955 TOTAL
                     EDM=   .93E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     10.531        22.165        .12316E-03   -1.5059    
   2  Prefactor     .10000E-03    33.768        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm          .10192E-03    213.55        .47377E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    17.831        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10000E-03    89.184        .21370E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10011E-03    784.36        .39372E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10000E-03    55.897        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          1.5238        1.6234        .79814E-04   -1.5461    
   9  Prefactor     .10000E-03    3.8442        .11988E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     2.2467        4.2494        .16364E-03   -1.5408    
  11  Prefactor     8.3109        8.1529        .13908E-03   -1.5131    
  12  Prefactor     4.6889        13.575        .18603E-03   -1.5275    
  13  norm          .99188        .78155        .47708E-04   -1.5509    
  14  Prefactor     .10000E-03    15.992        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  norm          1.9549        1.3410        .58347E-04   -1.5428    
  16  Prefactor     36.686        29.454        .66141E-04   -1.4496    
  17  norm          2.1167        17.119        .28363E-03   -1.5417    
  18  Normalizat    1.2079        .31866        .26827E-03   -.86359    
  19  Prefactor     1.1041        .26756        .24647E-03   -.89334    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 9.25268e-09
Minuit parameter uncertainties:
  1  22.1823
  2  8.33986e-05
  3  0.0406186
  4  0.000287454
  5  0.00089282
  6  0.0184967
  7  0.000713204
  8  1.62342
  9  1.03872e-05
  10  4.24998
  11  8.15403
  12  13.5837
  13  0.781556
  14  7.74685e-06
  15  1.34102
  16  29.4659
  17  12.0436
  18  0.319172
  19  0.267886
Done.

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

Extracting fit parameters...

4FGL J1040.5+0617
   Spectrum: PowerLaw
216    Prefactor:  2.247e+00  4.250e+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:  1.104e+00  2.679e-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.208e+00  3.192e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.36
Ra Dec: 160.150 6.285
Photon Flux Upper Limit: 1.45e-07 ph cm-2 s-1
Energy Flux Upper Limit: 1.12e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/65684/likelihoodResults_428803201_429062401_4FGL_J1040.5+0617_daily_bin731.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) = 3932.07226004
delta logL = 0.00763805173119

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 3932.07029179
delta logL = 0.00960629808424

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    1.9922       1.0000         .10000E-03   10000.    
     2 'Index     '    2.5132       1.0000          .0000       10.000    
     3 'Normalizat'    1.2044       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.1062       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.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   3932.070     FROM MIGRAD    STATUS=CONVERGED     83 CALLS      241 TOTAL
                     EDM=   .19E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     1.9925        4.4784        .15005E-03   -.32493E-03
   2  Index         2.5131        1.1338        .86955E-02   -.40687E-04
   3  Normalizat    1.2044        .30189        .26860E-03    .18363E-03
   4  Prefactor     1.1063        .26591        .24626E-03    .19124E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 1.99247
  Index      = 2.51307
  Normalizat = 1.20439
  Prefactor  = 1.10625
 **********
 **   18 **HESSE 
 **********

 FCN=   3932.070     FROM HESSE     STATUS=OK            25 CALLS      266 TOTAL
                     EDM=   .21E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     1.9925        4.2228        .60019E-05   -1.5426    
   2  Index         2.5131        1.0703        .34782E-03   -.52058    
   3  Normalizat    1.2044        .30218        .53721E-04   -.86467    
   4  Prefactor     1.1063        .26606        .49252E-04   -.89267    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.08199e-10
Minuit parameter uncertainties:
  1  4.22347
  2  1.08142
  3  0.302616
  4  0.266383
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/65684': 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) = 3932.07029177
delta logL = 0.00960632368015

Extracting fit parameters...

4FGL J1040.5+0617
   Spectrum: PowerLaw
216    Prefactor:  1.992e+00  4.223e+00  1.000e-04  1.000e+04 ( 1.000e-12)
217        Index:  2.513e+00  1.081e+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:  1.106e+00  2.664e-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.204e+00  3.026e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 0.36
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/65684/cmap_HighResolution_428803201_429062401_4FGL_J1040.5+0617_daily_bin731.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='1.12e-02', job_status='DONE', photon_flux_upper_limit='1.45e-07', time_completed='2021-09-02 08:31:06.884797', job_id='65684', GAL2='1.11', fit_tolerance='1e-08', EG2='1.20', EG='1.21', time_epoch_completed='1630596666.88', return_code2='0', ts='0.36', comment='SUCCESS', return_code='0', GAL='1.10', dlogl='9.61e-03', ts2='0.38', photon_index_error='0.00', photon_index='2.37' WHERE bin_id='731' AND source_name='4FGL J1040.5+0617' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Sep  2 08:31:06 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0095>
Subject: Job 65684: <4FGL_J1040.5+0617_daily_bin731> in cluster <slac> Done

Job <4FGL_J1040.5+0617_daily_bin731> was submitted from host <rhel6-64k> by user <kocevski> in cluster <slac> at Thu Sep  2 08:21:20 2021
Job was executed on host(s) <bullet0095>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Sep  2 08:24:01 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:24:01 2021
Terminated at Thu Sep  2 08:31:07 2021
Results reported at Thu Sep  2 08:31:07 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1040.5+0617_daily_bin731 160.15 6.2848 428803201 429062401 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 :                                   402.00 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             333.19 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   426 sec.
    Turnaround time :                            587 sec.

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

