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


Performing analysis on: 4FGL_J1204.8+0407_daily_bin1029
RA = 181.203, Dec = 4.12
tmin = 506044801, tmax = 506304001
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='310264', job_status='RUN', time_executed='2021-09-04 23:17:32.386797', time_epoch_executed='1630822652.39' WHERE source_name='4FGL J1204.8+0407' and cadence='daily' and bin_id='1029'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/310264

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/310264/ft1_4FGL_J1204.8+0407_daily_bin1029.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/310264/ft2_4FGL_J1204.8+0407_daily_bin1029.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/310264/ft1_4FGL_J1204.8+0407_daily_bin1029.fits outfile=/scratch/kocevski/310264/ft1_filteredMKT_4FGL_J1204.8+0407_daily_bin1029.fits ra=181.203 dec=4.12 rad=12.0 tmin=506044801.0 tmax=506304001.0 emin=100.0 emax=100000.0 zmin=0.0 zmax=90.0 evclass=128 evtype="INDEF" convtype=-1 phasemin=0.0 phasemax=1.0 evtable="EVENTS" chatter=2 clobber=yes debug=no gui=no mode="ql"

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

Done.
real 4.37
user 4.12
sys 0.20

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/310264/ft2_4FGL_J1204.8+0407_daily_bin1029.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/310264/ft1_filteredMKT_4FGL_J1204.8+0407_daily_bin1029.fits evtable="EVENTS" outfile="/scratch/kocevski/310264/ft1_filtered_4FGL_J1204.8+0407_daily_bin1029.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.32
sys 0.15

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/310264/ft1_filtered_4FGL_J1204.8+0407_daily_bin1029.fits" evtable="EVENTS" scfile=/scratch/kocevski/310264/ft2_4FGL_J1204.8+0407_daily_bin1029.fits sctable="SC_DATA" outfile=/scratch/kocevski/310264/ltcube_506044801_506304001_4FGL_J1204.8+0407_daily_bin1029.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/310264/ft2_4FGL_J1204.8+0407_daily_bin1029.fits
.....................!
real 11.88
user 11.44
sys 0.33

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/310264/ft1_filtered_4FGL_J1204.8+0407_daily_bin1029.fits evtable="EVENTS" scfile=/scratch/kocevski/310264/ft2_4FGL_J1204.8+0407_daily_bin1029.fits sctable="SC_DATA" expcube=/scratch/kocevski/310264/ltcube_506044801_506304001_4FGL_J1204.8+0407_daily_bin1029.fits outfile=/scratch/kocevski/310264/expmap_506044801_506304001_4FGL_J1204.8+0407_daily_bin1029.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/310264/ltcube_506044801_506304001_4FGL_J1204.8+0407_daily_bin1029.fits
.....................!
real 191.36
user 186.79
sys 4.19

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/310264/ft1_filtered_4FGL_J1204.8+0407_daily_bin1029.fits scfile=/scratch/kocevski/310264/ft2_4FGL_J1204.8+0407_daily_bin1029.fits outfile=/scratch/kocevski/310264/cmap_506044801_506304001_4FGL_J1204.8+0407_daily_bin1029.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.53
user 0.37
sys 0.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/310264/ft1_filtered_4FGL_J1204.8+0407_daily_bin1029.fits scfile=/scratch/kocevski/310264/ft2_4FGL_J1204.8+0407_daily_bin1029.fits outfile=/scratch/kocevski/310264/cmap_HighResolution_506044801_506304001_4FGL_J1204.8+0407_daily_bin1029.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.55
user 0.38
sys 0.15

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

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/310264/ft1_filtered_4FGL_J1204.8+0407_daily_bin1029.fits', '/scratch/kocevski/310264/ft2_4FGL_J1204.8+0407_daily_bin1029.fits', expMap='/scratch/kocevski/310264/expmap_506044801_506304001_4FGL_J1204.8+0407_daily_bin1029.fits', expCube='/scratch/kocevski/310264/ltcube_506044801_506304001_4FGL_J1204.8+0407_daily_bin1029.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/310264/Model_4FGL_J1204.8+0407_daily_bin1029.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/310264/ft1_filtered_4FGL_J1204.8+0407_daily_bin1029.fits
Spacecraft file(s): /scratch/kocevski/310264/ft2_4FGL_J1204.8+0407_daily_bin1029.fits
Exposure map: /scratch/kocevski/310264/expmap_506044801_506304001_4FGL_J1204.8+0407_daily_bin1029.fits
Exposure cube: /scratch/kocevski/310264/ltcube_506044801_506304001_4FGL_J1204.8+0407_daily_bin1029.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/310264/Model_4FGL_J1204.8+0407_daily_bin1029.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) = 5455.6873791

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    4.0331       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10014E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    36.750       1.0000         .10000E-03   10000.    
     4 'Prefactor '    67.056       1.0000         .10000E-03   10000.    
     5 'Prefactor '    6.2713       1.0000         .10000E-03   10000.    
     6 'Prefactor '    35.221       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10073E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10285E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    7.7865       1.0000         .10000E-03   10000.    
    13 'Prefactor '    40.593       1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .76590       1.0000         .10000E-03   10000.    
    16 'norm      '    1.8355       1.0000         .10000E-03   10000.    
    17 'norm      '    .20637E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    19 'norm      '    11.247       1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10017E-03   1.0000         .10000E-03   10000.    
    21 'norm      '    1.8389       1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10006E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    25 'norm      '    .10027E-03   1.0000         .10000E-03   10000.    
    26 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    27 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
    28 'Normalizat'    1.2054       1.0000         .10000E-01   10.000    
    29 'Prefactor '    1.0694       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=   5455.676     FROM MIGRAD    STATUS=CONVERGED    721 CALLS     3708 TOTAL
                     EDM=   .77E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  2.1%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     4.0329        3.0786        .23863E-06    .11721E-03
   2  Prefactor     .10000E-03    37.839       -.49179E-06** at limit **
   3  Prefactor     36.745        26.545       -.13252E-06   -.21843E-04
   4  Prefactor     67.234        130.50        .42083E-05    .49176E-04
   5  Prefactor     6.2708        8.9953        .40947E-06    .70612E-04
   6  Prefactor     35.229        38.177       -.34694E-06    .44926E-05
   7  Prefactor     .10000E-03    2.9393        .37280E-06** at limit **
   8  Prefactor     .10000E-03    5.0541       -.59587E-07** at limit **
   9  Prefactor     .10000E-03    10.508       -.26915E-06** at limit **
  10  Prefactor     .10000E-03    24.193       -.54577E-07** at limit **
  11  Prefactor     .10000E-03    47.535        .27787E-06** at limit **
  12  Prefactor     7.8081        63.253        .29296E-05   -.11051E-04
  13  Prefactor     40.607        28.472       -.92486E-06   -.24615E-03
  14  Prefactor     .10000E-03    15.021        .38076E-06** at limit **
  15  Prefactor     .72790        19.954        .52492E-06    .12035E-03
  16  norm          1.8393        2.5983       -.80493E-06   -.92434E-03
  17  norm          .10000E-03    2.1540        .10551E-05** at limit **
  18  Prefactor     .10000E-03    24.174       -.37790E-06** at limit **
  19  norm          11.249        36.498       -.15004E-05   -.71309E-04
  20  Prefactor     .10000E-03    47.512       -.87939E-07** at limit **
  21  norm          1.8397        .79109        .55738E-07   -.15977E-02
  22  Prefactor     .10000E-03    3.5332       -.14313E-06** at limit **
  23  Prefactor     .10000E-03    11.538       -.16373E-06** at limit **
  24  Prefactor     .10000E-03    3.6441       -.16105E-06** at limit **
  25  norm          .10000E-03    .94264       -.71334E-06** at limit **
  26  Prefactor     .10000E-03    4.1189       -.14310E-06** at limit **
  27  Prefactor     .10000E-03    29.783       -.34716E-06** at limit **
  28  Normalizat    1.2055        .26540       -.82041E-05   -.11680E-03
  29  Prefactor     1.0694        .21351        .64023E-05   -.24819E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 4.03286
  Prefactor  = 0.0001
  Prefactor  = 36.7449
  Prefactor  = 67.2337
  Prefactor  = 6.27079
  Prefactor  = 35.2289
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 7.80813
  Prefactor  = 40.6074
  Prefactor  = 0.0001
  Prefactor  = 0.727905
  norm       = 1.83925
  norm       = 0.000100001
  Prefactor  = 0.0001
  norm       = 11.2487
  Prefactor  = 0.0001
  norm       = 1.8397
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Normalizat = 1.20552
  Prefactor  = 1.06936
 **********
 **   18 **HESSE 
 **********

 FCN=   5455.676     FROM HESSE     STATUS=OK           549 CALLS     4257 TOTAL
                     EDM=   .37E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     4.0329        3.0772        .10796E-03   -1.5306    
   2  Prefactor     .10000E-03    38.176        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     36.745        26.548        .66111E-04   -1.4495    
   4  Prefactor     67.234        130.85        .24507E-03   -1.4066    
   5  Prefactor     6.2708        8.9957        .16029E-03   -1.5207    
   6  Prefactor     35.229        38.165        .67526E-04   -1.4520    
   7  Prefactor     .10000E-03    2.9494        .12376E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .10000E-03    5.0575        .16217E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     .10000E-03    10.599        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .10000E-03    24.196        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .10000E-03    47.775        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     7.8081        61.489        .14370E-03   -1.5149    
  13  Prefactor     40.607        28.863        .62914E-04   -1.4433    
  14  Prefactor     .10000E-03    15.038        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .72790        116.76        .48504E-02   -1.5537    
  16  norm          1.8393        2.8501        .12006E-03   -1.5437    
  17  norm          .10000E-03    7.8083        .19329E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .10000E-03    24.221        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  norm          11.249        36.191        .11946E-03   -1.5037    
  20  Prefactor     .10000E-03    47.513        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  norm          1.8397        .76590        .36796E-04   -1.5437    
  22  Prefactor     .10000E-03    3.5394        .13559E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .10000E-03    11.547        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     .10000E-03    3.6494        .13770E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  norm          .10000E-03    1.4304        .12938E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  Prefactor     .10000E-03    4.1263        .14641E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  Prefactor     .10000E-03    29.831        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  Normalizat    1.2055        .27126        .27913E-03   -.86432    
  29  Prefactor     1.0694        .21689        .24842E-03   -.90452    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 3.71919e-09
Minuit parameter uncertainties:
  1  3.07728
  2  2.874e-05
  3  26.5567
  4  131.412
  5  8.99764
  6  38.191
  7  1.75883e-05
  8  1.09593e-06
  9  2.57531e-05
  10  2.7738e-05
  11  4.64007e-06
  12  43.885
  13  28.8732
  14  5.01867e-05
  15  18.4731
  16  2.85031
  17  0.000203055
  18  6.40403e-05
  19  36.2621
  20  2.84676e-05
  21  0.765901
  22  3.87941e-06
  23  3.7787e-06
  24  7.52e-06
  25  4.53476e-05
  26  7.03904e-06
  27  8.76644e-06
  28  0.271574
  29  0.217071
Done.

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

Extracting fit parameters...

4FGL J1204.8+0407
   Spectrum: PowerLaw
316    Prefactor:  7.808e+00  4.389e+01  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:  1.069e+00  2.171e-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.206e+00  2.716e-01  1.000e-02  1.000e+01 ( 1.000e+00)


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

Saving results to:
/scratch/kocevski/310264/likelihoodResults_506044801_506304001_4FGL_J1204.8+0407_daily_bin1029.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) = 5455.48799714
delta logL = 0.188359144143

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 5455.45900448
delta logL = 0.217351811228

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    5.9194       1.0000         .10000E-03   10000.    
     2 'Index     '    3.8723       1.0000          .0000       10.000    
     3 'Normalizat'    1.1547       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.0951       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.
 MIGRAD TERMINATED WITHOUT CONVERGENCE.

 FCN=   5455.459     FROM MIGRAD    STATUS=FAILED        94 CALLS      269 TOTAL
                     EDM=   .21E-05    STRATEGY= 1      ERR MATRIX APPROXIMATE

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     5.9067        6181.1        .16505E-03   -.38159E-04
   2  Index         3.8730        7.2029        .77343E-02    .26793E-03
   3  Normalizat    1.1548        .27940        .28431E-03    .14247E-03
   4  Prefactor     1.0951        .25314        .24585E-03   -.16726E-03
                               ERR DEF=  .500    
 START SIMPLEX MINIMIZATION.    CONVERGENCE WHEN EDM .LT.   .20E-04
 SIMPLEX MINIMIZATION HAS CONVERGED.

 FCN=   5455.459     FROM SIMPLEX   STATUS=UNCHANGED    106 CALLS      375 TOTAL
                     EDM=   .11E-04    STRATEGY= 1      ERR MATRIX APPROXIMATE

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     5.9067        6181.1        .33726E-03   -1.5222    
   2  Index         3.8730        7.2029        .15878E-02   -.22735    
   3  Normalizat    1.1548        .27940        .13640E-03   -.88011    
   4  Prefactor     1.0951        .25314        .69763E-04   -.89625    
                               ERR DEF=  .500    

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   5455.459     FROM MIGRAD    STATUS=CONVERGED     31 CALLS      406 TOTAL
                     EDM=   .54E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     5.9066        22.761        .66021E-05   -.63714E-04
   2  Index         3.8730        2.2037        .15469E-02   -.77023E-05
   3  Normalizat    1.1548        .26610        .11372E-04    .13935E-03
   4  Prefactor     1.0951        .21784        .49170E-04   -.16735E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 5.90659
  Index      = 3.87304
  Normalizat = 1.15479
  Prefactor  = 1.09506
 **********
 **   18 **HESSE 
 **********

 FCN=   5455.459     FROM HESSE     STATUS=OK            23 CALLS      429 TOTAL
                     EDM=   .54E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     5.9066        20.807        .13204E-05   -1.5222    
   2  Index         3.8730        2.0243        .61874E-04   -.22735    
   3  Normalizat    1.1548        .26642        .22745E-05   -.88011    
   4  Prefactor     1.0951        .21795        .98340E-05   -.89625    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 5.40576e-10
Minuit parameter uncertainties:
  1  20.8329
  2  2.08758
  3  0.266734
  4  0.218123
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/310264': 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) = 5455.45900416
delta logL = 0.217352126448

Extracting fit parameters...

4FGL J1204.8+0407
   Spectrum: PowerLaw
316    Prefactor:  5.907e+00  2.083e+01  1.000e-04  1.000e+04 ( 1.000e-13)
317        Index:  3.873e+00  2.088e+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:  1.095e+00  2.181e-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.155e+00  2.667e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 0.04
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/310264/cmap_HighResolution_506044801_506304001_4FGL_J1204.8+0407_daily_bin1029.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='1.01e-02', job_status='DONE', photon_flux_upper_limit='1.30e-07', time_completed='2021-09-04 23:31:13.170002', job_id='310264', GAL2='1.10', fit_tolerance='1e-08', EG2='1.15', EG='1.21', time_epoch_completed='1630823473.17', return_code2='0', ts='0.04', comment='SUCCESS', return_code='0', GAL='1.07', dlogl='2.17e-01', ts2='0.53', photon_index_error='0.00', photon_index='2.58' WHERE bin_id='1029' AND source_name='4FGL J1204.8+0407' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sat Sep  4 23:31:13 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0230>
Subject: Job 310264: <4FGL_J1204.8+0407_daily_bin1029> in cluster <slac> Done

Job <4FGL_J1204.8+0407_daily_bin1029> was submitted from host <rhel6-64d> by user <kocevski> in cluster <slac> at Sat Sep  4 23:15:49 2021
Job was executed on host(s) <bullet0230>, in queue <medium>, as user <kocevski> in cluster <slac> at Sat Sep  4 23:15:51 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:15:51 2021
Terminated at Sat Sep  4 23:31:13 2021
Results reported at Sat Sep  4 23:31:13 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1204.8+0407_daily_bin1029 181.203 4.12 506044801 506304001 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 :                                   803.00 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             271.41 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   922 sec.
    Turnaround time :                            924 sec.

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

