/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 9 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 = 7404
number of fields = 22
No RA_SUN column yet. Adding RA_SUN/DEC_SUN columns.
Done.


Performing analysis on: 4FGL_J1304.0+3704_daily_bin60
RA = 196.008, Dec = 37.071
tmin = 254880001, tmax = 255139201
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='183925', job_status='RUN', time_executed='2021-09-06 19:26:11.940865', time_epoch_executed='1630981571.94' WHERE source_name='4FGL J1304.0+3704' and cadence='daily' and bin_id='60'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/183925

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/183925/ft1_4FGL_J1304.0+3704_daily_bin60.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/183925/ft2_4FGL_J1304.0+3704_daily_bin60.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/183925/ft1_4FGL_J1304.0+3704_daily_bin60.fits outfile=/scratch/kocevski/183925/ft1_filteredMKT_4FGL_J1304.0+3704_daily_bin60.fits ra=196.008 dec=37.071 rad=12.0 tmin=254880001.0 tmax=255139201.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 1.43
user 1.25
sys 0.16

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

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

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

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/183925/ft1_filtered_4FGL_J1304.0+3704_daily_bin60.fits evtable="EVENTS" scfile=/scratch/kocevski/183925/ft2_4FGL_J1304.0+3704_daily_bin60.fits sctable="SC_DATA" expcube=/scratch/kocevski/183925/ltcube_254880001_255139201_4FGL_J1304.0+3704_daily_bin60.fits outfile=/scratch/kocevski/183925/expmap_254880001_255139201_4FGL_J1304.0+3704_daily_bin60.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/183925/ltcube_254880001_255139201_4FGL_J1304.0+3704_daily_bin60.fits
.....................!
real 192.03
user 187.02
sys 3.99

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/183925/ft1_filtered_4FGL_J1304.0+3704_daily_bin60.fits scfile=/scratch/kocevski/183925/ft2_4FGL_J1304.0+3704_daily_bin60.fits outfile=/scratch/kocevski/183925/cmap_254880001_255139201_4FGL_J1304.0+3704_daily_bin60.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.54
user 0.39
sys 0.14

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

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

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

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    3.7588       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10014E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    2.2663       1.0000         .10000E-03   10000.    
     4 'Prefactor '    10.853       1.0000         .10000E-03   10000.    
     5 'Prefactor '    15.217       1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    4.9436       1.0000         .10000E-03   10000.    
     8 'Prefactor '    .50592       1.0000         .10000E-03   10000.    
     9 'norm      '    1.1376       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    47.708       1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    13 'norm      '    18.349       1.0000         .10000E-03   10000.    
    14 'norm      '    4.0918       1.0000         .10000E-03   10000.    
    15 'norm      '    1.4809       1.0000         .10000E-03   10000.    
    16 'norm      '    10.561       1.0000         .10000E-03   10000.    
    17 'norm      '    2.3563       1.0000         .10000E-03   10000.    
    18 'Prefactor '    6.7995       1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .13681E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10037E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    23.224       1.0000         .10000E-03   10000.    
    25 'Prefactor '    8.0092       1.0000         .10000E-03   10000.    
    26 'norm      '    4.2035       1.0000         .10000E-03   10000.    
    27 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
    28 'norm      '    .10004E-03   1.0000         .10000E-03   10000.    
    29 'Normalizat'    1.0366       1.0000         .10000E-01   10.000    
    30 'Prefactor '    1.0324       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=   6835.195     FROM MIGRAD    STATUS=CONVERGED    767 CALLS     3909 TOTAL
                     EDM=   .85E-10  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .4%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          3.7588        3.8430       -.11031E-06    .14317E-04
   2  Prefactor     .10000E-03    7.0535       -.28099E-05** at limit **
   3  Prefactor     2.2661        2.4384        .41653E-07   -.43431E-05
   4  Prefactor     10.853        9.0224       -.55669E-07   -.12204E-04
   5  Prefactor     15.218        26.837        .18141E-06    .64544E-05
   6  Prefactor     .10000E-03    13.145        .49807E-05** at limit **
   7  Prefactor     4.9529        322.58        .32558E-04   -.13118E-04
   8  Prefactor     .50611        .38190        .18606E-07   -.66048E-03
   9  norm          1.1369        7.5294        .16779E-05   -.27315E-03
  10  Prefactor     .10000E-03    24.216       -.46502E-05** at limit **
  11  Prefactor     47.713        27.596        .15778E-06   -.10582E-03
  12  Prefactor     .10000E-03    6.6418        .96893E-06** at limit **
  13  norm          18.350        6.7965        .85950E-07   -.56268E-04
  14  norm          4.0916        7.8265        .26387E-08    .55138E-05
  15  norm          1.4803        4.9839       -.83137E-06   -.17610E-03
  16  norm          10.562        9.1727       -.44937E-07   -.51291E-04
  17  norm          2.3571        4.1178       -.22587E-05   -.40444E-04
  18  Prefactor     6.7995        3.4667       -.43357E-07    .32353E-05
  19  Prefactor     .10000E-03    3.2234        .77823E-07** at limit **
  20  Prefactor     .10000E-03    141.59       -.18429E-05** at limit **
  21  Prefactor     .10000E-03    28.429       -.65661E-05** at limit **
  22  Prefactor     .10000E-03    8.9037        .78571E-05** at limit **
  23  Prefactor     .10000E-03    31.191        .11142E-04** at limit **
  24  Prefactor     23.224        17.809       -.15020E-06   -.68456E-04
  25  Prefactor     8.0077        154.07       -.37604E-05    .86126E-05
  26  norm          4.2035        1.7599        .14825E-07   -.39957E-04
  27  Prefactor     .10000E-03    1.9797        .32380E-08** at limit **
  28  norm          .10000E-03    10.060       -.93080E-05** at limit **
  29  Normalizat    1.0365        .16747       -.37526E-06   -.29453E-04
  30  Prefactor     1.0325        .20142       -.81732E-07   -.30561E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 3.75885
  Prefactor  = 0.0001
  Prefactor  = 2.26611
  Prefactor  = 10.8526
  Prefactor  = 15.2177
  Prefactor  = 0.0001
  Prefactor  = 4.95287
  Prefactor  = 0.50611
  norm       = 1.13687
  Prefactor  = 0.0001
  Prefactor  = 47.7128
  Prefactor  = 0.0001
  norm       = 18.3498
  norm       = 4.09158
  norm       = 1.48031
  norm       = 10.5622
  norm       = 2.35712
  Prefactor  = 6.79953
  Prefactor  = 0.0001
  Prefactor  = 0.000100001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 23.2238
  Prefactor  = 8.00766
  norm       = 4.20347
  Prefactor  = 0.0001
  norm       = 0.0001
  Normalizat = 1.03655
  Prefactor  = 1.03248
 **********
 **   18 **HESSE 
 **********

 FCN=   6835.195     FROM HESSE     STATUS=OK           590 CALLS     4499 TOTAL
                     EDM=   .13E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          3.7588        3.8733        .14206E-03   -1.5320    
   2  Prefactor     .10000E-03    7.1977        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     2.2661        2.4507        .11610E-03   -1.5407    
   4  Prefactor     10.853        9.0211        .12162E-03   -1.5049    
   5  Prefactor     15.218        26.838        .10267E-03   -1.4928    
   6  Prefactor     .10000E-03    13.185        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     4.9529        286.03        .18089E-03   -1.5263    
   8  Prefactor     .50611        8.1215        .22119E-02   -1.5566    
   9  norm          1.1369        6.2133        .32915E-03   -1.5495    
  10  Prefactor     .10000E-03    24.237        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     47.713        26.651        .58053E-04   -1.4325    
  12  Prefactor     .10000E-03    6.6590        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  norm          18.350        6.8369        .93500E-04   -1.4851    
  14  norm          4.0916        7.8168        .19930E-03   -1.5303    
  15  norm          1.4803        4.8269        .21156E-03   -1.5465    
  16  norm          10.562        8.9873        .12329E-03   -1.5058    
  17  norm          2.3571        4.1068        .21395E-03   -1.5401    
  18  Prefactor     6.7995        3.4571        .10289E-03   -1.5186    
  19  Prefactor     .10000E-03    3.2257        .14494E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .10000E-03    145.18        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .10000E-03    28.462        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     .10000E-03    8.9601        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .10000E-03    31.351        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     23.224        17.816        .83119E-04   -1.4744    
  25  Prefactor     8.0077        155.35        .14167E-03   -1.5142    
  26  norm          4.2035        1.7600        .68296E-04   -1.5298    
  27  Prefactor     .10000E-03    2.0012        .11358E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  norm          .10000E-03    10.093        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  29  Normalizat    1.0365        .19988        .23549E-03   -.91816    
  30  Prefactor     1.0325        .23966        .29612E-03   -.91654    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.26918e-09
Minuit parameter uncertainties:
  1  3.87358
  2  1.93235e-05
  3  2.45078
  4  9.02222
  5  26.8594
  6  8.58327e-06
  7  75.6586
  8  4.05506
  9  5.31613
  10  1.70395e-05
  11  26.6572
  12  3.86743e-06
  13  6.83722
  14  7.81878
  15  4.8282
  16  8.98842
  17  4.10732
  18  3.45717
  19  1.37391e-06
  20  0.000915983
  21  1.33705e-05
  22  8.87373e-06
  23  3.71457e-05
  24  17.8199
  25  70.7536
  26  1.75998
  27  9.44934e-07
  28  2.43452e-05
  29  0.200024
  30  0.239911
Done.

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

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  1.000e-04  3.867e-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:  1.032e+00  2.399e-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.037e+00  2.000e-01  1.000e-02  1.000e+01 ( 1.000e+00)


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

Saving results to:
/scratch/kocevski/183925/likelihoodResults_254880001_255139201_4FGL_J1304.0+3704_daily_bin60.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) = 6835.19598463
delta logL = -0.000714833450729

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 6835.19526978
delta logL = 2.04136085813e-08

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10032E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.4231       1.0000          .0000       10.000    
     3 'Normalizat'    1.0366       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.0325       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=   6835.195     FROM MIGRAD    STATUS=CONVERGED     89 CALLS      241 TOTAL
                     EDM=   .76E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10142E-03    123.22        .18142E-02** at limit **
   2  Index         2.3414        7.6221        .50000        .12413E-04
   3  Normalizat    1.0365        .16975E-01    .23549E-03    .30511E-04
   4  Prefactor     1.0325        .21393E-01    .29612E-03    .42270E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000101422
  Index      = 2.34137
  Normalizat = 1.03655
  Prefactor  = 1.03248
 **********
 **   18 **HESSE 
 **********

 FCN=   6835.195     FROM HESSE     STATUS=NOT POSDEF    29 CALLS      270 TOTAL
                     EDM=   .36E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10142E-03    506.28        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.3414        5.2722        .50000       -.56064    
   3  Normalizat    1.0365        .37271E-01    .94197E-05   -.91816    
   4  Prefactor     1.0325        .46963E-01    .11845E-04   -.91654    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 3.56198e-08
Minuit parameter uncertainties:
  1  0.0541322
  2  1329.81
  3  0.0372718
  4  0.0469647
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/183925': 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) = 6835.19526958
delta logL = 2.18136847252e-07

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  1.014e-04  5.413e-02  1.000e-04  1.000e+04 ( 1.000e-13)
314        Index:  2.341e+00  1.330e+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:  1.032e+00  4.696e-02  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.037e+00  3.727e-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 -2.500e-04 [aplpy.core]
INFO: Auto-setting vmax to  2.775e-03 [aplpy.core]
Saving /scratch/kocevski/183925/cmap_HighResolution_254880001_255139201_4FGL_J1304.0+3704_daily_bin60.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='4.25e-03', job_status='DONE', photon_flux_upper_limit='5.49e-08', time_completed='2021-09-06 19:41:44.803853', job_id='183925', GAL2='1.03', fit_tolerance='1e-08', EG2='1.04', EG='1.04', time_epoch_completed='1630982504.8', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='1.03', dlogl='2.18e-07', ts2='-0.00', photon_index_error='0.00', photon_index='2.44' WHERE bin_id='60' AND source_name='4FGL J1304.0+3704' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 19:41:44 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0299>
Subject: Job 183925: <4FGL_J1304.0+3704_daily_bin60> in cluster <slac> Done

Job <4FGL_J1304.0+3704_daily_bin60> was submitted from host <rhel6-64e> by user <kocevski> in cluster <slac> at Mon Sep  6 19:25:39 2021
Job was executed on host(s) <bullet0299>, in queue <medium>, as user <kocevski> in cluster <slac> at Mon Sep  6 19:25:52 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Mon Sep  6 19:25:52 2021
Terminated at Mon Sep  6 19:41:45 2021
Results reported at Mon Sep  6 19:41:45 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1304.0+3704_daily_bin60 196.008 37.071 254880001 255139201 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 :                                   927.00 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             342.48 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   953 sec.
    Turnaround time :                            966 sec.

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

