/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 151 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 = 7397
number of fields = 27
No RA_SUN column yet. Adding RA_SUN/DEC_SUN columns.
Done.


Performing analysis on: 4FGL_J0407.5+0741_daily_bin322
RA = 61.8921, Dec = 7.6998
tmin = 322790401, tmax = 323049601
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='268407', job_status='RUN', time_executed='2021-08-20 05:45:40.076101', time_epoch_executed='1629463540.08' WHERE source_name='4FGL J0407.5+0741' and cadence='daily' and bin_id='322'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/268407

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/268407/ft1_4FGL_J0407.5+0741_daily_bin322.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/268407/ft2_4FGL_J0407.5+0741_daily_bin322.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/268407/ft1_4FGL_J0407.5+0741_daily_bin322.fits outfile=/scratch/kocevski/268407/ft1_filteredMKT_4FGL_J0407.5+0741_daily_bin322.fits ra=61.8921 dec=7.6998 rad=12.0 tmin=322790401.0 tmax=323049601.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 21.99
user 11.71
sys 10.17

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/268407/ft2_4FGL_J0407.5+0741_daily_bin322.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/268407/ft2_4FGL_J0407.5+0741_daily_bin322.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/268407/ft1_filteredMKT_4FGL_J0407.5+0741_daily_bin322.fits evtable="EVENTS" outfile="/scratch/kocevski/268407/ft1_filtered_4FGL_J0407.5+0741_daily_bin322.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 9.99
user 0.35
sys 9.60

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/268407/ft1_filtered_4FGL_J0407.5+0741_daily_bin322.fits" evtable="EVENTS" scfile=/scratch/kocevski/268407/ft2_4FGL_J0407.5+0741_daily_bin322.fits sctable="SC_DATA" outfile=/scratch/kocevski/268407/ltcube_322790401_323049601_4FGL_J0407.5+0741_daily_bin322.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/268407/ft2_4FGL_J0407.5+0741_daily_bin322.fits
.....................!
real 26.34
user 14.92
sys 11.33

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/268407/ft1_filtered_4FGL_J0407.5+0741_daily_bin322.fits evtable="EVENTS" scfile=/scratch/kocevski/268407/ft2_4FGL_J0407.5+0741_daily_bin322.fits sctable="SC_DATA" expcube=/scratch/kocevski/268407/ltcube_322790401_323049601_4FGL_J0407.5+0741_daily_bin322.fits outfile=/scratch/kocevski/268407/expmap_322790401_323049601_4FGL_J0407.5+0741_daily_bin322.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/268407/ltcube_322790401_323049601_4FGL_J0407.5+0741_daily_bin322.fits
.....................!
real 205.22
user 188.12
sys 16.69

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

Setting source of interest to:
4FGL J0407.5+0741 @ 61.8921 7.6998

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/268407/ft1_filtered_4FGL_J0407.5+0741_daily_bin322.fits scfile=/scratch/kocevski/268407/ft2_4FGL_J0407.5+0741_daily_bin322.fits outfile=/scratch/kocevski/268407/cmap_322790401_323049601_4FGL_J0407.5+0741_daily_bin322.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=61.8921 yref=7.6998 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 9.97
user 0.38
sys 9.54

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/268407/ft1_filtered_4FGL_J0407.5+0741_daily_bin322.fits scfile=/scratch/kocevski/268407/ft2_4FGL_J0407.5+0741_daily_bin322.fits outfile=/scratch/kocevski/268407/cmap_HighResolution_322790401_323049601_4FGL_J0407.5+0741_daily_bin322.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=61.8921 yref=7.6998 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 10.27
user 0.40
sys 9.53

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/268407/ft1_filtered_4FGL_J0407.5+0741_daily_bin322.fits evtable="EVENTS" scfile=/scratch/kocevski/268407/ft2_4FGL_J0407.5+0741_daily_bin322.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/268407/Model_4FGL_J0407.5+0741_daily_bin322.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/268407/ft1_filtered_4FGL_J0407.5+0741_daily_bin322.fits.....................!
real 60.57
user 46.68
sys 13.74

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/268407/ft1_filtered_4FGL_J0407.5+0741_daily_bin322.fits', '/scratch/kocevski/268407/ft2_4FGL_J0407.5+0741_daily_bin322.fits', expMap='/scratch/kocevski/268407/expmap_322790401_323049601_4FGL_J0407.5+0741_daily_bin322.fits', expCube='/scratch/kocevski/268407/ltcube_322790401_323049601_4FGL_J0407.5+0741_daily_bin322.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/268407/Model_4FGL_J0407.5+0741_daily_bin322.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J0407.5+0741'

4FGL J0407.5+0741
   Spectrum: PowerLaw
217    Prefactor:  5.499e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
218        Index:  2.311e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
219        Scale:  1.332e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/268407/ft1_filtered_4FGL_J0407.5+0741_daily_bin322.fits
Spacecraft file(s): /scratch/kocevski/268407/ft2_4FGL_J0407.5+0741_daily_bin322.fits
Exposure map: /scratch/kocevski/268407/expmap_322790401_323049601_4FGL_J0407.5+0741_daily_bin322.fits
Exposure cube: /scratch/kocevski/268407/ltcube_322790401_323049601_4FGL_J0407.5+0741_daily_bin322.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/268407/Model_4FGL_J0407.5+0741_daily_bin322.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) = 2972.21852869

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    58.340       1.0000         .10000E-03   10000.    
     2 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
     3 'norm      '    7.3382       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10026E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    27.967       1.0000         .10000E-03   10000.    
     6 'norm      '    .10010E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    28.651       1.0000         .10000E-03   10000.    
     8 'norm      '    12.741       1.0000         .10000E-03   10000.    
     9 'Prefactor '    73.136       1.0000         .10000E-03   10000.    
    10 'norm      '    47.036       1.0000         .10000E-03   10000.    
    11 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    4.5948       1.0000         .10000E-03   10000.    
    13 'Prefactor '    79.713       1.0000         .10000E-03   10000.    
    14 'Prefactor '    27.065       1.0000         .10000E-03   10000.    
    15 'Prefactor '    21.308       1.0000         .10000E-03   10000.    
    16 'norm      '    .10008E-03   1.0000         .10000E-03   10000.    
    17 'Prefactor '    48.482       1.0000         .10000E-03   10000.    
    18 'norm      '    .10008E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    1.6051       1.0000         .10000E-03   10000.    
    20 'norm      '    7.0391       1.0000         .10000E-03   10000.    
    21 'Normalizat'    .29053E-01   1.0000         .10000E-01   10.000    
    22 'Prefactor '    1.0142       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .4600E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   2972.217     FROM MIGRAD    STATUS=CONVERGED     64 CALLS     2690 TOTAL
                     EDM=   .67E-11  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  2.4%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     58.340        1.0024       -.15720E-07    .37844E-03
   2  norm          .10000E-03    5.4710        .14339E-05** at limit **
   3  norm          7.3381        1.1130       -.21677E-06   -.37573E-03
   4  Prefactor     .10000E-03    51.225       -.21073E-04** at limit **
   5  Prefactor     27.967        1.0032       -.25025E-07    .32170E-03
   6  norm          .10000E-03    31.375       -.63031E-05** at limit **
   7  Prefactor     28.651        1.0004        .28166E-08    .35121E-04
   8  norm          12.741        1.0065       -.58808E-08    .15444E-04
   9  Prefactor     73.136        1.0025       -.12680E-07    .50924E-03
  10  norm          47.036        1.0014        .90380E-09    .21275E-03
  11  norm          .10000E-03    1.3737        .56590E-05** at limit **
  12  Prefactor     4.5947        4.3140        .30099E-05    .52634E-04
  13  Prefactor     79.712        1.0018       -.54715E-08    .29056E-03
  14  Prefactor     27.064        1.0074       -.21978E-07    .55782E-03
  15  Prefactor     21.305        1.0739       -.11706E-06    .93481E-03
  16  norm          .10000E-03    8.7654        .38631E-05** at limit **
  17  Prefactor     48.481        1.0010       -.10285E-07    .24451E-03
  18  norm          .10000E-03    10.023        .52514E-05** at limit **
  19  Prefactor     1.6016        1.1391       -.60511E-06    .14469E-03
  20  norm          7.0388        1.2956       -.52972E-06    .35544E-03
  21  Normalizat    .28884E-01    6.1715       -.10114E-03    .39893E-06
  22  Prefactor     1.0143        .12874        .30032E-05    .91210E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 58.3395
  norm       = 0.0001
  norm       = 7.33811
  Prefactor  = 0.0001
  Prefactor  = 27.9668
  norm       = 0.0001
  Prefactor  = 28.6509
  norm       = 12.7409
  Prefactor  = 73.1357
  norm       = 47.036
  norm       = 0.0001
  Prefactor  = 4.59468
  Prefactor  = 79.712
  Prefactor  = 27.0641
  Prefactor  = 21.3048
  norm       = 0.0001
  Prefactor  = 48.4813
  norm       = 0.0001
  Prefactor  = 1.60159
  norm       = 7.03879
  Normalizat = 0.0288841
  Prefactor  = 1.01425
 **********
 **   18 **HESSE 
 **********

 FCN=   2972.217     FROM HESSE     STATUS=NOT POSDEF   396 CALLS     3086 TOTAL
                     EDM=   .97E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     58.340        89.428        .13131E-02   -1.4179    
   2  norm          .10000E-03    5.0257        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm          7.3381        10.864        .37015E-02   -1.5166    
   4  Prefactor     .10000E-03    47.156        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     27.967        49.040        .18939E-02   -1.4650    
   6  norm          .10000E-03    28.850        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     28.651        52.500        .18712E-02   -1.4637    
   8  norm          12.741        14.598        .28055E-02   -1.4994    
   9  Prefactor     73.136        71.129        .11736E-02   -1.3995    
  10  norm          47.036        88.414        .14616E-02   -1.4335    
  11  norm          .10000E-03    1.2958        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     4.5947        4.7749        .46945E-02   -1.5279    
  13  Prefactor     79.712        94.783        .11246E-02   -1.3920    
  14  Prefactor     27.064        499.11        .19251E-02   -1.4667    
  15  Prefactor     21.305        23.840        .21693E-02   -1.4784    
  16  norm          .10000E-03    7.9722        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  Prefactor     48.481        63.500        .14398E-02   -1.4314    
  18  norm          .10000E-03    9.1784        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     1.6016        634.48        .83624E-02   -1.5455    
  20  norm          7.0388        5.1233        .37801E-02   -1.5177    
  21  Normalizat    .28884E-01    8.1832        .32410       -1.4838    
  22  Prefactor     1.0143        .81993        .29271E-01   -.92256    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 9.68128e-08
Minuit parameter uncertainties:
  1  89.6346
  2  1.57547e-06
  3  10.8666
  4  0.000134316
  5  49.1111
  6  1.41976e-05
  7  52.5847
  8  14.6026
  9  71.2116
  10  88.6619
  11  7.60541e-08
  12  4.77525
  13  94.9633
  14  234.756
  15  23.8501
  16  1.64386e-06
  17  63.5889
  18  1.83694e-06
  19  64.4528
  20  5.12362
  21  1.9593
  22  0.830357
Done.

MINUIT Return Code (Fixed Index): 102
logL (Fixed Index) = 2972.21664321

Extracting fit parameters...

4FGL J0407.5+0741
   Spectrum: PowerLaw
217    Prefactor:  2.797e+01  4.911e+01  1.000e-04  1.000e+04 ( 1.000e-13)
218        Index:  2.311e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
219        Scale:  1.332e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
457    Prefactor:  1.014e+00  8.304e-01  0.000e+00  1.000e+01 ( 1.000e+00)
458        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
459        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
456   Normalization:  2.888e-02  1.959e+00  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.91
Ra Dec: 61.892 7.700
Photon Flux Upper Limit: 3.54e-07 ph cm-2 s-1
Energy Flux Upper Limit: 2.72e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/268407/likelihoodResults_322790401_323049601_4FGL_J0407.5+0741_daily_bin322.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) = 2972.21293153
delta logL = 0.00371167714411

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 2972.20934542
delta logL = 0.00729778521554

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    32.263       1.0000         .10000E-03   10000.    
     2 'Index     '    2.2123       1.0000          .0000       10.000    
     3 'Normalizat'    .30006E-01   1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.0139       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .4600E+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=   2972.209     FROM MIGRAD    STATUS=CONVERGED     89 CALLS      276 TOTAL
                     EDM=   .56E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     32.267        55.425        .70545E-04   -.14638E-03
   2  Index         2.2116        .83802        .62221E-02   -.10186E-03
   3  Normalizat    .32400E-01    6.5932        .16632E-01    .22987E-04
   4  Prefactor     1.0134        .16273        .12942E-03    .66676E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 32.2668
  Index      = 2.21164
  Normalizat = 0.0324003
  Prefactor  = 1.01335
 **********
 **   18 **HESSE 
 **********

 FCN=   2972.209     FROM HESSE     STATUS=OK            27 CALLS      303 TOTAL
                     EDM=   .62E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     32.267        52.705        .14109E-04   -1.4571    
   2  Index         2.2116        .79596        .24888E-03   -.59158    
   3  Normalizat    .32400E-01    6.0402        .66527E-03   -1.4761    
   4  Prefactor     1.0134        .13117        .25884E-04   -.92286    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 6.18409e-10
Minuit parameter uncertainties:
  1  52.7812
  2  0.800922
  3  0.49636
  4  0.131213
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/268407': 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) = 2972.20933292
delta logL = 0.00731028836435

Extracting fit parameters...

4FGL J0407.5+0741
   Spectrum: PowerLaw
217    Prefactor:  3.227e+01  5.278e+01  1.000e-04  1.000e+04 ( 1.000e-13)
218        Index:  2.212e+00  8.009e-01  0.000e+00  1.000e+01 (-1.000e+00)
219        Scale:  1.332e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
457    Prefactor:  1.013e+00  1.312e-01  0.000e+00  1.000e+01 ( 1.000e+00)
458        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
459        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
456   Normalization:  3.240e-02  4.964e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 0.91
Ra Dec: 61.892 7.700

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/268407/cmap_HighResolution_322790401_323049601_4FGL_J0407.5+0741_daily_bin322.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='2.72e-02', job_status='DONE', photon_flux_upper_limit='3.54e-07', time_completed='2021-08-20 05:56:45.777897', job_id='268407', GAL2='1.01', fit_tolerance='1e-08', EG2='0.03', EG='0.03', time_epoch_completed='1629464205.78', return_code2='0', ts='0.91', comment='SUCCESS', return_code='102', GAL='1.01', dlogl='7.31e-03', ts2='0.92', photon_index_error='0.00', photon_index='2.31' WHERE bin_id='322' AND source_name='4FGL J0407.5+0741' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Fri Aug 20 05:56:45 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0090>
Subject: Job 268407: <4FGL_J0407.5+0741_daily_bin322> in cluster <slac> Done

Job <4FGL_J0407.5+0741_daily_bin322> was submitted from host <rhel6-64j> by user <kocevski> in cluster <slac> at Fri Aug 20 05:40:19 2021
Job was executed on host(s) <bullet0090>, in queue <medium>, as user <kocevski> in cluster <slac> at Fri Aug 20 05:40:21 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Fri Aug 20 05:40:21 2021
Terminated at Fri Aug 20 05:56:48 2021
Results reported at Fri Aug 20 05:56:48 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J0407.5+0741_daily_bin322 61.8921 7.6998 322790401 323049601 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J0407.5+0741 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   817.00 sec.
    Max Memory :                                 1255 MB
    Average Memory :                             210.19 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   986 sec.
    Turnaround time :                            989 sec.

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

