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


Performing analysis on: 4FGL_J1304.0+3704_daily_bin759
RA = 196.008, Dec = 37.071
tmin = 436060801, tmax = 436320001
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='190796', job_status='RUN', time_executed='2021-09-06 19:50:49.872657', time_epoch_executed='1630983049.87' WHERE source_name='4FGL J1304.0+3704' and cadence='daily' and bin_id='759'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/190796

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/190796/ft1_4FGL_J1304.0+3704_daily_bin759.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/190796/ft2_4FGL_J1304.0+3704_daily_bin759.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/190796/ft1_4FGL_J1304.0+3704_daily_bin759.fits outfile=/scratch/kocevski/190796/ft1_filteredMKT_4FGL_J1304.0+3704_daily_bin759.fits ra=196.008 dec=37.071 rad=12.0 tmin=436060801.0 tmax=436320001.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 5.77
user 5.47
sys 0.25

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

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

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

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/190796/ft1_filtered_4FGL_J1304.0+3704_daily_bin759.fits evtable="EVENTS" scfile=/scratch/kocevski/190796/ft2_4FGL_J1304.0+3704_daily_bin759.fits sctable="SC_DATA" expcube=/scratch/kocevski/190796/ltcube_436060801_436320001_4FGL_J1304.0+3704_daily_bin759.fits outfile=/scratch/kocevski/190796/expmap_436060801_436320001_4FGL_J1304.0+3704_daily_bin759.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/190796/ltcube_436060801_436320001_4FGL_J1304.0+3704_daily_bin759.fits
.....................!
real 192.96
user 186.86
sys 5.60

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/190796/ft1_filtered_4FGL_J1304.0+3704_daily_bin759.fits scfile=/scratch/kocevski/190796/ft2_4FGL_J1304.0+3704_daily_bin759.fits outfile=/scratch/kocevski/190796/cmap_436060801_436320001_4FGL_J1304.0+3704_daily_bin759.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.55
user 0.37
sys 0.16

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/190796/ft1_filtered_4FGL_J1304.0+3704_daily_bin759.fits scfile=/scratch/kocevski/190796/ft2_4FGL_J1304.0+3704_daily_bin759.fits outfile=/scratch/kocevski/190796/cmap_HighResolution_436060801_436320001_4FGL_J1304.0+3704_daily_bin759.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.56
user 0.40
sys 0.14

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

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/190796/ft1_filtered_4FGL_J1304.0+3704_daily_bin759.fits', '/scratch/kocevski/190796/ft2_4FGL_J1304.0+3704_daily_bin759.fits', expMap='/scratch/kocevski/190796/expmap_436060801_436320001_4FGL_J1304.0+3704_daily_bin759.fits', expCube='/scratch/kocevski/190796/ltcube_436060801_436320001_4FGL_J1304.0+3704_daily_bin759.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/190796/Model_4FGL_J1304.0+3704_daily_bin759.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/190796/ft1_filtered_4FGL_J1304.0+3704_daily_bin759.fits
Spacecraft file(s): /scratch/kocevski/190796/ft2_4FGL_J1304.0+3704_daily_bin759.fits
Exposure map: /scratch/kocevski/190796/expmap_436060801_436320001_4FGL_J1304.0+3704_daily_bin759.fits
Exposure cube: /scratch/kocevski/190796/ltcube_436060801_436320001_4FGL_J1304.0+3704_daily_bin759.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/190796/Model_4FGL_J1304.0+3704_daily_bin759.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) = 4307.38849451

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    6.8368       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .34670E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10327E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    11.771       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10053E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10006E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    4.6573       1.0000         .10000E-03   10000.    
     9 'norm      '    6.1896       1.0000         .10000E-03   10000.    
    10 'Prefactor '    4.6846       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10020E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    27.640       1.0000         .10000E-03   10000.    
    13 'norm      '    .10126E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    .10547E-03   1.0000         .10000E-03   10000.    
    15 'norm      '    .10007E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    .10082E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    6.5333       1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10119E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    31.009       1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10030E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    22.841       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .35346       1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10019E-03   1.0000         .10000E-03   10000.    
    25 'Prefactor '    128.32       1.0000         .10000E-03   10000.    
    26 'norm      '    4.0352       1.0000         .10000E-03   10000.    
    27 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    28 'norm      '    .10021E-03   1.0000         .10000E-03   10000.    
    29 'Normalizat'    .95606       1.0000         .10000E-01   10.000    
    30 'Prefactor '    1.0991       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5990E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   4307.366     FROM MIGRAD    STATUS=CONVERGED    152 CALLS     3386 TOTAL
                     EDM=   .11E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  3.5%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          6.8374        4.0915        .15684E-06   -.24717E-04
   2  Prefactor     .10094E-03    4.2805       -.22085E-05** at limit **
   3  Prefactor     .10000E-03    2.3110        .71275E-07** at limit **
   4  Prefactor     11.771        1.1042        .61479E-07    .20447E-03
   5  Prefactor     .10000E-03    9.2649        .34846E-07** at limit **
   6  Prefactor     .10033E-03    19.587        .52367E-05** at limit **
   7  Prefactor     .10009E-03    28.957       -.11784E-04** at limit **
   8  Prefactor     4.6587        1.3314       -.15757E-06    .21269E-03
   9  norm          6.1883        4.8115       -.88650E-06    .13288E-03
  10  Prefactor     4.5341        9.5809       -.23300E-05   -.27253E-03
  11  Prefactor     .10000E-03    12.334       -.24130E-05** at limit **
  12  Prefactor     27.607        12.988        .75239E-06   -.48480E-02
  13  norm          .10000E-03    4.8373       -.25094E-06** at limit **
  14  norm          .10013E-03    11.081        .15626E-05** at limit **
  15  norm          .10000E-03    2.5471        .13301E-06** at limit **
  16  norm          .10000E-03    2.7359        .24178E-07** at limit **
  17  norm          .10000E-03    5.8811       -.79280E-06** at limit **
  18  Prefactor     6.5342        5.1610       -.45125E-06   -.17787E-02
  19  Prefactor     .10467E-03    42.600        .72066E-06** at limit **
  20  Prefactor     31.086        14.873        .16220E-05   -.10220E-01
  21  Prefactor     .10594E-03    46.331        .77081E-05** at limit **
  22  Prefactor     22.833        2.1083        .66886E-07   -.32769E-03
  23  Prefactor     .11306E-03    1355.5       -.40129E-04** at limit **
  24  Prefactor     .10010E-03    9.7778        .18218E-05** at limit **
  25  Prefactor     128.28        4.9741       -.28272E-06    .84246E-02
  26  norm          4.0363        2.0556        .14054E-06    .83377E-04
  27  Prefactor     .10000E-03    2.1840        .58486E-06** at limit **
  28  norm          .10000E-03    8.2999       -.30775E-06** at limit **
  29  Normalizat    .95680        .25048       -.12046E-05   -.20946E-04
  30  Prefactor     1.0983        .30590        .10391E-05   -.62374E-05
                               ERR DEF=  .500    
Final values: 
  norm       = 6.83737
  Prefactor  = 0.000100941
  Prefactor  = 0.0001
  Prefactor  = 11.771
  Prefactor  = 0.0001
  Prefactor  = 0.000100331
  Prefactor  = 0.000100087
  Prefactor  = 4.65874
  norm       = 6.18831
  Prefactor  = 4.53406
  Prefactor  = 0.0001
  Prefactor  = 27.6067
  norm       = 0.0001
  norm       = 0.000100128
  norm       = 0.0001
  norm       = 0.0001
  norm       = 0.0001
  Prefactor  = 6.53418
  Prefactor  = 0.000104675
  Prefactor  = 31.0855
  Prefactor  = 0.000105936
  Prefactor  = 22.833
  Prefactor  = 0.000113056
  Prefactor  = 0.000100102
  Prefactor  = 128.275
  norm       = 4.03631
  Prefactor  = 0.0001
  norm       = 0.0001
  Normalizat = 0.9568
  Prefactor  = 1.09831
 **********
 **   18 **HESSE 
 **********

 FCN=   4307.366     FROM HESSE     STATUS=OK           660 CALLS     4046 TOTAL
                     EDM=   .15E-05    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          6.8374        4.2869        .38362E-02   -1.5185    
   2  Prefactor     .10094E-03    9.2255        .65047E-01   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10000E-03    1.4348        .42924E-01   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     11.771        11.660        .29191E-02   -1.5022    
   5  Prefactor     .10000E-03    9.3114        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10033E-03    20.143        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10009E-03    29.370        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     4.6587        6.9179        .46621E-02   -1.5276    
   9  norm          6.1883        4.8204        .40340E-02   -1.5210    
  10  Prefactor     4.5341        199.64        .46482E-02   -1.5282    
  11  Prefactor     .10000E-03    12.325        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     27.607        27.887        .19050E-02   -1.4657    
  13  norm          .10000E-03    4.8079        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          .10013E-03    20.970        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  norm          .10000E-03    2.5172        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          .10000E-03    2.7340        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          .10000E-03    5.6638        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     6.5342        5.2422        .39252E-02   -1.5197    
  19  Prefactor     .10467E-03    50.639        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     31.086        40.863        .17988E-02   -1.4592    
  21  Prefactor     .10594E-03    56.169        .90712E-02   -1.5707    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     22.833        21.238        .20953E-02   -1.4752    
  23  Prefactor     .11306E-03    56.000        .13977       -1.5709    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     .10010E-03    20.941        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     128.28        111.78        .88850E-03   -1.3438    
  26  norm          4.0363        2.0684        .50185E-02   -1.5306    
  27  Prefactor     .10000E-03    2.1801        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  norm          .10000E-03    8.2772        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  29  Normalizat    .95680        .21637        .45614E-01   -.94492    
  30  Prefactor     1.0983        .25470        .64455E-01   -.89521    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.52408e-06
Minuit parameter uncertainties:
  1  4.28705
  2  0.00589455
  3  8.55356e-07
  4  11.662
  5  1.19673e-05
  6  0.00516646
  7  0.00320318
  8  6.91913
  9  4.82071
  10  60.3881
  11  9.67055e-05
  12  27.9006
  13  1.12472e-06
  14  0.00327173
  15  2.13838e-06
  16  1.30671e-06
  17  1.99307e-05
  18  5.24261
  19  0.0307969
  20  40.9002
  21  0.0365547
  22  21.2449
  23  0.0541301
  24  0.00292921
  25  111.97
  26  2.06848
  27  7.00985e-06
  28  1.61676e-05
  29  0.216567
  30  0.254978
Done.

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

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  2.761e+01  2.790e+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:  1.098e+00  2.550e-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.568e-01  2.166e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 1.45
Ra Dec: 196.008 37.071
Photon Index (Fixed Index): 2.44 +/- 0.00
Photon Flux (Fixed Index): 5.66e-08 +/- 5.72e-08
Energy Flux (Fixed Index): 1.77e-05 +/- 1.79e-05

TS (Fixed Index): 1.45
Ra Dec: 196.008 37.071
Photon Flux Upper Limit: 1.71e-07 ph cm-2 s-1
Energy Flux Upper Limit: 1.33e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/190796/likelihoodResults_436060801_436320001_4FGL_J1304.0+3704_daily_bin759.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) = 4307.12287809
delta logL = 0.243525963342

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 4307.1039308
delta logL = 0.262473251662

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    15.532       1.0000         .10000E-03   10000.    
     2 'Index     '    2.9989       1.0000          .0000       10.000    
     3 'Normalizat'    .92038       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.1292       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.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   4307.104     FROM MIGRAD    STATUS=CONVERGED     81 CALLS      273 TOTAL
                     EDM=   .24E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     15.527        29.397        .10163E-03   -.28895E-03
   2  Index         2.9991        1.0360        .47675E-02   -.13127E-03
   3  Normalizat    .92035        .25655        .25001E-03   -.26336E-03
   4  Prefactor     1.1292        .31112        .28167E-03   -.17985E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 15.5272
  Index      = 2.99911
  Normalizat = 0.920353
  Prefactor  = 1.12919
 **********
 **   18 **HESSE 
 **********

 FCN=   4307.104     FROM HESSE     STATUS=OK            25 CALLS      298 TOTAL
                     EDM=   .27E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     15.527        24.204        .40651E-05   -1.4920    
   2  Index         2.9991        .85397        .19070E-03   -.41171    
   3  Normalizat    .92035        .25633        .50001E-04   -.95749    
   4  Prefactor     1.1292        .31050        .56334E-04   -.88539    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.72453e-10
Minuit parameter uncertainties:
  1  24.2193
  2  0.858993
  3  0.256675
  4  0.311002
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/190796': 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) = 4307.10393076
delta logL = 0.262473286024

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  1.553e+01  2.422e+01  1.000e-04  1.000e+04 ( 1.000e-13)
314        Index:  2.999e+00  8.590e-01  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:  1.129e+00  3.110e-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.204e-01  2.567e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 2.02
Ra Dec: 196.008 37.071
Photon Index (Free Index): 3.00 +/- 0.86
Photon Flux (Free Index): 8.53e-08 +/- 7.26e-08
Energy Flux (Free Index): 1.70e-05 +/- 1.42e-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/190796/cmap_HighResolution_436060801_436320001_4FGL_J1304.0+3704_daily_bin759.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='1.33e-02', comment='SUCCESS', photon_flux='5.66e-08', energy_flux2='1.70e-05', photon_flux_error='5.72e-08', dlogl='2.62e-01', energy_flux='1.77e-05', photon_flux2='8.53e-08', job_status='DONE', time_completed='2021-09-06 20:02:18.204937', photon_index_error2='0.86', photon_index2='3.00', ts='1.45', fit_tolerance='1e-08', GAL='1.10', photon_index_error='0.00', photon_flux_upper_limit='1.71e-07', energy_flux_error2='1.42e-05', EG='0.96', time_epoch_completed='1630983738.21', return_code='0', job_id='190796', GAL2='1.13', EG2='0.92', return_code2='0', energy_flux_error='1.79e-05', photon_flux_error2='7.26e-08', ts2='2.02', photon_index='2.44' WHERE bin_id='759' AND source_name='4FGL J1304.0+3704' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 20:02:18 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0276>
Subject: Job 190796: <4FGL_J1304.0+3704_daily_bin759> in cluster <slac> Done

Job <4FGL_J1304.0+3704_daily_bin759> was submitted from host <rhel6-64j> by user <kocevski> in cluster <slac> at Mon Sep  6 19:50:21 2021
Job was executed on host(s) <bullet0276>, in queue <medium>, as user <kocevski> in cluster <slac> at Mon Sep  6 19:50:37 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:50:37 2021
Terminated at Mon Sep  6 20:02:18 2021
Results reported at Mon Sep  6 20:02:18 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1304.0+3704_daily_bin759 196.008 37.071 436060801 436320001 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 :                                   685.43 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             378.64 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   701 sec.
    Turnaround time :                            717 sec.

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

