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


Performing analysis on: 4FGL_J1304.0+3704_daily_bin723
RA = 196.008, Dec = 37.071
tmin = 426729601, tmax = 426988801
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='190740', job_status='RUN', time_executed='2021-09-06 19:54:09.524903', time_epoch_executed='1630983249.52' WHERE source_name='4FGL J1304.0+3704' and cadence='daily' and bin_id='723'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/190740

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/190740/ft1_4FGL_J1304.0+3704_daily_bin723.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/190740/ft2_4FGL_J1304.0+3704_daily_bin723.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/190740/ft1_4FGL_J1304.0+3704_daily_bin723.fits outfile=/scratch/kocevski/190740/ft1_filteredMKT_4FGL_J1304.0+3704_daily_bin723.fits ra=196.008 dec=37.071 rad=12.0 tmin=426729601.0 tmax=426988801.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 5.80
user 5.44
sys 0.29

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/190740/ft2_4FGL_J1304.0+3704_daily_bin723.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/190740/ft1_filteredMKT_4FGL_J1304.0+3704_daily_bin723.fits evtable="EVENTS" outfile="/scratch/kocevski/190740/ft1_filtered_4FGL_J1304.0+3704_daily_bin723.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.51
user 0.32
sys 0.17

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/190740/ft1_filtered_4FGL_J1304.0+3704_daily_bin723.fits" evtable="EVENTS" scfile=/scratch/kocevski/190740/ft2_4FGL_J1304.0+3704_daily_bin723.fits sctable="SC_DATA" outfile=/scratch/kocevski/190740/ltcube_426729601_426988801_4FGL_J1304.0+3704_daily_bin723.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/190740/ft2_4FGL_J1304.0+3704_daily_bin723.fits
.....................!
real 17.55
user 17.07
sys 0.34

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/190740/ft1_filtered_4FGL_J1304.0+3704_daily_bin723.fits evtable="EVENTS" scfile=/scratch/kocevski/190740/ft2_4FGL_J1304.0+3704_daily_bin723.fits sctable="SC_DATA" expcube=/scratch/kocevski/190740/ltcube_426729601_426988801_4FGL_J1304.0+3704_daily_bin723.fits outfile=/scratch/kocevski/190740/expmap_426729601_426988801_4FGL_J1304.0+3704_daily_bin723.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/190740/ltcube_426729601_426988801_4FGL_J1304.0+3704_daily_bin723.fits
.....................!
real 192.54
user 186.47
sys 5.27

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/190740/ft1_filtered_4FGL_J1304.0+3704_daily_bin723.fits scfile=/scratch/kocevski/190740/ft2_4FGL_J1304.0+3704_daily_bin723.fits outfile=/scratch/kocevski/190740/cmap_426729601_426988801_4FGL_J1304.0+3704_daily_bin723.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.56
user 0.39
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/190740/ft1_filtered_4FGL_J1304.0+3704_daily_bin723.fits scfile=/scratch/kocevski/190740/ft2_4FGL_J1304.0+3704_daily_bin723.fits outfile=/scratch/kocevski/190740/cmap_HighResolution_426729601_426988801_4FGL_J1304.0+3704_daily_bin723.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.60
user 0.39
sys 0.16

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

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

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    21.158       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .11793E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    11.485       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10007E-03   1.0000         .10000E-03   10000.    
     9 'norm      '    4.2782       1.0000         .10000E-03   10000.    
    10 'Prefactor '    44.488       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    13 'norm      '    .13708E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    .10005E-03   1.0000         .10000E-03   10000.    
    15 'norm      '    9.1999       1.0000         .10000E-03   10000.    
    16 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    2.8584       1.0000         .10000E-03   10000.    
    18 'Prefactor '    3.2822       1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10010E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    23.832       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    11.930       1.0000         .10000E-03   10000.    
    25 'Prefactor '    86.002       1.0000         .10000E-03   10000.    
    26 'norm      '    1.9382       1.0000         .10000E-03   10000.    
    27 'Prefactor '    .10019E-03   1.0000         .10000E-03   10000.    
    28 'norm      '    35.061       1.0000         .10000E-03   10000.    
    29 'Normalizat'    1.3818       1.0000         .10000E-01   10.000    
    30 'Prefactor '    .67564       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=   4301.734     FROM MIGRAD    STATUS=CONVERGED    729 CALLS     3869 TOTAL
                     EDM=   .32E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.9%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          21.154        7.2666        .36309E-06    .26374E-03
   2  Prefactor     .10000E-03    3.3754       -.30223E-06** at limit **
   3  Prefactor     .10000E-03    2.7170        .17578E-06** at limit **
   4  Prefactor     .10000E-03    6.6657       -.45073E-06** at limit **
   5  Prefactor     .10000E-03    21.861       -.33566E-06** at limit **
   6  Prefactor     11.480        25.777        .18794E-06   -.10574E-05
   7  Prefactor     .10000E-03    27.084       -.16272E-06** at limit **
   8  Prefactor     .10000E-03    4.0436       -.34299E-06** at limit **
   9  norm          4.2782        4.6712        .74567E-07    .32467E-04
  10  Prefactor     44.509        75.214        .10953E-05    .70410E-05
  11  Prefactor     .10000E-03    17.311       -.36813E-06** at limit **
  12  Prefactor     .10000E-03    17.724       -.14926E-06** at limit **
  13  norm          .10001E-03    5.6599        .12580E-05** at limit **
  14  norm          .10000E-03    17.143        .22857E-06** at limit **
  15  norm          9.2019        6.0220        .16567E-06   -.15979E-04
  16  norm          .10000E-03    5.7403       -.20465E-06** at limit **
  17  norm          2.8585        4.3247        .17293E-06    .89326E-04
  18  Prefactor     3.2834        4.9127        .12797E-05    .30786E-03
  19  Prefactor     .10000E-03    25.110       -.42092E-06** at limit **
  20  Prefactor     .10000E-03    22.545       -.83786E-07** at limit **
  21  Prefactor     .10000E-03    31.649        .30360E-06** at limit **
  22  Prefactor     23.833        32.802        .87900E-06    .21590E-05
  23  Prefactor     .10000E-03    15.437       -.15362E-08** at limit **
  24  Prefactor     11.934        45.007       -.30450E-06    .39286E-05
  25  Prefactor     86.255        140.36        .56463E-05    .69233E-04
  26  norm          1.9380        2.0754        .37199E-06    .55495E-03
  27  Prefactor     .10000E-03    3.3761       -.57412E-07** at limit **
  28  norm          35.060        27.762        .14402E-06    .25434E-04
  29  Normalizat    1.3811        .26608       -.10580E-04    .11580E-03
  30  Prefactor     .67640        .30281        .15903E-04    .28392E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 21.1535
  Prefactor  = 0.0001
  Prefactor  = 0.000100001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 11.4803
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 4.27817
  Prefactor  = 44.5088
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.000100008
  norm       = 0.0001
  norm       = 9.20192
  norm       = 0.0001
  norm       = 2.85845
  Prefactor  = 3.2834
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 23.833
  Prefactor  = 0.0001
  Prefactor  = 11.9338
  Prefactor  = 86.2554
  norm       = 1.93803
  Prefactor  = 0.0001
  norm       = 35.0602
  Normalizat = 1.38108
  Prefactor  = 0.676398
 **********
 **   18 **HESSE 
 **********

 FCN=   4301.734     FROM HESSE     STATUS=OK           586 CALLS     4455 TOTAL
                     EDM=   .10E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          21.154        6.8568        .87078E-04   -1.4788    
   2  Prefactor     .10000E-03    3.3826        .11772E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10000E-03    5.6118        .19743E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    6.6956        .16549E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10000E-03    21.893        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     11.480        25.765        .11821E-03   -1.5030    
   7  Prefactor     .10000E-03    27.088        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .10000E-03    4.0579        .12881E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  norm          4.2782        4.6626        .14289E-03   -1.5294    
  10  Prefactor     44.509        75.196        .60108E-04   -1.4373    
  11  Prefactor     .10000E-03    17.341        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10000E-03    17.778        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  norm          .10001E-03    14.334        .29332E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          .10000E-03    17.227        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  norm          9.2019        5.9908        .12022E-03   -1.5101    
  16  norm          .10000E-03    5.7502        .15316E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          2.8585        4.3125        .16290E-03   -1.5370    
  18  Prefactor     3.2834        4.8850        .16434E-03   -1.5346    
  19  Prefactor     .10000E-03    25.196        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .10000E-03    22.573        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .10000E-03    31.653        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     23.833        32.636        .82053E-04   -1.4731    
  23  Prefactor     .10000E-03    15.441        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     11.934        44.799        .11598E-03   -1.5017    
  25  Prefactor     86.255        140.89        .21660E-03   -1.3848    
  26  norm          1.9380        2.0709        .94099E-04   -1.5430    
  27  Prefactor     .10000E-03    3.3984        .11767E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  norm          35.060        27.748        .67679E-04   -1.4523    
  29  Normalizat    1.3811        .26707        .22456E-03   -.81177    
  30  Prefactor     .67640        .30381        .36449E-03   -1.0446    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.04617e-09
Minuit parameter uncertainties:
  1  6.85703
  2  1.46992e-05
  3  0.000147527
  4  4.24429e-05
  5  2.22145e-05
  6  25.79
  7  4.69839e-06
  8  2.33965e-05
  9  4.66303
  10  75.3573
  11  5.64663e-05
  12  4.69494e-05
  13  0.000692712
  14  1.08909e-05
  15  5.99116
  16  3.26838e-05
  17  4.31294
  18  4.88564
  19  0.000146231
  20  1.56174e-05
  21  2.56962e-06
  22  32.6606
  23  4.19331e-06
  24  44.9254
  25  141.443
  26  2.07103
  27  2.90383e-07
  28  27.7578
  29  0.267337
  30  0.304553
Done.

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

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  1.000e-04  4.695e-05  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.764e-01  3.046e-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.381e+00  2.673e-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: 1.06e-07 ph cm-2 s-1
Energy Flux Upper Limit: 8.23e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/190740/likelihoodResults_426729601_426988801_4FGL_J1304.0+3704_daily_bin723.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) = 4301.73447944
delta logL = -0.00026789601543

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 4301.73421388
delta logL = -2.33862101595e-06

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10024E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    3.1232       1.0000          .0000       10.000    
     3 'Normalizat'    1.3811       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .67640       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=   4301.734     FROM MIGRAD    STATUS=CONVERGED     97 CALLS      293 TOTAL
                     EDM=   .21E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .11611E-03    2.7697        .18142E-01** at limit **
   2  Index         2.7785        6.2945        .50000        .17008E-04
   3  Normalizat    1.3811        .24429E-02    .22456E-03   -.10597E-03
   4  Prefactor     .67640        .28900E-02    .36448E-03   -.85715E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000116112
  Index      = 2.77846
  Normalizat = 1.38108
  Prefactor  = 0.676399
 **********
 **   18 **HESSE 
 **********

 FCN=   4301.734     FROM HESSE     STATUS=NOT POSDEF    29 CALLS      322 TOTAL
                     EDM=   .77E-06    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .11611E-03    770.99        .46988E-03   -1.5707    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.7785        6.8956        .50000       -.46040    
   3  Normalizat    1.3811        .43596E-01    .44913E-04   -.81177    
   4  Prefactor     .67640        .51505E-01    .14579E-04   -1.0446    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 7.71898e-07
Minuit parameter uncertainties:
  1  0.225876
  2  1938.49
  3  0.0435972
  4  0.0515083
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/190740': 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) = 4301.73421293
delta logL = -1.38338964462e-06

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  1.161e-04  2.259e-01  1.000e-04  1.000e+04 ( 1.000e-13)
314        Index:  2.778e+00  1.938e+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:  6.764e-01  5.151e-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.381e+00  4.360e-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/190740/cmap_HighResolution_426729601_426988801_4FGL_J1304.0+3704_daily_bin723.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='8.23e-03', job_status='DONE', photon_flux_upper_limit='1.06e-07', time_completed='2021-09-06 20:06:03.805831', job_id='190740', GAL2='0.68', fit_tolerance='1e-08', EG2='1.38', EG='1.38', time_epoch_completed='1630983963.81', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.68', dlogl='-1.38e-06', ts2='-0.00', photon_index_error='0.00', photon_index='2.44' WHERE bin_id='723' AND source_name='4FGL J1304.0+3704' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 20:06:03 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0089>
Subject: Job 190740: <4FGL_J1304.0+3704_daily_bin723> in cluster <slac> Done

Job <4FGL_J1304.0+3704_daily_bin723> was submitted from host <rhel6-64j> by user <kocevski> in cluster <slac> at Mon Sep  6 19:50:16 2021
Job was executed on host(s) <bullet0089>, in queue <medium>, as user <kocevski> in cluster <slac> at Mon Sep  6 19:50:23 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Mon Sep  6 19:50:23 2021
Terminated at Mon Sep  6 20:06:04 2021
Results reported at Mon Sep  6 20:06:04 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1304.0+3704_daily_bin723 196.008 37.071 426729601 426988801 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 :                                   711.00 sec.
    Max Memory :                                 1094 MB
    Average Memory :                             276.63 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   941 sec.
    Turnaround time :                            948 sec.

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

