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


Performing analysis on: 4FGL_J1204.8+0407_daily_bin1240
RA = 181.203, Dec = 4.12
tmin = 560736001, tmax = 560995201
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='311734', job_status='RUN', time_executed='2021-09-04 23:22:38.375642', time_epoch_executed='1630822958.38' WHERE source_name='4FGL J1204.8+0407' and cadence='daily' and bin_id='1240'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/311734

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/311734/ft1_4FGL_J1204.8+0407_daily_bin1240.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/311734/ft2_4FGL_J1204.8+0407_daily_bin1240.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/311734/ft1_4FGL_J1204.8+0407_daily_bin1240.fits outfile=/scratch/kocevski/311734/ft1_filteredMKT_4FGL_J1204.8+0407_daily_bin1240.fits ra=181.203 dec=4.12 rad=12.0 tmin=560736001.0 tmax=560995201.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.54
sys 0.21

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/311734/ft2_4FGL_J1204.8+0407_daily_bin1240.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/311734/ft1_filteredMKT_4FGL_J1204.8+0407_daily_bin1240.fits evtable="EVENTS" outfile="/scratch/kocevski/311734/ft1_filtered_4FGL_J1204.8+0407_daily_bin1240.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.51
user 0.33
sys 0.16

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

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/311734/ft1_filtered_4FGL_J1204.8+0407_daily_bin1240.fits evtable="EVENTS" scfile=/scratch/kocevski/311734/ft2_4FGL_J1204.8+0407_daily_bin1240.fits sctable="SC_DATA" expcube=/scratch/kocevski/311734/ltcube_560736001_560995201_4FGL_J1204.8+0407_daily_bin1240.fits outfile=/scratch/kocevski/311734/expmap_560736001_560995201_4FGL_J1204.8+0407_daily_bin1240.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/311734/ltcube_560736001_560995201_4FGL_J1204.8+0407_daily_bin1240.fits
.....................!
real 193.89
user 187.83
sys 5.37

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/311734/ft1_filtered_4FGL_J1204.8+0407_daily_bin1240.fits scfile=/scratch/kocevski/311734/ft2_4FGL_J1204.8+0407_daily_bin1240.fits outfile=/scratch/kocevski/311734/cmap_560736001_560995201_4FGL_J1204.8+0407_daily_bin1240.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.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/311734/ft1_filtered_4FGL_J1204.8+0407_daily_bin1240.fits scfile=/scratch/kocevski/311734/ft2_4FGL_J1204.8+0407_daily_bin1240.fits outfile=/scratch/kocevski/311734/cmap_HighResolution_560736001_560995201_4FGL_J1204.8+0407_daily_bin1240.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.59
user 0.39
sys 0.15

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

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

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    85.847       1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10456E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    26.892       1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10015E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    12.254       1.0000         .10000E-03   10000.    
    10 'Prefactor '    16.039       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10167E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    111.19       1.0000         .10000E-03   10000.    
    13 'Prefactor '    43.086       1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10170E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    3.6901       1.0000         .10000E-03   10000.    
    17 'norm      '    .10078E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    19 'norm      '    161.54       1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    21 'norm      '    .10003E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    .17761E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    402.76       1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10030E-03   1.0000         .10000E-03   10000.    
    25 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    26 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    27 'Prefactor '    .10019E-03   1.0000         .10000E-03   10000.    
    28 'Normalizat'    .25626       1.0000         .10000E-01   10.000    
    29 'Prefactor '    1.4707       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=   2026.182     FROM MIGRAD    STATUS=CONVERGED    714 CALLS     4413 TOTAL
                     EDM=   .74E-10  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  4.0%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    3.2729        .75634E-07** at limit **
   2  Prefactor     85.856        50.265       -.45595E-06    .13878E-04
   3  Prefactor     .10000E-03    19.844        .11529E-06** at limit **
   4  Prefactor     .10000E-03    130.16        .20749E-05** at limit **
   5  Prefactor     26.893        31.410       -.12891E-07    .11014E-04
   6  Prefactor     .10000E-03    27.308       -.42729E-06** at limit **
   7  Prefactor     .10000E-03    7.4998       -.20032E-06** at limit **
   8  Prefactor     .10000E-03    45.024       -.63570E-06** at limit **
   9  Prefactor     12.266        25.060       -.70986E-06    .12306E-04
  10  Prefactor     15.963        1943.4       -.62046E-05   -.16032E-06
  11  Prefactor     .10000E-03    35.418        .52605E-06** at limit **
  12  Prefactor     111.11        149.80       -.27506E-07    .46750E-04
  13  Prefactor     43.094        55.997       -.31209E-06    .43875E-04
  14  Prefactor     .10000E-03    93.795       -.28568E-06** at limit **
  15  Prefactor     .10000E-03    14.010       -.25412E-06** at limit **
  16  norm          3.6901        3.8302       -.22383E-07    .10286E-03
  17  norm          .10000E-03    37.040       -.64082E-05** at limit **
  18  Prefactor     .10000E-03    64.285       -.12354E-05** at limit **
  19  norm          161.46        134.56        .90240E-06    .79552E-04
  20  Prefactor     .10000E-03    266.32       -.39529E-05** at limit **
  21  norm          .10000E-03    .57336       -.46968E-06** at limit **
  22  Prefactor     .10000E-03    212.76        .10674E-05** at limit **
  23  Prefactor     403.00        824.69       -.12979E-06    .61419E-05
  24  Prefactor     .10000E-03    13.056        .25643E-07** at limit **
  25  norm          .10000E-03    1.6821       -.31899E-07** at limit **
  26  Prefactor     .10000E-03    6.8603       -.18990E-08** at limit **
  27  Prefactor     .10000E-03    38.182        .26870E-06** at limit **
  28  Normalizat    .25604        .48445        .48641E-05    .38868E-04
  29  Prefactor     1.4708        .35127       -.69339E-06    .83662E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 85.8557
  Prefactor  = 0.0001
  Prefactor  = 0.000100001
  Prefactor  = 26.8929
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 12.2656
  Prefactor  = 15.9629
  Prefactor  = 0.0001
  Prefactor  = 111.111
  Prefactor  = 43.0944
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 3.6901
  norm       = 0.0001
  Prefactor  = 0.0001
  norm       = 161.459
  Prefactor  = 0.000100002
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 402.997
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Normalizat = 0.256035
  Prefactor  = 1.47085
 **********
 **   18 **HESSE 
 **********

 FCN=   2026.182     FROM HESSE     STATUS=OK           533 CALLS     4946 TOTAL
                     EDM=   .13E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    3.3948        .15900E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     85.856        50.534        .43359E-04   -1.3852    
   3  Prefactor     .10000E-03    19.851        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    130.82        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     26.893        31.392        .77252E-04   -1.4670    
   6  Prefactor     .10000E-03    27.341        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10000E-03    7.5056        .12040E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .10000E-03    45.060        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     12.266        25.215        .11444E-03   -1.5007    
  10  Prefactor     15.963        1957.3        .10001E-03   -1.4909    
  11  Prefactor     .10000E-03    35.462        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     111.11        150.84        .19074E-03   -1.3596    
  13  Prefactor     43.094        56.047        .61075E-04   -1.4394    
  14  Prefactor     .10000E-03    94.063        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .10000E-03    14.031        .16453E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          3.6901        3.8299        .86117E-04   -1.5324    
  17  norm          .10000E-03    37.509        .36285E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .10000E-03    64.487        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  norm          161.46        136.87        .15864E-03   -1.3160    
  20  Prefactor     .10000E-03    268.10        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  norm          .10000E-03    .58500        .65996E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     .10000E-03    212.66        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     403.00        825.93        .10173E-03   -1.1666    
  24  Prefactor     .10000E-03    13.097        .15885E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  norm          .10000E-03    1.6851        .57016E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  Prefactor     .10000E-03    6.8625        .11516E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  Prefactor     .10000E-03    38.196        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  Normalizat    .25604        .48781        .58415E-03   -1.2556    
  29  Prefactor     1.4708        .35466        .20513E-03   -.78359    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.32913e-10
Minuit parameter uncertainties:
  1  6.2545e-06
  2  50.559
  3  5.53314e-06
  4  0.000578936
  5  31.4115
  6  5.3025e-05
  7  4.33533e-07
  8  7.60343e-05
  9  25.2366
  10  366.539
  11  5.67678e-05
  12  151.365
  13  56.1154
  14  0.000243668
  15  4.45806e-08
  16  3.83011
  17  0.000261751
  18  0.00022498
  19  137.143
  20  0.00139376
  21  2.23028e-06
  22  0.000344525
  23  852.366
  24  1.86103e-06
  25  1.88585e-08
  26  3.95584e-07
  27  3.80277e-05
  28  0.496264
  29  0.355255
Done.

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

Extracting fit parameters...

4FGL J1204.8+0407
   Spectrum: PowerLaw
316    Prefactor:  1.111e+02  1.514e+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:  1.471e+00  3.553e-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:  2.560e-01  4.963e-01  1.000e-02  1.000e+01 ( 1.000e+00)


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

Saving results to:
/scratch/kocevski/311734/likelihoodResults_560736001_560995201_4FGL_J1204.8+0407_daily_bin1240.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) = 2025.60985404
delta logL = 0.572043212345

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 2025.58983216
delta logL = 0.592065090965

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    58.590       1.0000         .10000E-03   10000.    
     2 'Index     '    3.5285       1.0000          .0000       10.000    
     3 'Normalizat'    .14205       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.5254       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=   2025.590     FROM MIGRAD    STATUS=CONVERGED     94 CALLS      325 TOTAL
                     EDM=   .28E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     58.487        102.88        .52413E-04   -.13880E-03
   2  Index         3.5292        1.0635        .40110E-02   -.12239E-03
   3  Normalizat    .14089        .46749        .76681E-02   -.65671E-04
   4  Prefactor     1.5262        .37057        .20157E-03   -.19698E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 58.487
  Index      = 3.52925
  Normalizat = 0.140894
  Prefactor  = 1.52621
 **********
 **   18 **HESSE 
 **********

 FCN=   2025.590     FROM HESSE     STATUS=OK            27 CALLS      352 TOTAL
                     EDM=   .32E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     58.487        91.106        .10483E-04   -1.4177    
   2  Index         3.5292        .94284        .16044E-03   -.29857    
   3  Normalizat    .14089        .44594        .30673E-03   -1.3414    
   4  Prefactor     1.5262        .35308        .40315E-04   -.76808    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 3.23968e-10
Minuit parameter uncertainties:
  1  91.3245
  2  0.949062
  3  0.45827
  4  0.353653
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/311734': 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) = 2025.58982726
delta logL = 0.592069989114

Extracting fit parameters...

4FGL J1204.8+0407
   Spectrum: PowerLaw
316    Prefactor:  5.849e+01  9.132e+01  1.000e-04  1.000e+04 ( 1.000e-13)
317        Index:  3.529e+00  9.491e-01  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.526e+00  3.537e-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.409e-01  4.583e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 2.18
Ra Dec: 181.203 4.120
Photon Index (Free Index): 3.53 +/- 0.95
Photon Flux (Free Index): 2.81e-07 +/- 2.42e-07
Energy Flux (Free Index): 4.65e-05 +/- 3.87e-05

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/311734/cmap_HighResolution_560736001_560995201_4FGL_J1204.8+0407_daily_bin1240.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='3.62e-02', comment='SUCCESS', energy_flux2='4.65e-05', dlogl='5.92e-01', photon_flux2='2.81e-07', job_status='DONE', time_completed='2021-09-04 23:31:10.087909', photon_index_error2='0.95', photon_index2='3.53', ts='0.76', fit_tolerance='1e-08', GAL='1.47', photon_index_error='0.00', photon_flux_upper_limit='4.63e-07', energy_flux_error2='3.87e-05', EG='0.26', time_epoch_completed='1630823470.09', return_code='0', job_id='311734', GAL2='1.53', EG2='0.14', return_code2='0', photon_flux_error2='2.42e-07', ts2='2.18', photon_index='2.58' WHERE bin_id='1240' AND source_name='4FGL J1204.8+0407' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sat Sep  4 23:31:10 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0052>
Subject: Job 311734: <4FGL_J1204.8+0407_daily_bin1240> in cluster <slac> Done

Job <4FGL_J1204.8+0407_daily_bin1240> was submitted from host <rhel6-64j> by user <kocevski> in cluster <slac> at Sat Sep  4 23:20:22 2021
Job was executed on host(s) <bullet0052>, in queue <medium>, as user <kocevski> in cluster <slac> at Sat Sep  4 23:20:24 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:24 2021
Terminated at Sat Sep  4 23:31:12 2021
Results reported at Sat Sep  4 23:31:12 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1204.8+0407_daily_bin1240 181.203 4.12 560736001 560995201 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 :                                   506.00 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             314.29 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   647 sec.
    Turnaround time :                            650 sec.

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

