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


Performing analysis on: 4FGL_J1204.8+0407_daily_bin1223
RA = 181.203, Dec = 4.12
tmin = 556329601, tmax = 556588801
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='311710', job_status='RUN', time_executed='2021-09-04 23:23:12.159046', time_epoch_executed='1630822992.16' WHERE source_name='4FGL J1204.8+0407' and cadence='daily' and bin_id='1223'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/311710

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/311710/ft1_4FGL_J1204.8+0407_daily_bin1223.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/311710/ft2_4FGL_J1204.8+0407_daily_bin1223.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/311710/ft1_4FGL_J1204.8+0407_daily_bin1223.fits outfile=/scratch/kocevski/311710/ft1_filteredMKT_4FGL_J1204.8+0407_daily_bin1223.fits ra=181.203 dec=4.12 rad=12.0 tmin=556329601.0 tmax=556588801.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 3.76
user 3.51
sys 0.21

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/311710/ft2_4FGL_J1204.8+0407_daily_bin1223.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/311710/ft2_4FGL_J1204.8+0407_daily_bin1223.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/311710/ft1_filteredMKT_4FGL_J1204.8+0407_daily_bin1223.fits evtable="EVENTS" outfile="/scratch/kocevski/311710/ft1_filtered_4FGL_J1204.8+0407_daily_bin1223.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.50
user 0.35
sys 0.14

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/311710/ft1_filtered_4FGL_J1204.8+0407_daily_bin1223.fits" evtable="EVENTS" scfile=/scratch/kocevski/311710/ft2_4FGL_J1204.8+0407_daily_bin1223.fits sctable="SC_DATA" outfile=/scratch/kocevski/311710/ltcube_556329601_556588801_4FGL_J1204.8+0407_daily_bin1223.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/311710/ft2_4FGL_J1204.8+0407_daily_bin1223.fits
.....................!
real 12.04
user 11.68
sys 0.34

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/311710/ft1_filtered_4FGL_J1204.8+0407_daily_bin1223.fits evtable="EVENTS" scfile=/scratch/kocevski/311710/ft2_4FGL_J1204.8+0407_daily_bin1223.fits sctable="SC_DATA" expcube=/scratch/kocevski/311710/ltcube_556329601_556588801_4FGL_J1204.8+0407_daily_bin1223.fits outfile=/scratch/kocevski/311710/expmap_556329601_556588801_4FGL_J1204.8+0407_daily_bin1223.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/311710/ltcube_556329601_556588801_4FGL_J1204.8+0407_daily_bin1223.fits
.....................!
real 190.86
user 185.66
sys 4.80

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

Setting source of interest to:
4FGL J1204.8+0407 @ 181.203 4.12

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/311710/ft1_filtered_4FGL_J1204.8+0407_daily_bin1223.fits scfile=/scratch/kocevski/311710/ft2_4FGL_J1204.8+0407_daily_bin1223.fits outfile=/scratch/kocevski/311710/cmap_556329601_556588801_4FGL_J1204.8+0407_daily_bin1223.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=181.203 yref=4.12 axisrot=0.0 rafield="RA" decfield="DEC" proj="AIT" hpx_ordering_scheme="RING" hpx_order=3 hpx_ebin=yes hpx_region="" evtable="EVENTS" sctable="SC_DATA" efield="ENERGY" tfield="TIME" chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

This is gtbin version HEAD
real 0.55
user 0.37
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/311710/ft1_filtered_4FGL_J1204.8+0407_daily_bin1223.fits scfile=/scratch/kocevski/311710/ft2_4FGL_J1204.8+0407_daily_bin1223.fits outfile=/scratch/kocevski/311710/cmap_HighResolution_556329601_556588801_4FGL_J1204.8+0407_daily_bin1223.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=181.203 yref=4.12 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.57
user 0.39
sys 0.15

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/311710/ft1_filtered_4FGL_J1204.8+0407_daily_bin1223.fits evtable="EVENTS" scfile=/scratch/kocevski/311710/ft2_4FGL_J1204.8+0407_daily_bin1223.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/311710/Model_4FGL_J1204.8+0407_daily_bin1223.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/311710/ft1_filtered_4FGL_J1204.8+0407_daily_bin1223.fits......................!
real 21.95
user 20.67
sys 1.22

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/311710/ft1_filtered_4FGL_J1204.8+0407_daily_bin1223.fits', '/scratch/kocevski/311710/ft2_4FGL_J1204.8+0407_daily_bin1223.fits', expMap='/scratch/kocevski/311710/expmap_556329601_556588801_4FGL_J1204.8+0407_daily_bin1223.fits', expCube='/scratch/kocevski/311710/ltcube_556329601_556588801_4FGL_J1204.8+0407_daily_bin1223.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/311710/Model_4FGL_J1204.8+0407_daily_bin1223.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1204.8+0407'

4FGL J1204.8+0407
   Spectrum: PowerLaw
316    Prefactor:  3.692e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
317        Index:  2.578e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
318        Scale:  7.480e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/311710/ft1_filtered_4FGL_J1204.8+0407_daily_bin1223.fits
Spacecraft file(s): /scratch/kocevski/311710/ft2_4FGL_J1204.8+0407_daily_bin1223.fits
Exposure map: /scratch/kocevski/311710/expmap_556329601_556588801_4FGL_J1204.8+0407_daily_bin1223.fits
Exposure cube: /scratch/kocevski/311710/ltcube_556329601_556588801_4FGL_J1204.8+0407_daily_bin1223.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/311710/Model_4FGL_J1204.8+0407_daily_bin1223.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) = 1053.37733877

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10049E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    59.400       1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    277.20       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10127E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    46.884       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    .11293E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    89.965       1.0000         .10000E-03   10000.    
    10 'Prefactor '    1137.5       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10036E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    32.919       1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10020E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    .10005E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10083E-03   1.0000         .10000E-03   10000.    
    19 'norm      '    181.21       1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10205E-03   1.0000         .10000E-03   10000.    
    21 'norm      '    .10042E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    .13006E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    6057.4       1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10007E-03   1.0000         .10000E-03   10000.    
    25 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    26 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    27 'Prefactor '    .10009E-03   1.0000         .10000E-03   10000.    
    28 'Normalizat'    1.1491       1.0000         .10000E-01   10.000    
    29 'Prefactor '    .49448       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6140E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   1052.341     FROM MIGRAD    STATUS=CONVERGED    725 CALLS     4934 TOTAL
                     EDM=   .24E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .6%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    6.0054       -.31382E-06** at limit **
   2  Prefactor     59.420        49.281       -.50012E-07    .13198E-05
   3  Prefactor     .10000E-03    26.524        .42775E-07** at limit **
   4  Prefactor     277.08        524.51        .42481E-06    .24402E-05
   5  Prefactor     .10000E-03    67.638        .17682E-05** at limit **
   6  Prefactor     46.873        81.350       -.88620E-06   -.64761E-05
   7  Prefactor     .10000E-03    12.340        .87452E-06** at limit **
   8  Prefactor     .10000E-03    459.30        .63517E-05** at limit **
   9  Prefactor     89.972        42.001        .12194E-06    .68719E-06
  10  Prefactor     1138.8        1374.1        .23835E-05    .84429E-05
  11  Prefactor     .10000E-03    47.555       -.24335E-06** at limit **
  12  Prefactor     33.000        214.70        .46549E-05    .18341E-04
  13  Prefactor     .10000E-03    17.633        .12143E-06** at limit **
  14  Prefactor     .10000E-03    56.875        .28528E-06** at limit **
  15  Prefactor     .10000E-03    17.158       -.20995E-06** at limit **
  16  norm          .10000E-03    2.5676       -.11705E-06** at limit **
  17  norm          .10000E-03    6.8779       -.28791E-07** at limit **
  18  Prefactor     .10000E-03    161.21        .36232E-06** at limit **
  19  norm          181.15        165.93        .32462E-05    .11670E-03
  20  Prefactor     .10000E-03    447.84        .10111E-06** at limit **
  21  norm          .10000E-03    1.9017       -.13941E-05** at limit **
  22  Prefactor     .10000E-03    519.52       -.67842E-06** at limit **
  23  Prefactor     6056.5        7998.8       -.62653E-07    .58760E-07
  24  Prefactor     .10000E-03    13.862       -.15880E-06** at limit **
  25  norm          .10000E-03    2.7647       -.86413E-08** at limit **
  26  Prefactor     .10000E-03    29.946       -.18146E-06** at limit **
  27  Prefactor     .10000E-03    87.388       -.30490E-06** at limit **
  28  Normalizat    1.1484        .61712       -.79867E-05    .15443E-03
  29  Prefactor     .49488        .40445        .95168E-05    .94193E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 59.4205
  Prefactor  = 0.0001
  Prefactor  = 277.079
  Prefactor  = 0.0001
  Prefactor  = 46.8726
  Prefactor  = 0.0001
  Prefactor  = 0.000100002
  Prefactor  = 89.9723
  Prefactor  = 1138.84
  Prefactor  = 0.0001
  Prefactor  = 33.0003
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  norm       = 181.151
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 6056.5
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Normalizat = 1.14836
  Prefactor  = 0.494882
 **********
 **   18 **HESSE 
 **********

 FCN=   1052.341     FROM HESSE     STATUS=OK           533 CALLS     5467 TOTAL
                     EDM=   .55E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    6.1457        .15507E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     59.420        49.337        .52057E-04   -1.4165    
   3  Prefactor     .10000E-03    26.532        .16326E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     277.08        524.54        .12182E-03   -1.2363    
   5  Prefactor     .10000E-03    67.703        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     46.873        81.385        .58559E-04   -1.4338    
   7  Prefactor     .10000E-03    12.342        .11129E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .10000E-03    459.92        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     89.972        42.160        .42364E-04   -1.3808    
  10  Prefactor     1138.8        1374.5        .62990E-04   -.88235    
  11  Prefactor     .10000E-03    47.570        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     33.000        216.55        .69840E-04   -1.4558    
  13  Prefactor     .10000E-03    17.635        .13310E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     .10000E-03    56.882        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .10000E-03    17.205        .13129E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          .10000E-03    2.5760        .50776E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          .10000E-03    6.8833        .83095E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .10000E-03    161.23        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  norm          181.15        170.59        .14994E-03   -1.3008    
  20  Prefactor     .10000E-03    447.83        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  norm          .10000E-03    2.6494        .79654E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     .10000E-03    519.63        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     6056.5        7998.7        .40926E-04    .21290    
  24  Prefactor     .10000E-03    13.884        .11799E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  norm          .10000E-03    2.7648        .52689E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  Prefactor     .10000E-03    30.083        .17347E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  Prefactor     .10000E-03    87.430        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  Normalizat    1.1484        .66361        .28325E-03   -.88214    
  29  Prefactor     .49488        .43660        .28893E-03   -1.1221    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 5.52578e-10
Minuit parameter uncertainties:
  1  1.50042e-05
  2  49.3712
  3  1.2169e-05
  4  533.908
  5  0.000294188
  6  81.5791
  7  4.25163e-05
  8  0.00213527
  9  42.1743
  10  1421.43
  11  9.7057e-05
  12  169.971
  13  1.08791e-05
  14  0.000112007
  15  2.29185e-05
  16  3.93489e-06
  17  1.98988e-06
  18  0.000298187
  19  171.063
  20  0.000163838
  21  3.13986e-05
  22  0.00101814
  23  7965.46
  24  4.91339e-06
  25  1.70582e-07
  26  5.25457e-06
  27  0.000229919
  28  0.668541
  29  0.439608
Done.

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

Extracting fit parameters...

4FGL J1204.8+0407
   Spectrum: PowerLaw
316    Prefactor:  3.300e+01  1.700e+02  1.000e-04  1.000e+04 ( 1.000e-13)
317        Index:  2.578e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
318        Scale:  7.480e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
611    Prefactor:  4.949e-01  4.396e-01  0.000e+00  1.000e+01 ( 1.000e+00)
612        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
613        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
610   Normalization:  1.148e+00  6.685e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.05
Ra Dec: 181.203 4.120
Photon Flux Upper Limit: 5.61e-07 ph cm-2 s-1
Energy Flux Upper Limit: 4.38e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/311710/likelihoodResults_556329601_556588801_4FGL_J1204.8+0407_daily_bin1223.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) = 1052.01755813
delta logL = 0.323483779781

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 1051.98485414
delta logL = 0.356187771043

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    18.493       1.0000         .10000E-03   10000.    
     2 'Index     '    4.2084       1.0000          .0000       10.000    
     3 'Normalizat'    .99186       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .56960       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6140E+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=   1051.985     FROM MIGRAD    STATUS=CONVERGED     85 CALLS      294 TOTAL
                     EDM=   .10E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     18.516        79.936        .93135E-04    .10766E-03
   2  Index         4.2074        2.4585        .45100E-02    .40448E-04
   3  Normalizat    .99322        .64447        .30098E-03    .20566E-03
   4  Prefactor     .56858        .44103        .27063E-03    .69354E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 18.5156
  Index      = 4.20745
  Normalizat = 0.993222
  Prefactor  = 0.568582
 **********
 **   18 **HESSE 
 **********

 FCN=   1051.985     FROM HESSE     STATUS=OK            25 CALLS      319 TOTAL
                     EDM=   .10E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     18.516        57.982        .37254E-05   -1.4847    
   2  Index         4.2074        1.8900        .18040E-03   -.15918    
   3  Normalizat    .99322        .64543        .60196E-04   -.93258    
   4  Prefactor     .56858        .44166        .10825E-04   -1.0893    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.0376e-09
Minuit parameter uncertainties:
  1  58.1589
  2  1.93956
  3  0.650603
  4  0.444379
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/311710': 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) = 1051.98485141
delta logL = 0.356190498629

Extracting fit parameters...

4FGL J1204.8+0407
   Spectrum: PowerLaw
316    Prefactor:  1.852e+01  5.816e+01  1.000e-04  1.000e+04 ( 1.000e-13)
317        Index:  4.207e+00  1.940e+00  0.000e+00  1.000e+01 (-1.000e+00)
318        Scale:  7.480e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
611    Prefactor:  5.686e-01  4.444e-01  0.000e+00  1.000e+01 ( 1.000e+00)
612        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
613        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
610   Normalization:  9.932e-01  6.506e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 0.05
Ra Dec: 181.203 4.120

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/311710/cmap_HighResolution_556329601_556588801_4FGL_J1204.8+0407_daily_bin1223.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='4.38e-02', job_status='DONE', photon_flux_upper_limit='5.61e-07', time_completed='2021-09-04 23:30:21.380460', job_id='311710', GAL2='0.57', fit_tolerance='1e-08', EG2='0.99', EG='1.15', time_epoch_completed='1630823421.38', return_code2='0', ts='0.05', comment='SUCCESS', return_code='0', GAL='0.49', dlogl='3.56e-01', ts2='0.83', photon_index_error='0.00', photon_index='2.58' WHERE bin_id='1223' AND source_name='4FGL J1204.8+0407' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sat Sep  4 23:30:21 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0098>
Subject: Job 311710: <4FGL_J1204.8+0407_daily_bin1223> in cluster <slac> Done

Job <4FGL_J1204.8+0407_daily_bin1223> was submitted from host <rhel6-64j> by user <kocevski> in cluster <slac> at Sat Sep  4 23:20:20 2021
Job was executed on host(s) <bullet0098>, in queue <medium>, as user <kocevski> in cluster <slac> at Sat Sep  4 23:20:22 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sat Sep  4 23:20:22 2021
Terminated at Sat Sep  4 23:30:22 2021
Results reported at Sat Sep  4 23:30:22 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1204.8+0407_daily_bin1223 181.203 4.12 556329601 556588801 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1204.8+0407 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   426.06 sec.
    Max Memory :                                 1094 MB
    Average Memory :                             251.19 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   599 sec.
    Turnaround time :                            602 sec.

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

