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


Performing analysis on: 4FGL_J1304.0+3704_daily_bin749
RA = 196.008, Dec = 37.071
tmin = 433468801, tmax = 433728001
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='190777', job_status='RUN', time_executed='2021-09-06 19:50:49.616890', time_epoch_executed='1630983049.62' WHERE source_name='4FGL J1304.0+3704' and cadence='daily' and bin_id='749'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/190777

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/190777/ft1_4FGL_J1304.0+3704_daily_bin749.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/190777/ft2_4FGL_J1304.0+3704_daily_bin749.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/190777/ft1_4FGL_J1304.0+3704_daily_bin749.fits outfile=/scratch/kocevski/190777/ft1_filteredMKT_4FGL_J1304.0+3704_daily_bin749.fits ra=196.008 dec=37.071 rad=12.0 tmin=433468801.0 tmax=433728001.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.08
user 5.75
sys 0.28

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

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

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

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/190777/ft1_filtered_4FGL_J1304.0+3704_daily_bin749.fits evtable="EVENTS" scfile=/scratch/kocevski/190777/ft2_4FGL_J1304.0+3704_daily_bin749.fits sctable="SC_DATA" expcube=/scratch/kocevski/190777/ltcube_433468801_433728001_4FGL_J1304.0+3704_daily_bin749.fits outfile=/scratch/kocevski/190777/expmap_433468801_433728001_4FGL_J1304.0+3704_daily_bin749.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/190777/ltcube_433468801_433728001_4FGL_J1304.0+3704_daily_bin749.fits
.....................!
real 192.29
user 187.67
sys 4.21

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/190777/ft1_filtered_4FGL_J1304.0+3704_daily_bin749.fits scfile=/scratch/kocevski/190777/ft2_4FGL_J1304.0+3704_daily_bin749.fits outfile=/scratch/kocevski/190777/cmap_433468801_433728001_4FGL_J1304.0+3704_daily_bin749.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.39
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/190777/ft1_filtered_4FGL_J1304.0+3704_daily_bin749.fits scfile=/scratch/kocevski/190777/ft2_4FGL_J1304.0+3704_daily_bin749.fits outfile=/scratch/kocevski/190777/cmap_HighResolution_433468801_433728001_4FGL_J1304.0+3704_daily_bin749.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.39
sys 0.16

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

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

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    .76259       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10025E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .24691E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10010E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10058E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    46.297       1.0000         .10000E-03   10000.    
     8 'Prefactor '    8.3157       1.0000         .10000E-03   10000.    
     9 'norm      '    .10182E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10088E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    3.7912       1.0000         .10000E-03   10000.    
    13 'norm      '    .10263E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    23.288       1.0000         .10000E-03   10000.    
    15 'norm      '    3.6713       1.0000         .10000E-03   10000.    
    16 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    .10005E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    2.6327       1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10052E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    16.033       1.0000         .10000E-03   10000.    
    22 'Prefactor '    .11042E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10057E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    15.727       1.0000         .10000E-03   10000.    
    25 'Prefactor '    103.94       1.0000         .10000E-03   10000.    
    26 'norm      '    8.3194       1.0000         .10000E-03   10000.    
    27 'Prefactor '    .12301E-03   1.0000         .10000E-03   10000.    
    28 'norm      '    17.593       1.0000         .10000E-03   10000.    
    29 'Normalizat'    .78290       1.0000         .10000E-01   10.000    
    30 'Prefactor '    1.1258       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=   3517.411     FROM MIGRAD    STATUS=CONVERGED    755 CALLS     3866 TOTAL
                     EDM=   .13E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .4%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .76306        4.1411       -.80196E-06   -.17808E-03
   2  Prefactor     .10000E-03    7.0922        .21073E-05** at limit **
   3  Prefactor     .10003E-03    2.7010       -.11536E-05** at limit **
   4  Prefactor     .10000E-03    4.8810        .13707E-05** at limit **
   5  Prefactor     .10000E-03    43.512       -.52350E-05** at limit **
   6  Prefactor     .10000E-03    14.961        .53697E-05** at limit **
   7  Prefactor     46.266        91.461       -.42758E-04    .22686E-04
   8  Prefactor     8.3188        8.5095        .29357E-05    .23353E-03
   9  norm          .10000E-03    2.5697        .33232E-06** at limit **
  10  Prefactor     .10000E-03    33.147        .11260E-04** at limit **
  11  Prefactor     .10000E-03    20.638       -.11776E-04** at limit **
  12  Prefactor     3.7661        39.205       -.39580E-04   -.25625E-04
  13  norm          .10000E-03    5.0744       -.54140E-06** at limit **
  14  norm          23.287        21.240       -.88609E-06    .30599E-05
  15  norm          3.6698        3.4740        .75254E-07    .24679E-03
  16  norm          .10000E-03    3.3368        .17487E-07** at limit **
  17  norm          .10000E-03    14.980        .19253E-05** at limit **
  18  Prefactor     2.6329        3.3533        .10753E-05    .15810E-03
  19  Prefactor     .10000E-03    5.4069       -.27831E-06** at limit **
  20  Prefactor     .10000E-03    39.872        .64039E-05** at limit **
  21  Prefactor     16.004        42.778       -.52210E-04    .13536E-04
  22  Prefactor     .10000E-03    16.257       -.15429E-05** at limit **
  23  Prefactor     .10000E-03    42.881       -.26714E-05** at limit **
  24  Prefactor     15.720        20.752       -.43528E-05    .17063E-04
  25  Prefactor     103.95        141.62        .84767E-05    .29996E-04
  26  norm          8.3193        2.9860       -.18208E-06    .15670E-03
  27  Prefactor     .10001E-03    4.1583        .17311E-06** at limit **
  28  norm          17.589        26.224       -.61652E-05    .42524E-05
  29  Normalizat    .78277        .21507        .46202E-05    .21145E-03
  30  Prefactor     1.1260        .25763        .47221E-05    .14769E-03
                               ERR DEF=  .500    
Final values: 
  norm       = 0.763057
  Prefactor  = 0.0001
  Prefactor  = 0.000100032
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 46.2662
  Prefactor  = 8.3188
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 3.76612
  norm       = 0.000100003
  norm       = 23.2866
  norm       = 3.66978
  norm       = 0.0001
  norm       = 0.000100001
  Prefactor  = 2.63293
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 16.0038
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 15.7201
  Prefactor  = 103.952
  norm       = 8.31925
  Prefactor  = 0.000100011
  norm       = 17.5889
  Normalizat = 0.78277
  Prefactor  = 1.12604
 **********
 **   18 **HESSE 
 **********

 FCN=   3517.411     FROM HESSE     STATUS=OK           578 CALLS     4444 TOTAL
                     EDM=   .56E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          .76306        3.0527        .20455E-03   -1.5533    
   2  Prefactor     .10000E-03    7.1248        .15420E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10003E-03    9.0466        .16499E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    4.8911        .12797E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10000E-03    43.621        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    14.972        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     46.266        91.408        .58927E-04   -1.4347    
   8  Prefactor     8.3188        8.4757        .13902E-03   -1.5131    
   9  norm          .10000E-03    2.5854        .92808E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .10000E-03    33.146        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .10000E-03    20.663        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     3.7661        38.962        .20732E-03   -1.5320    
  13  norm          .10000E-03    5.0964        .13003E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          23.287        21.245        .83005E-04   -1.4742    
  15  norm          3.6698        3.4663        .10301E-03   -1.5325    
  16  norm          .10000E-03    3.3398        .10571E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          .10000E-03    15.616        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     2.6329        3.3329        .11630E-03   -1.5383    
  19  Prefactor     .10000E-03    5.4104        .13467E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .10000E-03    39.915        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     16.004        42.725        .10003E-03   -1.4908    
  22  Prefactor     .10000E-03    16.455        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .10000E-03    42.955        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     15.720        20.749        .10099E-03   -1.4915    
  25  Prefactor     103.95        142.49        .39440E-04   -1.3665    
  26  norm          8.3193        2.9853        .29620E-03   -1.5131    
  27  Prefactor     .10001E-03    10.158        .23347E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  norm          17.589        26.205        .95489E-04   -1.4869    
  29  Normalizat    .78277        .25416        .24788E-03   -1.0071    
  30  Prefactor     1.1260        .30522        .26248E-03   -.88638    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 5.57379e-09
Minuit parameter uncertainties:
  1  3.05254
  2  3.78364e-05
  3  0.001079
  4  3.10162e-06
  5  0.000108869
  6  1.21596e-05
  7  91.6869
  8  8.47687
  9  5.64078e-05
  10  1.76662e-05
  11  0.000173841
  12  24.2468
  13  0.000233694
  14  21.2519
  15  3.46649
  16  3.52824e-06
  17  0.000198423
  18  3.33314
  19  1.00124e-05
  20  7.56464e-05
  21  42.8072
  22  2.77475e-05
  23  7.77095e-05
  24  20.758
  25  142.964
  26  2.98531
  27  0.00065344
  28  26.2218
  29  0.254542
  30  0.305699
Done.

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

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  3.766e+00  2.425e+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.126e+00  3.057e-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:  7.828e-01  2.545e-01  1.000e-02  1.000e+01 ( 1.000e+00)


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

Saving results to:
/scratch/kocevski/190777/likelihoodResults_433468801_433728001_4FGL_J1304.0+3704_daily_bin749.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) = 3517.4107122
delta logL = 0.000561837619898

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 3517.41048131
delta logL = 0.00079272864923

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    4.1956       1.0000         .10000E-03   10000.    
     2 'Index     '    2.3388       1.0000          .0000       10.000    
     3 'Normalizat'    .78377       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.1254       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=   3517.410     FROM MIGRAD    STATUS=CONVERGED     68 CALLS      252 TOTAL
                     EDM=   .20E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     4.2608        520.45        .49187E-02    .38655E-04
   2  Index         2.3025        2.0540        .50000        .71203E-05
   3  Normalizat    .78379        .19872E-01    .43398E-01    .65768E-04
   4  Prefactor     1.1250        .24853E-01    .59376E-01    .42176E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 4.26084
  Index      = 2.30246
  Normalizat = 0.783789
  Prefactor  = 1.12504
 **********
 **   18 **HESSE 
 **********

 FCN=   3517.410     FROM HESSE     STATUS=OK            33 CALLS      285 TOTAL
                     EDM=   .20E-10    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     4.2608        43.905        .19675E-03   -1.5295    
   2  Index         2.3025        2.8651        .77207E-02   -.56985    
   3  Normalizat    .78379        .24272        .24773E-03   -1.0067    
   4  Prefactor     1.1250        .30282        .26258E-03   -.88670    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.00909e-11
Minuit parameter uncertainties:
  1  27.3803
  2  3.15126
  3  0.24306
  4  0.303289
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/190777': 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) = 3517.41040562
delta logL = 0.00086842579185

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  4.261e+00  2.738e+01  1.000e-04  1.000e+04 ( 1.000e-13)
314        Index:  2.302e+00  3.151e+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.125e+00  3.033e-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:  7.838e-01  2.431e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 0.03
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/190777/cmap_HighResolution_433468801_433728001_4FGL_J1304.0+3704_daily_bin749.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='1.05e-02', job_status='DONE', photon_flux_upper_limit='1.35e-07', time_completed='2021-09-06 20:01:32.755021', job_id='190777', GAL2='1.13', fit_tolerance='1e-08', EG2='0.78', EG='0.78', time_epoch_completed='1630983692.76', return_code2='0', ts='0.03', comment='SUCCESS', return_code='0', GAL='1.13', dlogl='8.68e-04', ts2='0.03', photon_index_error='0.00', photon_index='2.44' WHERE bin_id='749' AND source_name='4FGL J1304.0+3704' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 20:01:32 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0046>
Subject: Job 190777: <4FGL_J1304.0+3704_daily_bin749> in cluster <slac> Done

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

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1304.0+3704_daily_bin749 196.008 37.071 433468801 433728001 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 :                                   639.00 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             336.00 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              7
    Max Threads :                                21
    Run time :                                   661 sec.
    Turnaround time :                            674 sec.

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

