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


Performing analysis on: 4FGL_J1304.0+3704_daily_bin252
RA = 196.008, Dec = 37.071
tmin = 304646401, tmax = 304905601
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='186713', job_status='RUN', time_executed='2021-09-06 19:38:10.491330', time_epoch_executed='1630982290.49' WHERE source_name='4FGL J1304.0+3704' and cadence='daily' and bin_id='252'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/186713

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/186713/ft1_4FGL_J1304.0+3704_daily_bin252.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/186713/ft2_4FGL_J1304.0+3704_daily_bin252.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/186713/ft1_4FGL_J1304.0+3704_daily_bin252.fits outfile=/scratch/kocevski/186713/ft1_filteredMKT_4FGL_J1304.0+3704_daily_bin252.fits ra=196.008 dec=37.071 rad=12.0 tmin=304646401.0 tmax=304905601.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.51
user 3.27
sys 0.21

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/186713/ft2_4FGL_J1304.0+3704_daily_bin252.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/186713/ft1_filteredMKT_4FGL_J1304.0+3704_daily_bin252.fits evtable="EVENTS" outfile="/scratch/kocevski/186713/ft1_filtered_4FGL_J1304.0+3704_daily_bin252.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/186713/ft1_filtered_4FGL_J1304.0+3704_daily_bin252.fits" evtable="EVENTS" scfile=/scratch/kocevski/186713/ft2_4FGL_J1304.0+3704_daily_bin252.fits sctable="SC_DATA" outfile=/scratch/kocevski/186713/ltcube_304646401_304905601_4FGL_J1304.0+3704_daily_bin252.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/186713/ft2_4FGL_J1304.0+3704_daily_bin252.fits
.....................!
real 16.21
user 15.78
sys 0.36

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/186713/ft1_filtered_4FGL_J1304.0+3704_daily_bin252.fits evtable="EVENTS" scfile=/scratch/kocevski/186713/ft2_4FGL_J1304.0+3704_daily_bin252.fits sctable="SC_DATA" expcube=/scratch/kocevski/186713/ltcube_304646401_304905601_4FGL_J1304.0+3704_daily_bin252.fits outfile=/scratch/kocevski/186713/expmap_304646401_304905601_4FGL_J1304.0+3704_daily_bin252.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/186713/ltcube_304646401_304905601_4FGL_J1304.0+3704_daily_bin252.fits
.....................!
real 191.84
user 186.28
sys 4.85

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/186713/ft1_filtered_4FGL_J1304.0+3704_daily_bin252.fits scfile=/scratch/kocevski/186713/ft2_4FGL_J1304.0+3704_daily_bin252.fits outfile=/scratch/kocevski/186713/cmap_304646401_304905601_4FGL_J1304.0+3704_daily_bin252.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.14

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

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

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

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    13.020       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    4.7067       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10050E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    29.484       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10026E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
     9 'norm      '    5.6065       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .19678E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10214E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    13 'norm      '    3.9797       1.0000         .10000E-03   10000.    
    14 'norm      '    .10009E-03   1.0000         .10000E-03   10000.    
    15 'norm      '    .10195E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    3.1304       1.0000         .10000E-03   10000.    
    17 'norm      '    17.605       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10502E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    1.0207       1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10089E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    1.2520       1.0000         .10000E-03   10000.    
    22 'Prefactor '    12.799       1.0000         .10000E-03   10000.    
    23 'Prefactor '    6.0067       1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10227E-03   1.0000         .10000E-03   10000.    
    25 'Prefactor '    .11083E-03   1.0000         .10000E-03   10000.    
    26 'norm      '    4.5296       1.0000         .10000E-03   10000.    
    27 'Prefactor '    6.0229       1.0000         .10000E-03   10000.    
    28 'norm      '    7.0292       1.0000         .10000E-03   10000.    
    29 'Normalizat'    1.2749       1.0000         .10000E-01   10.000    
    30 'Prefactor '    .62943       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.141     FROM MIGRAD    STATUS=CONVERGED    831 CALLS     3405 TOTAL
                     EDM=   .63E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  2.0%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          13.019        4.7152        .58775E-07    .56796E-04
   2  Prefactor     .10000E-03    2.6599        .28885E-07** at limit **
   3  Prefactor     .10000E-03    .76553       -.39903E-07** at limit **
   4  Prefactor     4.7085        8.1859       -.17229E-05   -.18856E-03
   5  Prefactor     .10000E-03    17.589       -.15417E-07** at limit **
   6  Prefactor     29.487        20.728        .26411E-06    .31436E-04
   7  Prefactor     .10000E-03    38.051        .13192E-05** at limit **
   8  Prefactor     .10000E-03    2.0481        .54140E-07** at limit **
   9  norm          5.6074        3.7077        .68916E-06   -.20971E-02
  10  Prefactor     .10000E-03    166.78        .35915E-05** at limit **
  11  Prefactor     .10000E-03    46.708       -.80501E-05** at limit **
  12  Prefactor     .10000E-03    6.6836        .63471E-07** at limit **
  13  norm          3.9821        3.6893        .39432E-08    .12134E-03
  14  norm          .10000E-03    6.9445       -.19615E-06** at limit **
  15  norm          .10000E-03    2.4988       -.27009E-06** at limit **
  16  norm          3.1305        6.4987        .17458E-06    .99342E-05
  17  norm          17.603        6.6542        .27673E-06    .21145E-03
  18  Prefactor     .10000E-03    1.6334        .37282E-07** at limit **
  19  Prefactor     1.0208        13.976        .16588E-06   -.24790E-03
  20  Prefactor     .10000E-03    70.742       -.73669E-05** at limit **
  21  Prefactor     .98290        56.075       -.20748E-05    .61233E-04
  22  Prefactor     12.794        14.959       -.18046E-07    .10757E-04
  23  Prefactor     6.0076        31.768        .50633E-06    .24333E-04
  24  Prefactor     .10000E-03    24.743       -.14066E-06** at limit **
  25  Prefactor     .10000E-03    56.120        .11902E-04** at limit **
  26  norm          4.5297        1.8230        .13140E-07    .36308E-04
  27  Prefactor     6.0218        4.5955        .54167E-08   -.57121E-05
  28  norm          7.0289        10.607        .10950E-06   -.10106E-04
  29  Normalizat    1.2749        .18188        .29900E-07    .16127E-03
  30  Prefactor     .62941        .22412       -.13173E-07    .77350E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 13.019
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 4.70854
  Prefactor  = 0.0001
  Prefactor  = 29.4865
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 5.60742
  Prefactor  = 0.0001
  Prefactor  = 0.000100002
  Prefactor  = 0.0001
  norm       = 3.98206
  norm       = 0.0001
  norm       = 0.0001
  norm       = 3.13055
  norm       = 17.603
  Prefactor  = 0.0001
  Prefactor  = 1.02076
  Prefactor  = 0.000100002
  Prefactor  = 0.982897
  Prefactor  = 12.7939
  Prefactor  = 6.00762
  Prefactor  = 0.0001
  Prefactor  = 0.000100005
  norm       = 4.52971
  Prefactor  = 6.02184
  norm       = 7.02895
  Normalizat = 1.27487
  Prefactor  = 0.629412
 **********
 **   18 **HESSE 
 **********

 FCN=   5312.141     FROM HESSE     STATUS=OK           594 CALLS     3999 TOTAL
                     EDM=   .40E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          13.019        4.7118        .92625E-04   -1.4986    
   2  Prefactor     .10000E-03    2.6684        .11608E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10000E-03    .76691        .62228E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     4.7085        8.2251        .18548E-03   -1.5274    
   5  Prefactor     .10000E-03    17.621        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     29.487        20.724        .73786E-04   -1.4621    
   7  Prefactor     .10000E-03    38.092        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .10000E-03    2.0550        .10184E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  norm          5.6074        5.6188        .81322E-03   -1.5234    
  10  Prefactor     .10000E-03    168.13        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .10000E-03    47.539        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10000E-03    6.7116        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  norm          3.9821        3.6909        .13063E-03   -1.5309    
  14  norm          .10000E-03    6.9541        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  norm          .10000E-03    12.569        .19007E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          3.1305        5.6456        .22085E-03   -1.5354    
  17  norm          17.603        6.6576        .95457E-04   -1.4869    
  18  Prefactor     .10000E-03    1.6562        .90554E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     1.0208        15.170        .51118E-03   -1.5506    
  20  Prefactor     .10000E-03    71.596        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .98290        54.129        .15038       -1.5510    
  22  Prefactor     12.794        14.950        .11196E-03   -1.4992    
  23  Prefactor     6.0076        31.719        .16383E-03   -1.5218    
  24  Prefactor     .10000E-03    24.905        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     .10000E-03    56.760        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  norm          4.5297        1.8224        .60101E-04   -1.5282    
  27  Prefactor     6.0218        4.5990        .13204E-03   -1.5217    
  28  norm          7.0289        10.606        .15131E-03   -1.5178    
  29  Normalizat    1.2749        .20742        .20202E-03   -.84320    
  30  Prefactor     .62941        .25337        .34481E-03   -1.0636    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 3.97283e-09
Minuit parameter uncertainties:
  1  4.71192
  2  2.26396e-07
  3  7.35816e-08
  4  8.22709
  5  6.67548e-06
  6  20.7294
  7  9.68653e-05
  8  3.06476e-07
  9  5.61936
  10  0.000414123
  11  0.0005973
  12  1.51387e-06
  13  3.69114
  14  7.6892e-06
  15  0.000126823
  16  5.64653
  17  6.6579
  18  5.89036e-06
  19  7.87228
  20  0.000810865
  21  14.6012
  22  14.9548
  23  27.631
  24  9.26561e-06
  25  0.00104334
  26  1.82242
  27  4.59927
  28  10.6092
  29  0.207556
  30  0.253831
Done.

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

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  1.000e-04  1.514e-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:  6.294e-01  2.538e-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.275e+00  2.076e-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.22e-08 ph cm-2 s-1
Energy Flux Upper Limit: 4.05e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/186713/likelihoodResults_304646401_304905601_4FGL_J1304.0+3704_daily_bin252.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.14214779
delta logL = -0.000708317610588

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 5312.141442
delta logL = -2.52624886343e-06

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .14495E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.3935       1.0000          .0000       10.000    
     3 'Normalizat'    1.2749       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .62941       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=   5312.141     FROM MIGRAD    STATUS=CONVERGED    118 CALLS      267 TOTAL
                     EDM=   .49E-11    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10001E-03    4.5047        .89231E-01** at limit **
   2  Index         1.5298        8.7898        .50000       -.30118E-06
   3  Normalizat    1.2749        .25503E-02    .20202E-03   -.20021E-02
   4  Prefactor     .62941        .31745E-02    .34481E-03   -.11698E-02
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000100013
  Index      = 1.52976
  Normalizat = 1.27487
  Prefactor  = 0.629408
 **********
 **   18 **HESSE 
 **********

 FCN=   5312.141     FROM HESSE     STATUS=NOT POSDEF    31 CALLS      298 TOTAL
                     EDM=   .60E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10001E-03    240.42        .49930E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         1.5298        9.1549        .50000       -.76710    
   3  Normalizat    1.2749        .11335E-01    .40405E-04   -.84320    
   4  Prefactor     .62941        .14109E-01    .68963E-04   -1.0636    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 5.97955e-10
Minuit parameter uncertainties:
  1  0.0035614
  2  352.546
  3  0.0113345
  4  0.014109
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/186713': 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) = 5312.14143349
delta logL = 5.98686892772e-06

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  1.000e-04  3.561e-03  1.000e-04  1.000e+04 ( 1.000e-13)
314        Index:  1.530e+00  3.525e+02  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:  6.294e-01  1.411e-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.275e+00  1.133e-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/186713/cmap_HighResolution_304646401_304905601_4FGL_J1304.0+3704_daily_bin252.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='4.05e-03', job_status='DONE', photon_flux_upper_limit='5.22e-08', time_completed='2021-09-06 19:51:13.106952', job_id='186713', GAL2='0.63', fit_tolerance='1e-08', EG2='1.27', EG='1.27', time_epoch_completed='1630983073.11', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.63', dlogl='5.99e-06', ts2='-0.00', photon_index_error='0.00', photon_index='2.44' WHERE bin_id='252' AND source_name='4FGL J1304.0+3704' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 19:51:13 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0207>
Subject: Job 186713: <4FGL_J1304.0+3704_daily_bin252> in cluster <slac> Done

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

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1304.0+3704_daily_bin252 196.008 37.071 304646401 304905601 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 :                                   779.05 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             296.71 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   929 sec.
    Turnaround time :                            931 sec.

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

