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


Performing analysis on: 4FGL_J1304.0+3704_daily_bin296
RA = 196.008, Dec = 37.071
tmin = 316051201, tmax = 316310401
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='186781', job_status='RUN', time_executed='2021-09-06 19:38:01.660095', time_epoch_executed='1630982281.66' WHERE source_name='4FGL J1304.0+3704' and cadence='daily' and bin_id='296'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/186781

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/186781/ft1_4FGL_J1304.0+3704_daily_bin296.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/186781/ft2_4FGL_J1304.0+3704_daily_bin296.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/186781/ft1_4FGL_J1304.0+3704_daily_bin296.fits outfile=/scratch/kocevski/186781/ft1_filteredMKT_4FGL_J1304.0+3704_daily_bin296.fits ra=196.008 dec=37.071 rad=12.0 tmin=316051201.0 tmax=316310401.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 3.54
user 3.30
sys 0.20

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/186781/ft2_4FGL_J1304.0+3704_daily_bin296.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/186781/ft1_filteredMKT_4FGL_J1304.0+3704_daily_bin296.fits evtable="EVENTS" outfile="/scratch/kocevski/186781/ft1_filtered_4FGL_J1304.0+3704_daily_bin296.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.54
user 0.38
sys 0.13

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

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/186781/ft1_filtered_4FGL_J1304.0+3704_daily_bin296.fits evtable="EVENTS" scfile=/scratch/kocevski/186781/ft2_4FGL_J1304.0+3704_daily_bin296.fits sctable="SC_DATA" expcube=/scratch/kocevski/186781/ltcube_316051201_316310401_4FGL_J1304.0+3704_daily_bin296.fits outfile=/scratch/kocevski/186781/expmap_316051201_316310401_4FGL_J1304.0+3704_daily_bin296.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/186781/ltcube_316051201_316310401_4FGL_J1304.0+3704_daily_bin296.fits
.....................!
real 192.55
user 187.83
sys 4.12

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/186781/ft1_filtered_4FGL_J1304.0+3704_daily_bin296.fits scfile=/scratch/kocevski/186781/ft2_4FGL_J1304.0+3704_daily_bin296.fits outfile=/scratch/kocevski/186781/cmap_316051201_316310401_4FGL_J1304.0+3704_daily_bin296.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.40
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/186781/ft1_filtered_4FGL_J1304.0+3704_daily_bin296.fits scfile=/scratch/kocevski/186781/ft2_4FGL_J1304.0+3704_daily_bin296.fits outfile=/scratch/kocevski/186781/cmap_HighResolution_316051201_316310401_4FGL_J1304.0+3704_daily_bin296.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.14

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

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

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    10.587       1.0000         .10000E-03   10000.    
     2 'Prefactor '    8.8451       1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    1.2866       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .68213       1.0000         .10000E-03   10000.    
     7 'Prefactor '    261.48       1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     9 'norm      '    12.429       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    32.578       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      '    11.886       1.0000         .10000E-03   10000.    
    15 'norm      '    .11537E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    .10005E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    1.8786       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    7.1228       1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    25.970       1.0000         .10000E-03   10000.    
    23 'Prefactor '    133.38       1.0000         .10000E-03   10000.    
    24 'Prefactor '    21.013       1.0000         .10000E-03   10000.    
    25 'Prefactor '    97.193       1.0000         .10000E-03   10000.    
    26 'norm      '    1.2679       1.0000         .10000E-03   10000.    
    27 'Prefactor '    7.7458       1.0000         .10000E-03   10000.    
    28 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
    29 'Normalizat'    1.1191       1.0000         .10000E-01   10.000    
    30 'Prefactor '    .79563       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=   5826.411     FROM MIGRAD    STATUS=CONVERGED    746 CALLS     3951 TOTAL
                     EDM=   .24E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  3.5%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          10.587        5.3894       -.40048E-06   -.55856E-04
   2  Prefactor     8.8453        6.7656       -.84496E-07    .20943E-05
   3  Prefactor     .10000E-03    1.5929        .12415E-06** at limit **
   4  Prefactor     1.2975        42.277        .19860E-04    .47804E-04
   5  Prefactor     .10000E-03    11.018       -.37772E-06** at limit **
   6  Prefactor     .62393        11.575        .19863E-05   -.26817E-03
   7  Prefactor     261.50        127.85       -.92690E-06    .11553E-04
   8  Prefactor     .10000E-03    2.9936       -.17583E-06** at limit **
   9  norm          12.429        7.2792        .26156E-06    .93727E-04
  10  Prefactor     .10000E-03    11.093        .15486E-06** at limit **
  11  Prefactor     32.591        33.088       -.78495E-06    .55096E-04
  12  Prefactor     .10000E-03    7.8951       -.36551E-06** at limit **
  13  norm          .10000E-03    3.1225       -.15661E-06** at limit **
  14  norm          11.885        10.379        .33309E-08    .89712E-05
  15  norm          .10000E-03    1.8475       -.42798E-06** at limit **
  16  norm          .10000E-03    3.0670        .11575E-06** at limit **
  17  norm          1.8787        3.6772       -.25989E-06    .54053E-05
  18  Prefactor     .10000E-03    2.1203       -.16166E-08** at limit **
  19  Prefactor     7.1230        11.181        .76716E-07    .69708E-04
  20  Prefactor     .10000E-03    34.616        .57392E-06** at limit **
  21  Prefactor     .10000E-03    61.386       -.64450E-06** at limit **
  22  Prefactor     25.981        24.517       -.35477E-06    .28861E-04
  23  Prefactor     133.40        55.236       -.97202E-06    .76981E-05
  24  Prefactor     21.012        24.965        .31917E-06    .79889E-05
  25  Prefactor     97.341        84.539       -.13384E-04    .19799E-04
  26  norm          1.2679        1.2655        .11004E-06    .19266E-03
  27  Prefactor     7.7460        6.4476        .40099E-06    .77942E-04
  28  norm          .10000E-03    5.1368        .83929E-07** at limit **
  29  Normalizat    1.1184        .19684       -.30788E-05    .10936E-03
  30  Prefactor     .79636        .22427        .60134E-05    .47245E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 10.5868
  Prefactor  = 8.84534
  Prefactor  = 0.0001
  Prefactor  = 1.29754
  Prefactor  = 0.0001
  Prefactor  = 0.623933
  Prefactor  = 261.5
  Prefactor  = 0.0001
  norm       = 12.429
  Prefactor  = 0.0001
  Prefactor  = 32.5913
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 11.8853
  norm       = 0.000100002
  norm       = 0.0001
  norm       = 1.87874
  Prefactor  = 0.0001
  Prefactor  = 7.12303
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 25.981
  Prefactor  = 133.399
  Prefactor  = 21.0117
  Prefactor  = 97.3413
  norm       = 1.26788
  Prefactor  = 7.746
  norm       = 0.0001
  Normalizat = 1.11841
  Prefactor  = 0.796365
 **********
 **   18 **HESSE 
 **********

 FCN=   5826.411     FROM HESSE     STATUS=OK           594 CALLS     4545 TOTAL
                     EDM=   .16E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          10.587        5.3861        .12022E-03   -1.5057    
   2  Prefactor     8.8453        6.7652        .13477E-03   -1.5113    
   3  Prefactor     .10000E-03    1.6056        .93821E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     1.2975        43.103        .19539E-02   -1.5480    
   5  Prefactor     .10000E-03    11.027        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .62393        65.435        .49511E-02   -1.5550    
   7  Prefactor     261.50        127.98        .25066E-04   -1.2460    
   8  Prefactor     .10000E-03    3.0081        .12889E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  norm          12.429        7.2620        .11362E-03   -1.5003    
  10  Prefactor     .10000E-03    11.094        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     32.591        32.806        .70204E-04   -1.4566    
  12  Prefactor     .10000E-03    7.9102        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  norm          .10000E-03    3.1471        .13165E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          11.885        10.380        .11619E-03   -1.5018    
  15  norm          .10000E-03    7.8110        .19558E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          .10000E-03    3.0850        .13039E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          1.8787        3.6501        .19772E-03   -1.5434    
  18  Prefactor     .10000E-03    2.1585        .10834E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     7.1230        11.092        .15030E-03   -1.5174    
  20  Prefactor     .10000E-03    34.661        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .10000E-03    61.538        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     25.981        24.541        .78608E-04   -1.4688    
  23  Prefactor     133.40        55.221        .17434E-03   -1.3393    
  24  Prefactor     21.012        24.943        .87377E-04   -1.4791    
  25  Prefactor     97.341        84.959        .20386E-03   -1.3732    
  26  norm          1.2679        1.2588        .82522E-04   -1.5483    
  27  Prefactor     7.7460        6.4465        .72041E-03   -1.5151    
  28  norm          .10000E-03    5.1431        .16897E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  29  Normalizat    1.1184        .23420        .23692E-03   -.89163    
  30  Prefactor     .79636        .26755        .32973E-03   -.99862    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.64543e-09
Minuit parameter uncertainties:
  1  5.38632
  2  6.76576
  3  9.63213e-06
  4  14.9681
  5  9.83505e-06
  6  12.7926
  7  128.117
  8  9.86518e-06
  9  7.26249
  10  4.70971e-06
  11  32.8238
  12  2.5966e-06
  13  1.14924e-06
  14  10.3811
  15  0.000248322
  16  1.76404e-06
  17  3.65049
  18  3.65601e-06
  19  11.0954
  20  7.23265e-05
  21  4.07795e-05
  22  24.5507
  23  55.2419
  24  24.9557
  25  85.0652
  26  1.25878
  27  6.44704
  28  8.92745e-06
  29  0.234415
  30  0.267986
Done.

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

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  1.000e-04  2.597e-06  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:  7.964e-01  2.680e-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.118e+00  2.344e-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.66e-08 ph cm-2 s-1
Energy Flux Upper Limit: 5.16e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/186781/likelihoodResults_316051201_316310401_4FGL_J1304.0+3704_daily_bin296.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) = 5826.4115434
delta logL = -0.000601744401138

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 5826.41094166
delta logL = -4.46743797511e-09

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.4342       1.0000          .0000       10.000    
     3 'Normalizat'    1.1184       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .79636       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=   5826.411     FROM MIGRAD    STATUS=CONVERGED     92 CALLS      248 TOTAL
                     EDM=   .74E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10006E-03    339.97        .18142E-02** at limit **
   2  Index         2.4080        5.8465        .50000        .13220E-05
   3  Normalizat    1.1184        .30804E-01    .23693E-03   -.37907E-05
   4  Prefactor     .79637        .36935E-01    .32972E-03    .10344E-06
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000100061
  Index      = 2.40797
  Normalizat = 1.11841
  Prefactor  = 0.796366
 **********
 **   18 **HESSE 
 **********

 FCN=   5826.411     FROM HESSE     STATUS=NOT POSDEF    29 CALLS      277 TOTAL
                     EDM=   .43E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10006E-03    1351.4        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.4080        6.0480        .50000       -.54499    
   3  Normalizat    1.1184        .85893E-01    .94771E-05   -.89163    
   4  Prefactor     .79637        .10246        .13189E-04   -.99862    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 4.32686e-09
Minuit parameter uncertainties:
  1  0.0186029
  2  3766.98
  3  0.0859035
  4  0.102487
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/186781': No such file or directory
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 5826.41094165
delta logL = 6.13908923697e-09

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  1.001e-04  1.860e-02  1.000e-04  1.000e+04 ( 1.000e-13)
314        Index:  2.408e+00  3.767e+03  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:  7.964e-01  1.025e-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.118e+00  8.590e-02  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/186781/cmap_HighResolution_316051201_316310401_4FGL_J1304.0+3704_daily_bin296.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='5.16e-03', job_status='DONE', photon_flux_upper_limit='6.66e-08', time_completed='2021-09-06 19:52:03.042865', job_id='186781', GAL2='0.80', fit_tolerance='1e-08', EG2='1.12', EG='1.12', time_epoch_completed='1630983123.04', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.80', dlogl='6.14e-09', ts2='-0.00', photon_index_error='0.00', photon_index='2.44' WHERE bin_id='296' AND source_name='4FGL J1304.0+3704' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 19:52:03 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0005>
Subject: Job 186781: <4FGL_J1304.0+3704_daily_bin296> in cluster <slac> Done

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

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1304.0+3704_daily_bin296 196.008 37.071 316051201 316310401 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 :                                   837.00 sec.
    Max Memory :                                 1094 MB
    Average Memory :                             291.62 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   974 sec.
    Turnaround time :                            976 sec.

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

