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


Performing analysis on: 4FGL_J0407.5+0741_daily_bin369
RA = 61.8921, Dec = 7.6998
tmin = 334972801, tmax = 335232001
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='268474', job_status='RUN', time_executed='2021-08-20 05:44:23.518361', time_epoch_executed='1629463463.52' WHERE source_name='4FGL J0407.5+0741' and cadence='daily' and bin_id='369'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/268474

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

Retrieving the FT1 file...

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

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

Retrieving 45 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/268474/ft1_4FGL_J0407.5+0741_daily_bin369.fits


Retrieving the FT1 file...

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

Retrieving 45 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/268474/ft2_4FGL_J0407.5+0741_daily_bin369.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/268474/ft1_4FGL_J0407.5+0741_daily_bin369.fits outfile=/scratch/kocevski/268474/ft1_filteredMKT_4FGL_J0407.5+0741_daily_bin369.fits ra=61.8921 dec=7.6998 rad=12.0 tmin=334972801.0 tmax=335232001.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 2.74
user 2.31
sys 0.40

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/268474/ft2_4FGL_J0407.5+0741_daily_bin369.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/268474/ft1_filteredMKT_4FGL_J0407.5+0741_daily_bin369.fits evtable="EVENTS" outfile="/scratch/kocevski/268474/ft1_filtered_4FGL_J0407.5+0741_daily_bin369.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.62
user 0.23
sys 0.36

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/268474/ft1_filtered_4FGL_J0407.5+0741_daily_bin369.fits" evtable="EVENTS" scfile=/scratch/kocevski/268474/ft2_4FGL_J0407.5+0741_daily_bin369.fits sctable="SC_DATA" outfile=/scratch/kocevski/268474/ltcube_334972801_335232001_4FGL_J0407.5+0741_daily_bin369.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/268474/ft2_4FGL_J0407.5+0741_daily_bin369.fits
.....................!
real 8.90
user 8.37
sys 0.51

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/268474/ft1_filtered_4FGL_J0407.5+0741_daily_bin369.fits evtable="EVENTS" scfile=/scratch/kocevski/268474/ft2_4FGL_J0407.5+0741_daily_bin369.fits sctable="SC_DATA" expcube=/scratch/kocevski/268474/ltcube_334972801_335232001_4FGL_J0407.5+0741_daily_bin369.fits outfile=/scratch/kocevski/268474/expmap_334972801_335232001_4FGL_J0407.5+0741_daily_bin369.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/268474/ltcube_334972801_335232001_4FGL_J0407.5+0741_daily_bin369.fits
.....................!
real 141.26
user 137.24
sys 3.76

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/268474/ft1_filtered_4FGL_J0407.5+0741_daily_bin369.fits scfile=/scratch/kocevski/268474/ft2_4FGL_J0407.5+0741_daily_bin369.fits outfile=/scratch/kocevski/268474/cmap_334972801_335232001_4FGL_J0407.5+0741_daily_bin369.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 0.64
user 0.28
sys 0.34

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/268474/ft1_filtered_4FGL_J0407.5+0741_daily_bin369.fits scfile=/scratch/kocevski/268474/ft2_4FGL_J0407.5+0741_daily_bin369.fits outfile=/scratch/kocevski/268474/cmap_HighResolution_334972801_335232001_4FGL_J0407.5+0741_daily_bin369.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 0.64
user 0.29
sys 0.34

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

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/268474/ft1_filtered_4FGL_J0407.5+0741_daily_bin369.fits', '/scratch/kocevski/268474/ft2_4FGL_J0407.5+0741_daily_bin369.fits', expMap='/scratch/kocevski/268474/expmap_334972801_335232001_4FGL_J0407.5+0741_daily_bin369.fits', expCube='/scratch/kocevski/268474/ltcube_334972801_335232001_4FGL_J0407.5+0741_daily_bin369.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/268474/Model_4FGL_J0407.5+0741_daily_bin369.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/268474/ft1_filtered_4FGL_J0407.5+0741_daily_bin369.fits
Spacecraft file(s): /scratch/kocevski/268474/ft2_4FGL_J0407.5+0741_daily_bin369.fits
Exposure map: /scratch/kocevski/268474/expmap_334972801_335232001_4FGL_J0407.5+0741_daily_bin369.fits
Exposure cube: /scratch/kocevski/268474/ltcube_334972801_335232001_4FGL_J0407.5+0741_daily_bin369.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/268474/Model_4FGL_J0407.5+0741_daily_bin369.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) = 13351.5745631

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10154E-03   1.0000         .10000E-03   10000.    
     2 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
     3 'norm      '    .13073E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .60791       1.0000         .10000E-03   10000.    
     5 'Prefactor '    3.0388       1.0000         .10000E-03   10000.    
     6 'norm      '    .10004E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10161E-03   1.0000         .10000E-03   10000.    
     8 'norm      '    12.900       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10905E-03   1.0000         .10000E-03   10000.    
    10 'norm      '    .19101E-03   1.0000         .10000E-03   10000.    
    11 'norm      '    1.7958       1.0000         .10000E-03   10000.    
    12 'Prefactor '    1.4795       1.0000         .10000E-03   10000.    
    13 'Prefactor '    3.4371       1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10016E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    .11174E-03   1.0000         .10000E-03   10000.    
    17 'Prefactor '    .10017E-03   1.0000         .10000E-03   10000.    
    18 'norm      '    .11192       1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    20 'norm      '    .32726E-03   1.0000         .10000E-03   10000.    
    21 'Normalizat'    1.6091       1.0000         .10000E-01   10.000    
    22 'Prefactor '    .96253       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.

 FCN=   13351.52     FROM MIGRAD    STATUS=CONVERGED    537 CALLS     2118 TOTAL
                     EDM=   .76E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.0%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    6.8991       -.65872E-05** at limit **
   2  norm          .10000E-03    1.4870        .26449E-07** at limit **
   3  norm          .10004E-03    .69518        .35507E-06** at limit **
   4  Prefactor     .30852        35.775       -.21924E-05    .25077E-04
   5  Prefactor     3.0645        11.483       -.63057E-06   -.94582E-04
   6  norm          .10000E-03    7.0261        .25487E-05** at limit **
   7  Prefactor     .10000E-03    13.295       -.29216E-05** at limit **
   8  norm          12.899        5.9965        .21489E-06    .20565E-04
   9  Prefactor     .10000E-03    26.394        .43158E-05** at limit **
  10  norm          .10000E-03    42.015        .20484E-05** at limit **
  11  norm          1.7956        1.1885       -.42722E-07   -.23202E-03
  12  Prefactor     1.4788        1.7548       -.14895E-06   -.10024E-02
  13  Prefactor     3.4345        26.659       -.12038E-04   -.52934E-04
  14  Prefactor     .10000E-03    29.185       -.56444E-05** at limit **
  15  Prefactor     .10000E-03    5.8552       -.14355E-06** at limit **
  16  norm          .10000E-03    1.0219        .28810E-06** at limit **
  17  Prefactor     .10000E-03    12.423        .30401E-05** at limit **
  18  norm          .10164        1.0985       -.73065E-06    .86977E-03
  19  Prefactor     .10000E-03    2.1048       -.31918E-07** at limit **
  20  norm          .10000E-03    .60167       -.47657E-07** at limit **
  21  Normalizat    1.6095        .23508        .18017E-05    .16499E-03
  22  Prefactor     .96257        .61196E-01   -.12158E-06    .52966E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 0.000100038
  Prefactor  = 0.308518
  Prefactor  = 3.06453
  norm       = 0.0001
  Prefactor  = 0.0001
  norm       = 12.8994
  Prefactor  = 0.0001
  norm       = 0.000100001
  norm       = 1.79562
  Prefactor  = 1.47882
  Prefactor  = 3.43454
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  norm       = 0.101642
  Prefactor  = 0.0001
  norm       = 0.0001
  Normalizat = 1.60946
  Prefactor  = 0.962569
 **********
 **   18 **HESSE 
 **********

 FCN=   13351.52     FROM HESSE     STATUS=OK           350 CALLS     2468 TOTAL
                     EDM=   .11E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    6.8332        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  norm          .10000E-03    1.4881        .13761E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm          .10004E-03    6.6594        .18516E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .30852        33.939        .17404       -1.5597    
   5  Prefactor     3.0645        11.466        .23276E-03   -1.5358    
   6  norm          .10000E-03    7.0116        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10000E-03    13.284        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          12.899        5.9907        .11152E-03   -1.4989    
   9  Prefactor     .10000E-03    26.641        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  norm          .10000E-03    42.510        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  norm          1.7956        1.1705        .93709E-04   -1.5440    
  12  Prefactor     1.4788        1.7293        .15390E-03   -1.5465    
  13  Prefactor     3.4345        27.330        .21817E-03   -1.5337    
  14  Prefactor     .10000E-03    29.073        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .10000E-03    5.9069        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          .10000E-03    1.0562        .22799E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  Prefactor     .10000E-03    12.411        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  norm          .10164        11.572        .22920E-02   -1.5644    
  19  Prefactor     .10000E-03    2.1172        .16367E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  norm          .10000E-03    5.1657        .17354E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Normalizat    1.6095        .26514        .43614E-03   -.74747    
  22  Prefactor     .96257        .68899E-01    .15149E-03   -.93988    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.10479e-08
Minuit parameter uncertainties:
  1  2.45764e-06
  2  1.89259e-07
  3  0.00100306
  4  6.47445
  5  11.4741
  6  1.79755e-06
  7  1.02989e-05
  8  5.99093
  9  8.29119e-05
  10  0.000309056
  11  1.17047
  12  1.72934
  13  19.3888
  14  6.87141e-05
  15  4.85291e-06
  16  2.64606e-05
  17  2.99706e-06
  18  2.16842
  19  2.56762e-06
  20  3.24054e-05
  21  0.265374
  22  0.068905
Done.

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

Extracting fit parameters...

4FGL J0407.5+0741
   Spectrum: PowerLaw
217    Prefactor:  3.065e+00  1.147e+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:  9.626e-01  6.890e-02  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:  1.609e+00  2.654e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.08
Ra Dec: 61.892 7.700
Photon Flux Upper Limit: 9.77e-08 ph cm-2 s-1
Energy Flux Upper Limit: 7.51e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/268474/likelihoodResults_334972801_335232001_4FGL_J0407.5+0741_daily_bin369.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) = 13351.5014404
delta logL = 0.0220789248742

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 13351.490715
delta logL = 0.0328042993751

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    5.1265       1.0000         .10000E-03   10000.    
     2 'Index     '    1.9265       1.0000          .0000       10.000    
     3 'Normalizat'    1.6127       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .96161       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=   13351.49     FROM MIGRAD    STATUS=CONVERGED     89 CALLS      261 TOTAL
                     EDM=   .15E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     5.1230        14.720        .17757E-03    .39055E-04
   2  Index         1.9292        1.2286        .91452E-02    .84980E-04
   3  Normalizat    1.6127        .24186        .43578E-03   -.59247E-03
   4  Prefactor     .96173        .67830E-01    .15154E-03   -.19525E-02
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 5.12301
  Index      = 1.92924
  Normalizat = 1.61267
  Prefactor  = 0.961728
 **********
 **   18 **HESSE 
 **********

 FCN=   13351.49     FROM HESSE     STATUS=OK            23 CALLS      284 TOTAL
                     EDM=   .15E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     5.1230        14.592        .71027E-05   -1.5255    
   2  Index         1.9292        1.2185        .36581E-03   -.66131    
   3  Normalizat    1.6127        .24195        .87156E-04   -.74660    
   4  Prefactor     .96173        .67857E-01    .30308E-04   -.94016    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.47156e-09
Minuit parameter uncertainties:
  1  14.6017
  2  1.23877
  3  0.242131
  4  0.0678633
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/268474': 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) = 13351.4907082
delta logL = 0.032811148214

Extracting fit parameters...

4FGL J0407.5+0741
   Spectrum: PowerLaw
217    Prefactor:  5.123e+00  1.460e+01  1.000e-04  1.000e+04 ( 1.000e-13)
218        Index:  1.929e+00  1.239e+00  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:  9.617e-01  6.786e-02  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:  1.613e+00  2.421e-01  1.000e-02  1.000e+01 ( 1.000e+00)


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

Creating a high resolution counts map...
INFO: Auto-setting vmin to -1.000e-01 [aplpy.core]
INFO: Auto-setting vmax to  1.110e+00 [aplpy.core]
Saving /scratch/kocevski/268474/cmap_HighResolution_334972801_335232001_4FGL_J0407.5+0741_daily_bin369.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='7.51e-03', job_status='DONE', photon_flux_upper_limit='9.77e-08', time_completed='2021-08-20 05:55:59.487407', job_id='268474', GAL2='0.96', fit_tolerance='1e-08', EG2='1.61', EG='1.61', time_epoch_completed='1629464159.49', return_code2='0', ts='0.08', comment='SUCCESS', return_code='0', GAL='0.96', dlogl='3.28e-02', ts2='0.15', photon_index_error='0.00', photon_index='2.31' WHERE bin_id='369' AND source_name='4FGL J0407.5+0741' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Fri Aug 20 05:55:59 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0033>
Subject: Job 268474: <4FGL_J0407.5+0741_daily_bin369> in cluster <slac> Done

Job <4FGL_J0407.5+0741_daily_bin369> was submitted from host <rhel6-64j> by user <kocevski> in cluster <slac> at Fri Aug 20 05:40:25 2021
Job was executed on host(s) <bullet0033>, in queue <medium>, as user <kocevski> in cluster <slac> at Fri Aug 20 05:40:28 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:28 2021
Terminated at Fri Aug 20 05:56:00 2021
Results reported at Fri Aug 20 05:56:00 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J0407.5+0741_daily_bin369 61.8921 7.6998 334972801 335232001 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 :                                   696.04 sec.
    Max Memory :                                 1093 MB
    Average Memory :                             299.53 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   931 sec.
    Turnaround time :                            935 sec.

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

