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


Performing analysis on: 4FGL_J1304.0+3704_daily_bin174
RA = 196.008, Dec = 37.071
tmin = 284428801, tmax = 284688001
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='186589', job_status='RUN', time_executed='2021-09-06 19:35:48.268415', time_epoch_executed='1630982148.27' WHERE source_name='4FGL J1304.0+3704' and cadence='daily' and bin_id='174'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/186589

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/186589/ft1_4FGL_J1304.0+3704_daily_bin174.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/186589/ft2_4FGL_J1304.0+3704_daily_bin174.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/186589/ft1_4FGL_J1304.0+3704_daily_bin174.fits outfile=/scratch/kocevski/186589/ft1_filteredMKT_4FGL_J1304.0+3704_daily_bin174.fits ra=196.008 dec=37.071 rad=12.0 tmin=284428801.0 tmax=284688001.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.61
user 3.39
sys 0.20

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

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

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/186589/ft1_filtered_4FGL_J1304.0+3704_daily_bin174.fits" evtable="EVENTS" scfile=/scratch/kocevski/186589/ft2_4FGL_J1304.0+3704_daily_bin174.fits sctable="SC_DATA" outfile=/scratch/kocevski/186589/ltcube_284428801_284688001_4FGL_J1304.0+3704_daily_bin174.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/186589/ft2_4FGL_J1304.0+3704_daily_bin174.fits
.....................!
real 16.05
user 15.60
sys 0.36

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/186589/ft1_filtered_4FGL_J1304.0+3704_daily_bin174.fits evtable="EVENTS" scfile=/scratch/kocevski/186589/ft2_4FGL_J1304.0+3704_daily_bin174.fits sctable="SC_DATA" expcube=/scratch/kocevski/186589/ltcube_284428801_284688001_4FGL_J1304.0+3704_daily_bin174.fits outfile=/scratch/kocevski/186589/expmap_284428801_284688001_4FGL_J1304.0+3704_daily_bin174.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/186589/ltcube_284428801_284688001_4FGL_J1304.0+3704_daily_bin174.fits
.....................!
real 192.66
user 185.97
sys 6.00

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/186589/ft1_filtered_4FGL_J1304.0+3704_daily_bin174.fits scfile=/scratch/kocevski/186589/ft2_4FGL_J1304.0+3704_daily_bin174.fits outfile=/scratch/kocevski/186589/cmap_284428801_284688001_4FGL_J1304.0+3704_daily_bin174.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.59
user 0.39
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/186589/ft1_filtered_4FGL_J1304.0+3704_daily_bin174.fits scfile=/scratch/kocevski/186589/ft2_4FGL_J1304.0+3704_daily_bin174.fits outfile=/scratch/kocevski/186589/cmap_HighResolution_284428801_284688001_4FGL_J1304.0+3704_daily_bin174.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.57
user 0.40
sys 0.16

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

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

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    1.9199       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10016E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    10.223       1.0000         .10000E-03   10000.    
     8 'Prefactor '    1.9108       1.0000         .10000E-03   10000.    
     9 'norm      '    .12772E-02   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    60.391       1.0000         .10000E-03   10000.    
    12 'Prefactor '    13.173       1.0000         .10000E-03   10000.    
    13 'norm      '    .10015E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    15 'norm      '    4.4517       1.0000         .10000E-03   10000.    
    16 'norm      '    .10096E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    27.259       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    11.560       1.0000         .10000E-03   10000.    
    20 'Prefactor '    63.488       1.0000         .10000E-03   10000.    
    21 'Prefactor '    23.976       1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10006E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    .17861E-02   1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10016E-03   1.0000         .10000E-03   10000.    
    25 'Prefactor '    85.647       1.0000         .10000E-03   10000.    
    26 'norm      '    3.0739       1.0000         .10000E-03   10000.    
    27 'Prefactor '    1.1229       1.0000         .10000E-03   10000.    
    28 'norm      '    26.639       1.0000         .10000E-03   10000.    
    29 'Normalizat'    .66311       1.0000         .10000E-01   10.000    
    30 'Prefactor '    1.1560       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=   5312.530     FROM MIGRAD    STATUS=CONVERGED    758 CALLS     3995 TOTAL
                     EDM=   .10E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .9%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          1.9198        1.8811        .27023E-07    .22400E-03
   2  Prefactor     .10000E-03    1.4405       -.55808E-08** at limit **
   3  Prefactor     .10000E-03    .56057        .24898E-08** at limit **
   4  Prefactor     .10000E-03    3.6724        .20405E-07** at limit **
   5  Prefactor     .10000E-03    13.038        .36701E-05** at limit **
   6  Prefactor     .10000E-03    6.6347       -.10644E-05** at limit **
   7  Prefactor     10.223        69.965       -.96873E-06    .51490E-04
   8  Prefactor     1.9098        3.6759       -.13753E-06   -.24513E-03
   9  norm          .10001E-03    3.2036       -.21444E-05** at limit **
  10  Prefactor     .10000E-03    17.958       -.37276E-05** at limit **
  11  Prefactor     60.414        34.780        .65714E-05    .44967E-03
  12  Prefactor     13.174        13.557       -.17349E-05    .16193E-03
  13  norm          .10000E-03    1.4873       -.28200E-07** at limit **
  14  norm          .10000E-03    6.0455        .38754E-05** at limit **
  15  norm          4.4513        4.9093       -.18562E-05    .73376E-03
  16  norm          .10000E-03    5.8572       -.27081E-05** at limit **
  17  norm          27.260        7.4923        .48551E-06   -.77531E-04
  18  Prefactor     .10000E-03    1.2286       -.25945E-08** at limit **
  19  Prefactor     11.560        11.979       -.39532E-06    .19244E-03
  20  Prefactor     63.471        45.202       -.92398E-05    .20700E-03
  21  Prefactor     23.975        46.215       -.10184E-05    .27532E-04
  22  Prefactor     .10000E-03    12.567       -.13272E-05** at limit **
  23  Prefactor     .10005E-03    191.57        .10453E-04** at limit **
  24  Prefactor     .10000E-03    20.483        .26035E-05** at limit **
  25  Prefactor     85.648        76.403        .15642E-05   -.19555E-04
  26  norm          3.0742        1.4715        .50270E-07   -.13867E-03
  27  Prefactor     1.1227        3.8245       -.13767E-05   -.80785E-03
  28  norm          26.639        19.808        .55095E-06   -.57258E-04
  29  Normalizat    .66291        .17476        .45373E-06    .27346E-03
  30  Prefactor     1.1562        .21009        .36330E-06    .26550E-03
                               ERR DEF=  .500    
Final values: 
  norm       = 1.91981
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 10.2234
  Prefactor  = 1.90979
  norm       = 0.000100011
  Prefactor  = 0.0001
  Prefactor  = 60.4136
  Prefactor  = 13.174
  norm       = 0.0001
  norm       = 0.0001
  norm       = 4.45127
  norm       = 0.000100001
  norm       = 27.2597
  Prefactor  = 0.0001
  Prefactor  = 11.5602
  Prefactor  = 63.4714
  Prefactor  = 23.9751
  Prefactor  = 0.0001
  Prefactor  = 0.000100047
  Prefactor  = 0.0001
  Prefactor  = 85.6484
  norm       = 3.07416
  Prefactor  = 1.12268
  norm       = 26.6385
  Normalizat = 0.662908
  Prefactor  = 1.15622
 **********
 **   18 **HESSE 
 **********

 FCN=   5312.530     FROM HESSE     STATUS=OK           582 CALLS     4577 TOTAL
                     EDM=   .28E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          1.9198        1.8969        .96568E-04   -1.5431    
   2  Prefactor     .10000E-03    1.4408        .85434E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10000E-03    .56150        .53292E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    3.6806        .13641E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10000E-03    13.011        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    6.6332        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     10.223        69.329        .12532E-03   -1.5068    
   8  Prefactor     1.9098        3.6390        .18627E-03   -1.5432    
   9  norm          .10001E-03    15.354        .23264E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .10000E-03    17.917        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     60.414        33.905        .51630E-04   -1.4152    
  12  Prefactor     13.174        13.528        .11036E-03   -1.4982    
  13  norm          .10000E-03    1.4890        .86793E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          .10000E-03    6.0010        .17431E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  norm          4.4513        4.8436        .14799E-03   -1.5286    
  16  norm          .10000E-03    5.8335        .17083E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          27.260        7.4858        .76731E-04   -1.4663    
  18  Prefactor     .10000E-03    1.2342        .78799E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     11.560        11.952        .11783E-03   -1.5028    
  20  Prefactor     63.471        44.871        .50363E-04   -1.4113    
  21  Prefactor     23.975        46.214        .81807E-04   -1.4728    
  22  Prefactor     .10000E-03    12.610        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .10005E-03    199.31        .40656E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     .10000E-03    20.545        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     85.648        76.551        .43409E-04   -1.3854    
  26  norm          3.0742        1.4686        .59159E-04   -1.5357    
  27  Prefactor     1.1227        3.8782        .25925E-03   -1.5496    
  28  norm          26.639        19.799        .77617E-04   -1.4675    
  29  Normalizat    .66291        .20686        .26209E-03   -1.0538    
  30  Prefactor     1.1562        .24941        .25556E-03   -.87689    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.77626e-09
Minuit parameter uncertainties:
  1  1.89692
  2  4.18265e-07
  3  2.88462e-07
  4  2.23917e-06
  5  0.000135415
  6  2.59211e-05
  7  53.3346
  8  3.63947
  9  0.00082977
  10  0.000166804
  11  33.9155
  12  13.5309
  13  2.07967e-06
  14  9.73065e-05
  15  4.84401
  16  0.000131615
  17  7.48608
  18  2.19206e-07
  19  11.9548
  20  44.895
  21  46.2828
  22  5.70342e-05
  23  0.00615583
  24  0.000122769
  25  76.6398
  26  1.46865
  27  3.87903
  28  19.8034
  29  0.207099
  30  0.249666
Done.

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

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  1.317e+01  1.353e+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.156e+00  2.497e-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:  6.629e-01  2.071e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 1.79
Ra Dec: 196.008 37.071
Photon Index (Fixed Index): 2.44 +/- 0.00
Photon Flux (Fixed Index): 2.70e-08 +/- 2.77e-08
Energy Flux (Fixed Index): 8.46e-06 +/- 8.69e-06

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

Saving results to:
/scratch/kocevski/186589/likelihoodResults_284428801_284688001_4FGL_J1304.0+3704_daily_bin174.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) = 5312.36002041
delta logL = 0.170266614088

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 5311.95048471
delta logL = 0.579802315209

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .94656E-02   1.0000         .10000E-03   10000.    
     2 'Index     '    6.5950       1.0000          .0000       10.000    
     3 'Normalizat'    .56799       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.2531       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=   5311.950     FROM MIGRAD    STATUS=CONVERGED     57 CALLS      384 TOTAL
                     EDM=   .17E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .94703E-02    .10995        .90879E-03    .58816E-02
   2  Index         6.5956        2.5775        .10417        .14036E-03
   3  Normalizat    .56777        .46807E-01    .63673E-01    .27419E-04
   4  Prefactor     1.2534        .58867E-01    .55897E-01    .30562E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0094703
  Index      = 6.5956
  Normalizat = 0.567772
  Prefactor  = 1.25336
 **********
 **   18 **HESSE 
 **********

 FCN=   5311.950     FROM HESSE     STATUS=NOT POSDEF    33 CALLS      417 TOTAL
                     EDM=   .45E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .94703E-02    .22563        .47432E-05   -1.5689    
   2  Index         6.5956        3.8376        .41118E-02    .32480    
   3  Normalizat    .56777        .17440        .28175E-03   -1.0937    
   4  Prefactor     1.2534        .21628        .24715E-03   -.84705    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 4.50846e-10
Minuit parameter uncertainties:
  1  0.091962
  2  4.47287
  3  0.174566
  4  0.216437
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/186589': 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) = 5311.95048095
delta logL = 0.579806077319

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  9.470e-03  9.196e-02  1.000e-04  1.000e+04 ( 1.000e-13)
314        Index:  6.596e+00  4.473e+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.253e+00  2.164e-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:  5.678e-01  1.746e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 3.22
Ra Dec: 196.008 37.071
Photon Index (Free Index): 6.60 +/- 4.47
Photon Flux (Free Index): 8.30e-08 +/- 5.61e-08
Energy Flux (Free Index): 1.01e-05 +/- 7.17e-06

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/186589/cmap_HighResolution_284428801_284688001_4FGL_J1304.0+3704_daily_bin174.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='7.38e-03', comment='SUCCESS', photon_flux='2.70e-08', energy_flux2='1.01e-05', photon_flux_error='2.77e-08', dlogl='5.80e-01', energy_flux='8.46e-06', photon_flux2='8.30e-08', job_status='DONE', time_completed='2021-09-06 19:49:27.612097', photon_index_error2='4.47', photon_index2='6.60', ts='1.79', fit_tolerance='1e-08', GAL='1.16', photon_index_error='0.00', photon_flux_upper_limit='9.52e-08', energy_flux_error2='7.17e-06', EG='0.66', time_epoch_completed='1630982967.61', return_code='0', job_id='186589', GAL2='1.25', EG2='0.57', return_code2='102', energy_flux_error='8.69e-06', photon_flux_error2='5.61e-08', ts2='3.22', photon_index='2.44' WHERE bin_id='174' AND source_name='4FGL J1304.0+3704' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 19:49:27 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0161>
Subject: Job 186589: <4FGL_J1304.0+3704_daily_bin174> in cluster <slac> Done

Job <4FGL_J1304.0+3704_daily_bin174> was submitted from host <rhel6-64h> by user <kocevski> in cluster <slac> at Mon Sep  6 19:35:30 2021
Job was executed on host(s) <bullet0161>, in queue <medium>, as user <kocevski> in cluster <slac> at Mon Sep  6 19:35: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:35:32 2021
Terminated at Mon Sep  6 19:49:28 2021
Results reported at Mon Sep  6 19:49:28 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1304.0+3704_daily_bin174 196.008 37.071 284428801 284688001 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 :                                   812.01 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             338.73 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   836 sec.
    Turnaround time :                            838 sec.

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

