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


Performing analysis on: 4FGL_J1304.0+3704_daily_bin505
RA = 196.008, Dec = 37.071
tmin = 370224001, tmax = 370483201
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='189365', job_status='RUN', time_executed='2021-09-06 19:49:53.251072', time_epoch_executed='1630982993.25' WHERE source_name='4FGL J1304.0+3704' and cadence='daily' and bin_id='505'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/189365

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/189365/ft1_4FGL_J1304.0+3704_daily_bin505.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/189365/ft2_4FGL_J1304.0+3704_daily_bin505.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/189365/ft1_4FGL_J1304.0+3704_daily_bin505.fits outfile=/scratch/kocevski/189365/ft1_filteredMKT_4FGL_J1304.0+3704_daily_bin505.fits ra=196.008 dec=37.071 rad=12.0 tmin=370224001.0 tmax=370483201.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 13.39
user 13.01
sys 0.34

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/189365/ft2_4FGL_J1304.0+3704_daily_bin505.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/189365/ft1_filteredMKT_4FGL_J1304.0+3704_daily_bin505.fits evtable="EVENTS" outfile="/scratch/kocevski/189365/ft1_filtered_4FGL_J1304.0+3704_daily_bin505.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.45
user 0.29
sys 0.15

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/189365/ft1_filtered_4FGL_J1304.0+3704_daily_bin505.fits" evtable="EVENTS" scfile=/scratch/kocevski/189365/ft2_4FGL_J1304.0+3704_daily_bin505.fits sctable="SC_DATA" outfile=/scratch/kocevski/189365/ltcube_370224001_370483201_4FGL_J1304.0+3704_daily_bin505.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/189365/ft2_4FGL_J1304.0+3704_daily_bin505.fits
.....................!
real 11.69
user 11.35
sys 0.31

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/189365/ft1_filtered_4FGL_J1304.0+3704_daily_bin505.fits evtable="EVENTS" scfile=/scratch/kocevski/189365/ft2_4FGL_J1304.0+3704_daily_bin505.fits sctable="SC_DATA" expcube=/scratch/kocevski/189365/ltcube_370224001_370483201_4FGL_J1304.0+3704_daily_bin505.fits outfile=/scratch/kocevski/189365/expmap_370224001_370483201_4FGL_J1304.0+3704_daily_bin505.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/189365/ltcube_370224001_370483201_4FGL_J1304.0+3704_daily_bin505.fits
.....................!
real 157.40
user 152.26
sys 4.81

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/189365/ft1_filtered_4FGL_J1304.0+3704_daily_bin505.fits scfile=/scratch/kocevski/189365/ft2_4FGL_J1304.0+3704_daily_bin505.fits outfile=/scratch/kocevski/189365/cmap_370224001_370483201_4FGL_J1304.0+3704_daily_bin505.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.48
user 0.33
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/189365/ft1_filtered_4FGL_J1304.0+3704_daily_bin505.fits scfile=/scratch/kocevski/189365/ft2_4FGL_J1304.0+3704_daily_bin505.fits outfile=/scratch/kocevski/189365/cmap_HighResolution_370224001_370483201_4FGL_J1304.0+3704_daily_bin505.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.49
user 0.33
sys 0.15

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

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

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    2.3708       1.0000         .10000E-03   10000.    
     2 'Prefactor '    6.6480       1.0000         .10000E-03   10000.    
     3 'Prefactor '    2.8990       1.0000         .10000E-03   10000.    
     4 'Prefactor '    7.7950       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
     9 'norm      '    1.9423       1.0000         .10000E-03   10000.    
    10 'Prefactor '    53.585       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    13 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    20.617       1.0000         .10000E-03   10000.    
    15 'norm      '    9.8469       1.0000         .10000E-03   10000.    
    16 'norm      '    .25529E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10061E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10038E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    67.244       1.0000         .10000E-03   10000.    
    22 'Prefactor '    .15735E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    44.146       1.0000         .10000E-03   10000.    
    25 'Prefactor '    81.955       1.0000         .10000E-03   10000.    
    26 'norm      '    11.532       1.0000         .10000E-03   10000.    
    27 'Prefactor '    5.5534       1.0000         .10000E-03   10000.    
    28 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    29 'Normalizat'    .41343       1.0000         .10000E-01   10.000    
    30 'Prefactor '    1.3819       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=   4099.141     FROM MIGRAD    STATUS=CONVERGED    758 CALLS     3909 TOTAL
                     EDM=   .54E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.4%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          2.3709        2.6085       -.91486E-08   -.33716E-05
   2  Prefactor     6.6477        8.7246        .14362E-06   -.10850E-04
   3  Prefactor     2.8990        2.1824       -.12500E-08    .51853E-05
   4  Prefactor     7.7949        7.5713       -.22528E-07    .22629E-05
   5  Prefactor     .10000E-03    10.475       -.43357E-08** at limit **
   6  Prefactor     .10000E-03    8.9189        .27641E-07** at limit **
   7  Prefactor     .10000E-03    23.356       -.80850E-06** at limit **
   8  Prefactor     .10000E-03    2.4416        .24032E-07** at limit **
   9  norm          1.9423        3.0081        .93781E-07   -.89925E-04
  10  Prefactor     53.589        60.433        .27926E-06    .17273E-04
  11  Prefactor     .10000E-03    10.523       -.83244E-08** at limit **
  12  Prefactor     .10000E-03    7.0207       -.52094E-07** at limit **
  13  norm          .10000E-03    1.8187       -.70996E-07** at limit **
  14  norm          20.616        22.126        .86537E-07   -.80727E-05
  15  norm          9.8450        5.3253       -.87445E-06   -.15744E-02
  16  norm          .10000E-03    10.375        .28019E-05** at limit **
  17  norm          .10000E-03    1.2626        .38061E-07** at limit **
  18  Prefactor     .10000E-03    2.9253       -.97353E-06** at limit **
  19  Prefactor     .10000E-03    8.7606       -.41559E-06** at limit **
  20  Prefactor     .10000E-03    37.141        .10667E-05** at limit **
  21  Prefactor     67.195        91.493       -.87625E-06   -.10622E-03
  22  Prefactor     .10000E-03    88.446       -.22844E-05** at limit **
  23  Prefactor     .10000E-03    18.396        .62167E-06** at limit **
  24  Prefactor     44.140        40.740       -.74748E-06   -.14133E-04
  25  Prefactor     81.958        96.859        .91699E-07   -.17904E-06
  26  norm          11.532        2.7301        .26663E-07   -.34615E-04
  27  Prefactor     5.5524        7.5923        .27957E-05   -.23517E-03
  28  norm          .10000E-03    8.7793        .84493E-07** at limit **
  29  Normalizat    .41335        .20104        .25644E-06   -.47965E-04
  30  Prefactor     1.3820        .25012       -.48434E-06   -.45305E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 2.37088
  Prefactor  = 6.64774
  Prefactor  = 2.89901
  Prefactor  = 7.79488
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.000100002
  Prefactor  = 0.0001
  norm       = 1.94233
  Prefactor  = 53.5894
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 20.6156
  norm       = 9.84495
  norm       = 0.000100002
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.000100001
  Prefactor  = 67.195
  Prefactor  = 0.0001
  Prefactor  = 0.000100001
  Prefactor  = 44.1403
  Prefactor  = 81.9583
  norm       = 11.5322
  Prefactor  = 5.55237
  norm       = 0.0001
  Normalizat = 0.413346
  Prefactor  = 1.382
 **********
 **   18 **HESSE 
 **********

 FCN=   4099.141     FROM HESSE     STATUS=OK           578 CALLS     4487 TOTAL
                     EDM=   .94E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          2.3709        2.6137        .10444E-03   -1.5400    
   2  Prefactor     6.6477        8.7142        .15563E-03   -1.5192    
   3  Prefactor     2.8990        2.1882        .78978E-04   -1.5367    
   4  Prefactor     7.7949        7.5734        .14362E-03   -1.5150    
   5  Prefactor     .10000E-03    10.482        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    8.9246        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10000E-03    23.434        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .10000E-03    2.4480        .97694E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  norm          1.9423        2.9840        .13377E-03   -1.5429    
  10  Prefactor     53.589        60.409        .54793E-04   -1.4243    
  11  Prefactor     .10000E-03    10.530        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10000E-03    7.0299        .16567E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  norm          .10000E-03    1.8203        .84303E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          20.616        22.158        .88212E-04   -1.4800    
  15  norm          9.8450        4.9671        .95977E-04   -1.5080    
  16  norm          .10000E-03    27.253        .34347E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          .10000E-03    1.2645        .70256E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .10000E-03    2.8966        .10535E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10000E-03    8.7615        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .10000E-03    37.356        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     67.195        91.304        .48945E-04   -1.4067    
  22  Prefactor     .10000E-03    90.943        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .10000E-03    18.435        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     44.140        40.573        .60340E-04   -1.4378    
  25  Prefactor     81.958        97.057        .44368E-04   -1.3895    
  26  norm          11.532        2.7292        .49691E-04   -1.5029    
  27  Prefactor     5.5524        7.2990        .85243E-03   -1.5237    
  28  norm          .10000E-03    8.7858        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  29  Normalizat    .41335        .23162        .31292E-03   -1.1662    
  30  Prefactor     1.3820        .29253        .23337E-03   -.80900    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 9.36326e-10
Minuit parameter uncertainties:
  1  2.61384
  2  8.71586
  3  2.18821
  4  7.57435
  5  2.46784e-05
  6  3.43585e-06
  7  0.000406168
  8  1.34475e-06
  9  2.9842
  10  60.4783
  11  6.96056e-06
  12  9.90084e-07
  13  2.60705e-06
  14  22.1671
  15  4.96728
  16  0.000484896
  17  1.34659e-07
  18  2.54558e-05
  19  4.01987e-05
  20  0.000402251
  21  91.4954
  22  0.000356233
  23  0.000213685
  24  40.598
  25  97.2454
  26  2.72928
  27  7.30021
  28  1.19274e-05
  29  0.232158
  30  0.29288
Done.

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

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  1.000e-04  9.901e-07  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.382e+00  2.929e-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:  4.133e-01  2.322e-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: 6.54e-08 ph cm-2 s-1
Energy Flux Upper Limit: 5.07e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/189365/likelihoodResults_370224001_370483201_4FGL_J1304.0+3704_daily_bin505.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) = 4099.14126936
delta logL = -0.000673173146424

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 4099.14059617
delta logL = 9.94623405859e-09

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 'Index     '    2.4283       1.0000          .0000       10.000    
     3 'Normalizat'    .41334       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.3820       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=   4099.141     FROM MIGRAD    STATUS=CONVERGED     53 CALLS      209 TOTAL
                     EDM=   .10E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    7.9902        .90712E-02** at limit **
   2  Index         2.4208        6.2087        .50000        .91913E-05
   3  Normalizat    .41335        .18802        .70674E-01    .33738E-04
   4  Prefactor     1.3820        .24638        .52786E-01    .57017E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Index      = 2.42083
  Normalizat = 0.413347
  Prefactor  = 1.382
 **********
 **   18 **HESSE 
 **********

 FCN=   4099.141     FROM HESSE     STATUS=OK            33 CALLS      242 TOTAL
                     EDM=   .12E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    9.9985        .16605E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.4208        6.1774        .50000       -.54198    
   3  Normalizat    .41335        .21777        .31291E-03   -1.1662    
   4  Prefactor     1.3820        .28604        .23337E-03   -.80900    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.21229e-10
Minuit parameter uncertainties:
  1  1.44849e-06
  2  5.10415
  3  0.218215
  4  0.286365
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/189365': 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) = 4099.14059615
delta logL = 3.25389919453e-08

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  1.000e-04  1.448e-06  1.000e-04  1.000e+04 ( 1.000e-13)
314        Index:  2.421e+00  5.104e+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.382e+00  2.864e-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:  4.133e-01  2.182e-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/189365/cmap_HighResolution_370224001_370483201_4FGL_J1304.0+3704_daily_bin505.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='5.07e-03', job_status='DONE', photon_flux_upper_limit='6.54e-08', time_completed='2021-09-06 20:00:07.939257', job_id='189365', GAL2='1.38', fit_tolerance='1e-08', EG2='0.41', EG='0.41', time_epoch_completed='1630983607.94', return_code2='0', ts='-0.00', comment='SUCCESS', return_code='0', GAL='1.38', dlogl='3.25e-08', ts2='-0.00', photon_index_error='0.00', photon_index='2.44' WHERE bin_id='505' AND source_name='4FGL J1304.0+3704' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 20:00:07 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0189>
Subject: Job 189365: <4FGL_J1304.0+3704_daily_bin505> in cluster <slac> Done

Job <4FGL_J1304.0+3704_daily_bin505> 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) <bullet0189>, in queue <medium>, as user <kocevski> in cluster <slac> at Mon Sep  6 19:45:51 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:51 2021
Terminated at Mon Sep  6 20:00:08 2021
Results reported at Mon Sep  6 20:00:08 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1304.0+3704_daily_bin505 196.008 37.071 370224001 370483201 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 :                                   609.00 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             251.44 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   857 sec.
    Turnaround time :                            882 sec.

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

