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


Performing analysis on: 4FGL_J1304.0+3704_daily_bin216
RA = 196.008, Dec = 37.071
tmin = 295315201, tmax = 295574401
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='186656', job_status='RUN', time_executed='2021-09-06 19:38:15.716669', time_epoch_executed='1630982295.72' WHERE source_name='4FGL J1304.0+3704' and cadence='daily' and bin_id='216'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/186656

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/186656/ft1_4FGL_J1304.0+3704_daily_bin216.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/186656/ft2_4FGL_J1304.0+3704_daily_bin216.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/186656/ft1_4FGL_J1304.0+3704_daily_bin216.fits outfile=/scratch/kocevski/186656/ft1_filteredMKT_4FGL_J1304.0+3704_daily_bin216.fits ra=196.008 dec=37.071 rad=12.0 tmin=295315201.0 tmax=295574401.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.39
user 2.17
sys 0.19

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/186656/ft2_4FGL_J1304.0+3704_daily_bin216.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/186656/ft2_4FGL_J1304.0+3704_daily_bin216.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/186656/ft1_filteredMKT_4FGL_J1304.0+3704_daily_bin216.fits evtable="EVENTS" outfile="/scratch/kocevski/186656/ft1_filtered_4FGL_J1304.0+3704_daily_bin216.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.53
user 0.35
sys 0.16

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/186656/ft1_filtered_4FGL_J1304.0+3704_daily_bin216.fits" evtable="EVENTS" scfile=/scratch/kocevski/186656/ft2_4FGL_J1304.0+3704_daily_bin216.fits sctable="SC_DATA" outfile=/scratch/kocevski/186656/ltcube_295315201_295574401_4FGL_J1304.0+3704_daily_bin216.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/186656/ft2_4FGL_J1304.0+3704_daily_bin216.fits
.....................!
real 17.27
user 16.82
sys 0.34

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/186656/ft1_filtered_4FGL_J1304.0+3704_daily_bin216.fits evtable="EVENTS" scfile=/scratch/kocevski/186656/ft2_4FGL_J1304.0+3704_daily_bin216.fits sctable="SC_DATA" expcube=/scratch/kocevski/186656/ltcube_295315201_295574401_4FGL_J1304.0+3704_daily_bin216.fits outfile=/scratch/kocevski/186656/expmap_295315201_295574401_4FGL_J1304.0+3704_daily_bin216.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/186656/ltcube_295315201_295574401_4FGL_J1304.0+3704_daily_bin216.fits
.....................!
real 191.86
user 186.16
sys 4.71

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

Setting source of interest to:
4FGL J1304.0+3704 @ 196.008 37.071

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/186656/ft1_filtered_4FGL_J1304.0+3704_daily_bin216.fits scfile=/scratch/kocevski/186656/ft2_4FGL_J1304.0+3704_daily_bin216.fits outfile=/scratch/kocevski/186656/cmap_295315201_295574401_4FGL_J1304.0+3704_daily_bin216.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=196.008 yref=37.071 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.66
user 0.39
sys 0.16

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/186656/ft1_filtered_4FGL_J1304.0+3704_daily_bin216.fits scfile=/scratch/kocevski/186656/ft2_4FGL_J1304.0+3704_daily_bin216.fits outfile=/scratch/kocevski/186656/cmap_HighResolution_295315201_295574401_4FGL_J1304.0+3704_daily_bin216.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=196.008 yref=37.071 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.39
sys 0.14

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/186656/ft1_filtered_4FGL_J1304.0+3704_daily_bin216.fits evtable="EVENTS" scfile=/scratch/kocevski/186656/ft2_4FGL_J1304.0+3704_daily_bin216.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/186656/Model_4FGL_J1304.0+3704_daily_bin216.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/186656/ft1_filtered_4FGL_J1304.0+3704_daily_bin216.fits.....................!
real 44.40
user 43.00
sys 1.20

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/186656/ft1_filtered_4FGL_J1304.0+3704_daily_bin216.fits', '/scratch/kocevski/186656/ft2_4FGL_J1304.0+3704_daily_bin216.fits', expMap='/scratch/kocevski/186656/expmap_295315201_295574401_4FGL_J1304.0+3704_daily_bin216.fits', expCube='/scratch/kocevski/186656/ltcube_295315201_295574401_4FGL_J1304.0+3704_daily_bin216.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/186656/Model_4FGL_J1304.0+3704_daily_bin216.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1304.0+3704'

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  2.111e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
314        Index:  2.436e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
315        Scale:  1.032e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/186656/ft1_filtered_4FGL_J1304.0+3704_daily_bin216.fits
Spacecraft file(s): /scratch/kocevski/186656/ft2_4FGL_J1304.0+3704_daily_bin216.fits
Exposure map: /scratch/kocevski/186656/expmap_295315201_295574401_4FGL_J1304.0+3704_daily_bin216.fits
Exposure cube: /scratch/kocevski/186656/ltcube_295315201_295574401_4FGL_J1304.0+3704_daily_bin216.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/186656/Model_4FGL_J1304.0+3704_daily_bin216.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) = 5272.2300947

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    .10040E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    3.1176       1.0000         .10000E-03   10000.    
     3 'Prefactor '    6.3909       1.0000         .10000E-03   10000.    
     4 'Prefactor '    19.863       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10011E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    3.4011       1.0000         .10000E-03   10000.    
     9 'norm      '    4.8283       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10010E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    20.958       1.0000         .10000E-03   10000.    
    12 'Prefactor '    15.061       1.0000         .10000E-03   10000.    
    13 'norm      '    4.9993       1.0000         .10000E-03   10000.    
    14 'norm      '    23.728       1.0000         .10000E-03   10000.    
    15 'norm      '    .10097E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    16.468       1.0000         .10000E-03   10000.    
    17 'norm      '    25.634       1.0000         .10000E-03   10000.    
    18 'Prefactor '    5.8130       1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10008E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    11.750       1.0000         .10000E-03   10000.    
    22 'Prefactor '    8.1539       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10010E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    12.058       1.0000         .10000E-03   10000.    
    25 'Prefactor '    43.429       1.0000         .10000E-03   10000.    
    26 'norm      '    .10008E-03   1.0000         .10000E-03   10000.    
    27 'Prefactor '    17.441       1.0000         .10000E-03   10000.    
    28 'norm      '    5.5363       1.0000         .10000E-03   10000.    
    29 'Normalizat'    1.0154       1.0000         .10000E-01   10.000    
    30 'Prefactor '    .82691       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5990E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   5272.212     FROM MIGRAD    STATUS=CONVERGED    745 CALLS     3852 TOTAL
                     EDM=   .11E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .3%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .10000E-03    1.8358       -.15577E-07** at limit **
   2  Prefactor     3.1174        5.1043       -.37936E-06   -.21852E-03
   3  Prefactor     6.3905        2.9097       -.62579E-07    .30645E-04
   4  Prefactor     19.864        10.564       -.12194E-06    .15157E-04
   5  Prefactor     .10000E-03    16.019       -.13253E-06** at limit **
   6  Prefactor     .10000E-03    7.9161        .81397E-07** at limit **
   7  Prefactor     .10000E-03    37.253        .49613E-05** at limit **
   8  Prefactor     3.4043        5.5389       -.80567E-07   -.19804E-03
   9  norm          4.8293        5.4398        .73712E-06   -.13132E-03
  10  Prefactor     .10000E-03    25.202        .20353E-05** at limit **
  11  Prefactor     20.949        33.451       -.70046E-05   -.92916E-05
  12  Prefactor     15.043        24.953       -.80308E-05   -.94494E-05
  13  norm          5.0020        6.3220        .92005E-06   -.10054E-03
  14  norm          23.727        18.403       -.14247E-06    .51349E-05
  15  norm          .10000E-03    4.1746        .12435E-06** at limit **
  16  norm          16.467        8.0290        .34957E-06    .46765E-05
  17  norm          25.633        7.5465       -.34989E-06    .74430E-04
  18  Prefactor     5.8139        4.1722        .17173E-05    .55701E-04
  19  Prefactor     .10000E-03    5.1693        .11160E-06** at limit **
  20  Prefactor     .10000E-03    32.606       -.73129E-05** at limit **
  21  Prefactor     11.727        63.985       -.50684E-04   -.35135E-05
  22  Prefactor     8.1517        17.016       -.26603E-05   -.46276E-04
  23  Prefactor     .10000E-03    65.374        .25963E-05** at limit **
  24  Prefactor     12.064        28.248        .50459E-05   -.20105E-05
  25  Prefactor     43.434        88.218        .62223E-05    .13188E-04
  26  norm          .10000E-03    .55590       -.27558E-07** at limit **
  27  Prefactor     17.442        6.6213        .18496E-06    .28747E-04
  28  norm          5.5360        13.233       -.10472E-05   -.60161E-04
  29  Normalizat    1.0152        .18702        .24701E-05   -.47604E-04
  30  Prefactor     .82725        .21659        .14781E-06    .74618E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 0.0001
  Prefactor  = 3.11743
  Prefactor  = 6.39047
  Prefactor  = 19.8635
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 3.40429
  norm       = 4.82926
  Prefactor  = 0.0001
  Prefactor  = 20.9491
  Prefactor  = 15.0426
  norm       = 5.00203
  norm       = 23.7269
  norm       = 0.0001
  norm       = 16.4671
  norm       = 25.6334
  Prefactor  = 5.81391
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 11.7267
  Prefactor  = 8.1517
  Prefactor  = 0.0001
  Prefactor  = 12.0643
  Prefactor  = 43.4341
  norm       = 0.0001
  Prefactor  = 17.4417
  norm       = 5.53599
  Normalizat = 1.01517
  Prefactor  = 0.827247
 **********
 **   18 **HESSE 
 **********

 FCN=   5272.212     FROM HESSE     STATUS=OK           594 CALLS     4446 TOTAL
                     EDM=   .25E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          .10000E-03    1.8504        .95864E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     3.1174        5.0935        .20364E-03   -1.5355    
   3  Prefactor     6.3905        2.9035        .80913E-04   -1.5202    
   4  Prefactor     19.864        10.568        .89868E-04   -1.4816    
   5  Prefactor     .10000E-03    16.066        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    7.9227        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10000E-03    37.270        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     3.4043        5.5053        .20182E-03   -1.5339    
   9  norm          4.8293        5.4116        .14825E-03   -1.5268    
  10  Prefactor     .10000E-03    25.212        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     20.949        33.292        .87491E-04   -1.4792    
  12  Prefactor     15.043        24.882        .10321E-03   -1.4932    
  13  norm          5.0020        6.2857        .17986E-03   -1.5261    
  14  norm          23.727        18.409        .82233E-04   -1.4733    
  15  norm          .10000E-03    4.2247        .28658E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          16.467        7.9587        .98695E-04   -1.4896    
  17  norm          25.633        7.5491        .79122E-04   -1.4695    
  18  Prefactor     5.8139        4.1657        .11260E-03   -1.5226    
  19  Prefactor     .10000E-03    5.1758        .16120E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .10000E-03    32.687        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     11.727        63.990        .11687E-03   -1.5023    
  22  Prefactor     8.1517        16.991        .14040E-03   -1.5137    
  23  Prefactor     .10000E-03    65.780        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     12.064        28.144        .11536E-03   -1.5013    
  25  Prefactor     43.434        89.533        .60833E-04   -1.4389    
  26  norm          .10000E-03    .57311        .10568E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  Prefactor     17.442        6.6270        .95903E-04   -1.4872    
  28  norm          5.5360        13.229        .17075E-03   -1.5237    
  29  Normalizat    1.0152        .22439        .22792E-03   -.92524    
  30  Prefactor     .82725        .25693        .31072E-03   -.98732    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.51116e-10
Minuit parameter uncertainties:
  1  1.0216e-06
  2  5.09424
  3  2.90353
  4  10.5687
  5  1.23051e-05
  6  1.37596e-05
  7  4.51682e-06
  8  5.50614
  9  5.41217
  10  9.95928e-06
  11  33.3214
  12  24.8996
  13  6.28658
  14  18.4134
  15  1.96083e-05
  16  7.95919
  17  7.54943
  18  4.16595
  19  2.87303e-05
  20  1.98822e-05
  21  54.8772
  22  17.0009
  23  9.6883e-05
  24  28.1748
  25  89.8114
  26  2.76515e-06
  27  6.62732
  28  13.2363
  29  0.224603
  30  0.2573
Done.

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

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  1.504e+01  2.490e+01  1.000e-04  1.000e+04 ( 1.000e-13)
314        Index:  2.436e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
315        Scale:  1.032e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
596    Prefactor:  8.272e-01  2.573e-01  0.000e+00  1.000e+01 ( 1.000e+00)
597        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
598        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
595   Normalization:  1.015e+00  2.246e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.51
Ra Dec: 196.008 37.071
Photon Flux Upper Limit: 1.26e-07 ph cm-2 s-1
Energy Flux Upper Limit: 9.78e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/186656/likelihoodResults_295315201_295574401_4FGL_J1304.0+3704_daily_bin216.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) = 5270.40126097
delta logL = 1.81067672569

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 5270.31965643
delta logL = 1.89228127064

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .45346       1.0000         .10000E-03   10000.    
     2 'Index     '    4.8967       1.0000          .0000       10.000    
     3 'Normalizat'    .91223       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .91579       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5990E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   5270.320     FROM MIGRAD    STATUS=CONVERGED     54 CALLS      280 TOTAL
                     EDM=   .21E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .45286        3.9600        .59841E-02    .67166E-03
   2  Index         4.8978        2.4010        .83524E-01    .14477E-03
   3  Normalizat    .91214        .53651E-01    .45058E-01    .97997E-05
   4  Prefactor     .91592        .66878E-01    .67109E-01    .13354E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.452856
  Index      = 4.89775
  Normalizat = 0.912138
  Prefactor  = 0.915921
 **********
 **   18 **HESSE 
 **********

 FCN=   5270.320     FROM HESSE     STATUS=NOT POSDEF    33 CALLS      313 TOTAL
                     EDM=   .22E-06    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .45286        7.2840        .26884E-04   -1.5573    
   2  Index         4.8978        3.4313        .33824E-02   -.20451E-01
   3  Normalizat    .91214        .18710        .23829E-03   -.96035    
   4  Prefactor     .91592        .22902        .29685E-03   -.95587    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 2.21976e-07
Minuit parameter uncertainties:
  1  3.63253
  2  3.78185
  3  0.187229
  4  0.22926
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/186656': 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): 102
logL (Free Index) = 5270.3196549
delta logL = 1.89228279736

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  4.529e-01  3.633e+00  1.000e-04  1.000e+04 ( 1.000e-13)
314        Index:  4.898e+00  3.782e+00  0.000e+00  1.000e+01 (-1.000e+00)
315        Scale:  1.032e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
596    Prefactor:  9.159e-01  2.293e-01  0.000e+00  1.000e+01 ( 1.000e+00)
597        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
598        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
595   Normalization:  9.121e-01  1.872e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 4.59
Ra Dec: 196.008 37.071
Photon Index (Free Index): 4.90 +/- 3.78
Photon Flux (Free Index): 1.08e-07 +/- 6.31e-08
Energy Flux (Free Index): 1.44e-05 +/- 1.07e-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/186656/cmap_HighResolution_295315201_295574401_4FGL_J1304.0+3704_daily_bin216.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='9.78e-03', comment='SUCCESS', energy_flux2='1.44e-05', dlogl='1.89e+00', photon_flux2='1.08e-07', job_status='DONE', time_completed='2021-09-06 19:51:52.313211', photon_index_error2='3.78', photon_index2='4.90', ts='0.51', fit_tolerance='1e-08', GAL='0.83', photon_index_error='0.00', photon_flux_upper_limit='1.26e-07', energy_flux_error2='1.07e-05', EG='1.02', time_epoch_completed='1630983112.31', return_code='0', job_id='186656', GAL2='0.92', EG2='0.91', return_code2='102', photon_flux_error2='6.31e-08', ts2='4.59', photon_index='2.44' WHERE bin_id='216' AND source_name='4FGL J1304.0+3704' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 19:51:52 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0096>
Subject: Job 186656: <4FGL_J1304.0+3704_daily_bin216> in cluster <slac> Done

Job <4FGL_J1304.0+3704_daily_bin216> was submitted from host <rhel6-64h> by user <kocevski> in cluster <slac> at Mon Sep  6 19:35:37 2021
Job was executed on host(s) <bullet0096>, in queue <medium>, as user <kocevski> in cluster <slac> at Mon Sep  6 19:35:39 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Mon Sep  6 19:35:39 2021
Terminated at Mon Sep  6 19:51:52 2021
Results reported at Mon Sep  6 19:51:52 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1304.0+3704_daily_bin216 196.008 37.071 295315201 295574401 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1304.0+3704 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   812.37 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             294.03 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   982 sec.
    Turnaround time :                            975 sec.

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

