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


Performing analysis on: 4FGL_J1304.0+3704_daily_bin508
RA = 196.008, Dec = 37.071
tmin = 371001601, tmax = 371260801
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='189369', job_status='RUN', time_executed='2021-09-06 19:48:08.021421', time_epoch_executed='1630982888.02' WHERE source_name='4FGL J1304.0+3704' and cadence='daily' and bin_id='508'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/189369

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

Retrieving the FT1 file...

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

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

Retrieving 50 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/189369/ft1_4FGL_J1304.0+3704_daily_bin508.fits


Retrieving the FT1 file...

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

Retrieving 50 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/189369/ft2_4FGL_J1304.0+3704_daily_bin508.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/189369/ft1_4FGL_J1304.0+3704_daily_bin508.fits outfile=/scratch/kocevski/189369/ft1_filteredMKT_4FGL_J1304.0+3704_daily_bin508.fits ra=196.008 dec=37.071 rad=12.0 tmin=371001601.0 tmax=371260801.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 6.42
user 6.16
sys 0.23

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

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

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/189369/ft1_filtered_4FGL_J1304.0+3704_daily_bin508.fits" evtable="EVENTS" scfile=/scratch/kocevski/189369/ft2_4FGL_J1304.0+3704_daily_bin508.fits sctable="SC_DATA" outfile=/scratch/kocevski/189369/ltcube_371001601_371260801_4FGL_J1304.0+3704_daily_bin508.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/189369/ft2_4FGL_J1304.0+3704_daily_bin508.fits
.....................!
real 13.98
user 13.61
sys 0.32

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/189369/ft1_filtered_4FGL_J1304.0+3704_daily_bin508.fits evtable="EVENTS" scfile=/scratch/kocevski/189369/ft2_4FGL_J1304.0+3704_daily_bin508.fits sctable="SC_DATA" expcube=/scratch/kocevski/189369/ltcube_371001601_371260801_4FGL_J1304.0+3704_daily_bin508.fits outfile=/scratch/kocevski/189369/expmap_371001601_371260801_4FGL_J1304.0+3704_daily_bin508.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/189369/ltcube_371001601_371260801_4FGL_J1304.0+3704_daily_bin508.fits
.....................!
real 192.20
user 186.22
sys 5.58

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/189369/ft1_filtered_4FGL_J1304.0+3704_daily_bin508.fits scfile=/scratch/kocevski/189369/ft2_4FGL_J1304.0+3704_daily_bin508.fits outfile=/scratch/kocevski/189369/cmap_371001601_371260801_4FGL_J1304.0+3704_daily_bin508.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.57
user 0.41
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/189369/ft1_filtered_4FGL_J1304.0+3704_daily_bin508.fits scfile=/scratch/kocevski/189369/ft2_4FGL_J1304.0+3704_daily_bin508.fits outfile=/scratch/kocevski/189369/cmap_HighResolution_371001601_371260801_4FGL_J1304.0+3704_daily_bin508.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.58
user 0.42
sys 0.15

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

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

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    .70458       1.0000         .10000E-03   10000.    
     2 'Prefactor '    13.371       1.0000         .10000E-03   10000.    
     3 'Prefactor '    4.7799       1.0000         .10000E-03   10000.    
     4 'Prefactor '    8.5360       1.0000         .10000E-03   10000.    
     5 'Prefactor '    4.2712       1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    6.2380       1.0000         .10000E-03   10000.    
     9 'norm      '    .39248E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    61.866       1.0000         .10000E-03   10000.    
    11 'Prefactor '    1.4319       1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    13 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    .10012E-03   1.0000         .10000E-03   10000.    
    15 'norm      '    15.019       1.0000         .10000E-03   10000.    
    16 'norm      '    .37812E-02   1.0000         .10000E-03   10000.    
    17 'norm      '    2.4411       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10029E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    2.7996       1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    43.982       1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    25 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    26 'norm      '    7.6086       1.0000         .10000E-03   10000.    
    27 'Prefactor '    4.8712       1.0000         .10000E-03   10000.    
    28 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
    29 'Normalizat'    1.0167       1.0000         .10000E-01   10.000    
    30 'Prefactor '    1.1173       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=   5728.750     FROM MIGRAD    STATUS=CONVERGED    750 CALLS     3904 TOTAL
                     EDM=   .65E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  4.2%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .69393        11.537       -.37841E-05    .36450E-04
   2  Prefactor     13.371        9.6205        .66330E-07    .12093E-03
   3  Prefactor     4.7873        5.2021        .20500E-05   -.35215E-03
   4  Prefactor     8.5362        11.183        .87665E-06   -.20651E-03
   5  Prefactor     4.2529        69.075       -.85269E-05   -.11554E-03
   6  Prefactor     .10000E-03    12.590        .54686E-06** at limit **
   7  Prefactor     .10000E-03    28.666        .22127E-05** at limit **
   8  Prefactor     6.2382        6.2364        .60032E-06   -.58037E-03
   9  norm          .10000E-03    3.7410       -.52859E-07** at limit **
  10  Prefactor     61.860        49.889       -.10168E-05   -.97272E-04
  11  Prefactor     1.4542        63.996        .23175E-05   -.15748E-04
  12  Prefactor     .10000E-03    5.9623       -.32631E-06** at limit **
  13  norm          .10000E-03    1.4972       -.34292E-08** at limit **
  14  norm          .10000E-03    5.6024        .11247E-06** at limit **
  15  norm          15.016        7.0427        .10596E-06   -.43265E-03
  16  norm          .10001E-03    11.412        .67532E-07** at limit **
  17  norm          2.4393        5.1821        .49562E-06   -.78355E-04
  18  Prefactor     .10000E-03    1.8156       -.43886E-08** at limit **
  19  Prefactor     .10000E-03    4.1946       -.86405E-08** at limit **
  20  Prefactor     .10000E-03    23.423       -.22766E-05** at limit **
  21  Prefactor     2.7975        58.667       -.17070E-06   -.21974E-04
  22  Prefactor     .10000E-03    7.4731       -.95809E-07** at limit **
  23  Prefactor     43.978        47.223       -.93810E-06   -.48569E-04
  24  Prefactor     .10000E-03    9.6810       -.33790E-06** at limit **
  25  Prefactor     .10000E-03    48.115       -.55382E-06** at limit **
  26  norm          7.6082        2.4068        .12875E-07    .29877E-04
  27  Prefactor     4.8691        8.7069        .51674E-07   -.66569E-04
  28  norm          .10000E-03    6.9465        .36418E-06** at limit **
  29  Normalizat    1.0169        .19150        .76160E-06    .12054E-03
  30  Prefactor     1.1172        .22702       -.76955E-06    .18506E-03
                               ERR DEF=  .500    
Final values: 
  norm       = 0.693927
  Prefactor  = 13.3713
  Prefactor  = 4.78727
  Prefactor  = 8.53615
  Prefactor  = 4.25288
  Prefactor  = 0.0001
  Prefactor  = 0.000100002
  Prefactor  = 6.23817
  norm       = 0.000100002
  Prefactor  = 61.8598
  Prefactor  = 1.4542
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 0.0001
  norm       = 15.0163
  norm       = 0.000100014
  norm       = 2.4393
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.000100002
  Prefactor  = 2.79752
  Prefactor  = 0.0001
  Prefactor  = 43.9775
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 7.60818
  Prefactor  = 4.86905
  norm       = 0.0001
  Normalizat = 1.01689
  Prefactor  = 1.11716
 **********
 **   18 **HESSE 
 **********

 FCN=   5728.750     FROM HESSE     STATUS=OK           588 CALLS     4492 TOTAL
                     EDM=   .25E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          .69393        33.498        .28884E-02   -1.5541    
   2  Prefactor     13.371        9.6146        .10954E-03   -1.4976    
   3  Prefactor     4.7873        6.7388        .55234E-03   -1.5270    
   4  Prefactor     8.5362        11.236        .68603E-03   -1.5124    
   5  Prefactor     4.2529        75.413        .19495E-03   -1.5295    
   6  Prefactor     .10000E-03    12.619        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10000E-03    28.953        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     6.2382        6.2642        .80363E-03   -1.5208    
   9  norm          .10000E-03    9.5404        .27302E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     61.860        50.084        .25507E-03   -1.4133    
  11  Prefactor     1.4542        59.999        .36095E-03   -1.5467    
  12  Prefactor     .10000E-03    5.9780        .18059E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  norm          .10000E-03    1.4998        .90436E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          .10000E-03    5.6080        .17499E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  norm          15.016        5.4649        .99897E-04   -1.4933    
  16  norm          .10001E-03    32.074        .38158E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          2.4393        5.1458        .23829E-03   -1.5396    
  18  Prefactor     .10000E-03    1.8485        .99490E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10000E-03    4.1975        .15139E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .10000E-03    23.693        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     2.7975        58.979        .24314E-03   -1.5373    
  22  Prefactor     .10000E-03    7.4822        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     43.978        47.296        .60451E-04   -1.4381    
  24  Prefactor     .10000E-03    9.6938        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     .10000E-03    48.256        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  norm          7.6082        2.4070        .62758E-04   -1.5156    
  27  Prefactor     4.8691        8.7466        .18225E-03   -1.5267    
  28  norm          .10000E-03    6.9644        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  29  Normalizat    1.0169        .22502        .25234E-03   -.92467    
  30  Prefactor     1.1172        .26646        .29727E-03   -.88920    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.50158e-09
Minuit parameter uncertainties:
  1  9.64768
  2  9.61566
  3  6.73988
  4  11.2392
  5  35.8698
  6  6.49915e-05
  7  0.00043762
  8  6.26491
  9  0.000253801
  10  50.1179
  11  18.701
  12  3.46597e-05
  13  1.91135e-06
  14  1.331e-05
  15  5.46506
  16  0.0013302
  17  5.14677
  18  5.642e-06
  19  3.72486e-06
  20  0.000382799
  21  25.7186
  22  1.53414e-05
  23  47.3366
  24  4.3893e-05
  25  0.000189944
  26  2.40707
  27  8.74893
  28  3.02896e-05
  29  0.225226
  30  0.266778
Done.

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

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  1.000e-04  3.466e-05  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.117e+00  2.668e-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.017e+00  2.252e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 196.008 37.071
Photon Flux Upper Limit: 5.74e-08 ph cm-2 s-1
Energy Flux Upper Limit: 4.45e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/189369/likelihoodResults_371001601_371260801_4FGL_J1304.0+3704_daily_bin508.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): 102
logL (Free Index) = 5728.75123159
delta logL = -0.000794482694801

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 5728.75043707
delta logL = 3.69027475244e-08

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10061E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.4195       1.0000          .0000       10.000    
     3 'Normalizat'    1.0169       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.1172       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=   5728.750     FROM MIGRAD    STATUS=CONVERGED     54 CALLS      206 TOTAL
                     EDM=   .77E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    7.9250        .90712E-02** at limit **
   2  Index         2.4031        6.1847        .50000        .23597E-04
   3  Normalizat    1.0169        .18087        .43850E-01    .93352E-06
   4  Prefactor     1.1172        .22307        .67197E-01    .27658E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Index      = 2.4031
  Normalizat = 1.01689
  Prefactor  = 1.11716
 **********
 **   18 **HESSE 
 **********

 FCN=   5728.750     FROM HESSE     STATUS=OK            33 CALLS      239 TOTAL
                     EDM=   .76E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    8.8244        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.4031        6.1618        .50000       -.54613    
   3  Normalizat    1.0169        .21258        .25234E-03   -.92467    
   4  Prefactor     1.1172        .26198        .29727E-03   -.88920    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 7.59426e-10
Minuit parameter uncertainties:
  1  1.90369e-05
  2  5.1407
  3  0.212757
  4  0.262282
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/189369': 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) = 5728.75043692
delta logL = 1.82809344551e-07

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  1.000e-04  1.904e-05  1.000e-04  1.000e+04 ( 1.000e-13)
314        Index:  2.403e+00  5.141e+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:  1.117e+00  2.623e-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.017e+00  2.128e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 196.008 37.071

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/189369/cmap_HighResolution_371001601_371260801_4FGL_J1304.0+3704_daily_bin508.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='4.45e-03', job_status='DONE', photon_flux_upper_limit='5.74e-08', time_completed='2021-09-06 20:01:55.774726', job_id='189369', GAL2='1.12', fit_tolerance='1e-08', EG2='1.02', EG='1.02', time_epoch_completed='1630983715.77', return_code2='0', ts='-0.00', comment='SUCCESS', return_code='0', GAL='1.12', dlogl='1.83e-07', ts2='-0.00', photon_index_error='0.00', photon_index='2.44' WHERE bin_id='508' AND source_name='4FGL J1304.0+3704' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 20:01:55 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0058>
Subject: Job 189369: <4FGL_J1304.0+3704_daily_bin508> in cluster <slac> Done

Job <4FGL_J1304.0+3704_daily_bin508> was submitted from host <rhel6-64j> by user <kocevski> in cluster <slac> at Mon Sep  6 19:45:26 2021
Job was executed on host(s) <bullet0058>, in queue <medium>, as user <kocevski> in cluster <slac> at Mon Sep  6 19:45:52 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:45:52 2021
Terminated at Mon Sep  6 20:01:56 2021
Results reported at Mon Sep  6 20:01:56 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1304.0+3704_daily_bin508 196.008 37.071 371001601 371260801 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 :                                   824.08 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             299.55 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   964 sec.
    Turnaround time :                            990 sec.

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

