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


Performing analysis on: 4FGL_J1304.0+3704_daily_bin742
RA = 196.008, Dec = 37.071
tmin = 431654401, tmax = 431913601
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='190766', job_status='RUN', time_executed='2021-09-06 19:53:24.298760', time_epoch_executed='1630983204.3' WHERE source_name='4FGL J1304.0+3704' and cadence='daily' and bin_id='742'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/190766

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/190766/ft1_4FGL_J1304.0+3704_daily_bin742.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/190766/ft2_4FGL_J1304.0+3704_daily_bin742.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/190766/ft1_4FGL_J1304.0+3704_daily_bin742.fits outfile=/scratch/kocevski/190766/ft1_filteredMKT_4FGL_J1304.0+3704_daily_bin742.fits ra=196.008 dec=37.071 rad=12.0 tmin=431654401.0 tmax=431913601.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 6.15
user 5.93
sys 0.19

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

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

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/190766/ft1_filtered_4FGL_J1304.0+3704_daily_bin742.fits" evtable="EVENTS" scfile=/scratch/kocevski/190766/ft2_4FGL_J1304.0+3704_daily_bin742.fits sctable="SC_DATA" outfile=/scratch/kocevski/190766/ltcube_431654401_431913601_4FGL_J1304.0+3704_daily_bin742.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/190766/ft2_4FGL_J1304.0+3704_daily_bin742.fits
.....................!
real 14.21
user 13.80
sys 0.35

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/190766/ft1_filtered_4FGL_J1304.0+3704_daily_bin742.fits evtable="EVENTS" scfile=/scratch/kocevski/190766/ft2_4FGL_J1304.0+3704_daily_bin742.fits sctable="SC_DATA" expcube=/scratch/kocevski/190766/ltcube_431654401_431913601_4FGL_J1304.0+3704_daily_bin742.fits outfile=/scratch/kocevski/190766/expmap_431654401_431913601_4FGL_J1304.0+3704_daily_bin742.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/190766/ltcube_431654401_431913601_4FGL_J1304.0+3704_daily_bin742.fits
.....................!
real 193.37
user 187.76
sys 5.04

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/190766/ft1_filtered_4FGL_J1304.0+3704_daily_bin742.fits scfile=/scratch/kocevski/190766/ft2_4FGL_J1304.0+3704_daily_bin742.fits outfile=/scratch/kocevski/190766/cmap_431654401_431913601_4FGL_J1304.0+3704_daily_bin742.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.39
sys 0.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/190766/ft1_filtered_4FGL_J1304.0+3704_daily_bin742.fits scfile=/scratch/kocevski/190766/ft2_4FGL_J1304.0+3704_daily_bin742.fits outfile=/scratch/kocevski/190766/cmap_HighResolution_431654401_431913601_4FGL_J1304.0+3704_daily_bin742.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/190766/ft1_filtered_4FGL_J1304.0+3704_daily_bin742.fits evtable="EVENTS" scfile=/scratch/kocevski/190766/ft2_4FGL_J1304.0+3704_daily_bin742.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/190766/Model_4FGL_J1304.0+3704_daily_bin742.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/190766/ft1_filtered_4FGL_J1304.0+3704_daily_bin742.fits.....................!
real 40.40
user 38.95
sys 1.26

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

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    16.207       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .31218E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .20105       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10017E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     9 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10012E-03   1.0000         .10000E-03   10000.    
    13 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    10.411       1.0000         .10000E-03   10000.    
    15 'norm      '    5.4226       1.0000         .10000E-03   10000.    
    16 'norm      '    .10062E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    .10028E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    1.4823       1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10006E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    54.846       1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10017E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    .11766E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    22.017       1.0000         .10000E-03   10000.    
    25 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    26 'norm      '    2.7034       1.0000         .10000E-03   10000.    
    27 'Prefactor '    .93384E-01   1.0000         .10000E-03   10000.    
    28 'norm      '    .10010E-03   1.0000         .10000E-03   10000.    
    29 'Normalizat'    1.5389       1.0000         .10000E-01   10.000    
    30 'Prefactor '    .45338       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5990E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   4234.709     FROM MIGRAD    STATUS=CONVERGED    161 CALLS     3361 TOTAL
                     EDM=   .33E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  4.4%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          16.207        6.4940       -.25820E-06   -.41206E-03
   2  Prefactor     .10000E-03    7.4062        .29919E-06** at limit **
   3  Prefactor     .10000E-03    1.6719       -.26462E-06** at limit **
   4  Prefactor     .10017E-03    .92553       -.44061E-06** at limit **
   5  Prefactor     .10000E-03    13.159        .12522E-05** at limit **
   6  Prefactor     .10145E-03    1452.1       -.13372E-04** at limit **
   7  Prefactor     .10155E-03    110.16        .30707E-04** at limit **
   8  Prefactor     .10000E-03    2.5676       -.58927E-06** at limit **
   9  norm          .10000E-03    4.5473        .99933E-06** at limit **
  10  Prefactor     .10000E-03    17.688        .91065E-05** at limit **
  11  Prefactor     .10000E-03    30.156       -.22607E-05** at limit **
  12  Prefactor     .10014E-03    5.6505       -.23762E-05** at limit **
  13  norm          .10000E-03    1.9855        .13975E-06** at limit **
  14  norm          10.410        1.0128        .55789E-07   -.31825E-05
  15  norm          5.4217        4.7033        .98539E-06   -.77514E-04
  16  norm          .10000E-03    5.5238        .18878E-05** at limit **
  17  norm          .10000E-03    4.8077       -.17930E-05** at limit **
  18  Prefactor     1.4838        3.4722        .10125E-06   -.14729E-04
  19  Prefactor     .10003E-03    4.9083       -.26454E-05** at limit **
  20  Prefactor     54.779        6.4139       -.22724E-06   -.99987E-03
  21  Prefactor     .10001E-03    45.050       -.60220E-05** at limit **
  22  Prefactor     .10000E-03    10.509        .24657E-05** at limit **
  23  Prefactor     .10525E-03    35.557        .17804E-04** at limit **
  24  Prefactor     22.017        1.2205       -.18235E-06    .15522E-03
  25  Prefactor     .10229E-03    49.493        .85358E-05** at limit **
  26  norm          2.7031        1.6443       -.33114E-06    .58044E-04
  27  Prefactor     .84305E-01    .80763        .18129E-05   -.10638E-04
  28  norm          .10005E-03    4.8244       -.26565E-05** at limit **
  29  Normalizat    1.5389        .25385       -.27319E-05   -.40827E-04
  30  Prefactor     .45363        .29664        .93538E-05   -.29301E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 16.2068
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.000100168
  Prefactor  = 0.000100002
  Prefactor  = 0.000101449
  Prefactor  = 0.000101545
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.000100001
  Prefactor  = 0.000100002
  Prefactor  = 0.000100136
  norm       = 0.0001
  norm       = 10.41
  norm       = 5.42169
  norm       = 0.0001
  norm       = 0.0001
  Prefactor  = 1.48379
  Prefactor  = 0.000100026
  Prefactor  = 54.7788
  Prefactor  = 0.000100014
  Prefactor  = 0.0001
  Prefactor  = 0.000105248
  Prefactor  = 22.0166
  Prefactor  = 0.000102292
  norm       = 2.70309
  Prefactor  = 0.0843055
  norm       = 0.000100053
  Normalizat = 1.53886
  Prefactor  = 0.453628
 **********
 **   18 **HESSE 
 **********

 FCN=   4234.709     FROM HESSE     STATUS=OK           652 CALLS     4013 TOTAL
                     EDM=   .13E-06    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          16.207        6.5558        .24872E-02   -1.4903    
   2  Prefactor     .10000E-03    7.3347        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10000E-03    1.6626        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10017E-03    11.044        .81851E-01   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10000E-03    13.314        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10145E-03    23.023        .99824E-01   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10155E-03    122.22        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .10000E-03    2.5678        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  norm          .10000E-03    4.4776        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .10000E-03    17.769        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .10000E-03    30.398        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10014E-03    14.756        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  norm          .10000E-03    1.9824        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          10.410        13.473        .31044E-02   -1.5063    
  15  norm          5.4217        4.7610        .43141E-02   -1.5242    
  16  norm          .10000E-03    5.5161        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          .10000E-03    4.7103        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     1.4838        3.5298        .88117E-02   -1.5464    
  19  Prefactor     .10003E-03    14.579        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     54.779        54.470        .13541E-02   -1.4226    
  21  Prefactor     .10001E-03    45.380        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     .10000E-03    10.499        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .10525E-03    85.521        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     22.017        28.745        .21341E-02   -1.4769    
  25  Prefactor     .10229E-03    72.572        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  norm          2.7031        1.6497        .61937E-02   -1.5379    
  27  Prefactor     .84305E-01    3.8918        .72540E-01   -1.5650    
  28  norm          .10005E-03    14.507        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  29  Normalizat    1.5389        .22751        .44763E-01   -.76692    
  30  Prefactor     .45363        .26660        .91834E-01   -1.1415    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.2894e-07
Minuit parameter uncertainties:
  1  6.55607
  2  5.72986e-08
  3  9.15555e-07
  4  0.00272515
  5  0.000364934
  6  0.0115544
  7  0.0275436
  8  1.93515e-06
  9  3.78523e-06
  10  0.000237265
  11  0.000526549
  12  0.00283818
  13  4.01743e-07
  14  13.4774
  15  4.76136
  16  9.47283e-06
  17  8.24444e-06
  18  3.53031
  19  0.00122546
  20  54.5191
  21  0.00158049
  22  4.00465e-05
  23  0.0424319
  24  28.7626
  25  0.0258277
  26  1.64974
  27  1.145
  28  0.00175571
  29  0.227662
  30  0.267332
Done.

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

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  1.001e-04  2.838e-03  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:  4.536e-01  2.673e-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.539e+00  2.277e-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: 7.53e-08 ph cm-2 s-1
Energy Flux Upper Limit: 5.83e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/190766/likelihoodResults_431654401_431913601_4FGL_J1304.0+3704_daily_bin742.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) = 4234.70939614
delta logL = -0.00031944777038

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 4234.70907788
delta logL = -1.18551452033e-06

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10878E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.4054       1.0000          .0000       10.000    
     3 'Normalizat'    1.5385       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .45405       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=   4234.709     FROM MIGRAD    STATUS=CONVERGED     94 CALLS      248 TOTAL
                     EDM=   .25E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10220E-03    9.6438        .18142E-01** at limit **
   2  Index         2.3352        6.0959        .50000        .13325E-04
   3  Normalizat    1.5389        .38714E-02    .19786E-03   -.13719E-03
   4  Prefactor     .45363        .45931E-02    .40696E-03   -.80259E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000102198
  Index      = 2.33518
  Normalizat = 1.53886
  Prefactor  = 0.453628
 **********
 **   18 **HESSE 
 **********

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

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10220E-03    413.86        .51044E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.3352        5.5034        .50000       -.56210    
   3  Normalizat    1.5389        .25706E-01    .39571E-04   -.76692    
   4  Prefactor     .45363        .30497E-01    .16278E-04   -1.1415    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 7.76898e-09
Minuit parameter uncertainties:
  1  0.0607427
  2  583.86
  3  0.0257061
  4  0.030498
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/190766': 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) = 4234.70907638
delta logL = 3.08376911562e-07

Extracting fit parameters...

4FGL J1304.0+3704
   Spectrum: PowerLaw
313    Prefactor:  1.022e-04  6.074e-02  1.000e-04  1.000e+04 ( 1.000e-13)
314        Index:  2.335e+00  5.839e+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:  4.536e-01  3.050e-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.539e+00  2.571e-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/190766/cmap_HighResolution_431654401_431913601_4FGL_J1304.0+3704_daily_bin742.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='5.83e-03', job_status='DONE', photon_flux_upper_limit='7.53e-08', time_completed='2021-09-06 20:04:54.239055', job_id='190766', GAL2='0.45', fit_tolerance='1e-08', EG2='1.54', EG='1.54', time_epoch_completed='1630983894.24', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.45', dlogl='3.08e-07', ts2='-0.00', photon_index_error='0.00', photon_index='2.44' WHERE bin_id='742' AND source_name='4FGL J1304.0+3704' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 20:04:54 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0042>
Subject: Job 190766: <4FGL_J1304.0+3704_daily_bin742> in cluster <slac> Done

Job <4FGL_J1304.0+3704_daily_bin742> was submitted from host <rhel6-64j> by user <kocevski> in cluster <slac> at Mon Sep  6 19:50:18 2021
Job was executed on host(s) <bullet0042>, in queue <medium>, as user <kocevski> in cluster <slac> at Mon Sep  6 19:50:29 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:29 2021
Terminated at Mon Sep  6 20:04:55 2021
Results reported at Mon Sep  6 20:04:55 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1304.0+3704_daily_bin742 196.008 37.071 431654401 431913601 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 :                                   688.08 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             310.92 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   865 sec.
    Turnaround time :                            877 sec.

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

