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


Performing analysis on: 4FGL_J0958.4+5042_daily_bin1157
RA = 149.606, Dec = 50.7
tmin = 539222401, tmax = 539481601
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='797258', job_status='RUN', time_executed='2021-09-01 17:08:16.833698', time_epoch_executed='1630541296.83' WHERE source_name='4FGL J0958.4+5042' and cadence='daily' and bin_id='1157'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/797258

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/797258/ft1_4FGL_J0958.4+5042_daily_bin1157.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/797258/ft2_4FGL_J0958.4+5042_daily_bin1157.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/797258/ft1_4FGL_J0958.4+5042_daily_bin1157.fits outfile=/scratch/kocevski/797258/ft1_filteredMKT_4FGL_J0958.4+5042_daily_bin1157.fits ra=149.606 dec=50.7 rad=12.0 tmin=539222401.0 tmax=539481601.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.66
user 5.39
sys 0.24

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/797258/ft2_4FGL_J0958.4+5042_daily_bin1157.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/797258/ft2_4FGL_J0958.4+5042_daily_bin1157.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/797258/ft1_filteredMKT_4FGL_J0958.4+5042_daily_bin1157.fits evtable="EVENTS" outfile="/scratch/kocevski/797258/ft1_filtered_4FGL_J0958.4+5042_daily_bin1157.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.53
user 0.35
sys 0.16

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/797258/ft1_filtered_4FGL_J0958.4+5042_daily_bin1157.fits" evtable="EVENTS" scfile=/scratch/kocevski/797258/ft2_4FGL_J0958.4+5042_daily_bin1157.fits sctable="SC_DATA" outfile=/scratch/kocevski/797258/ltcube_539222401_539481601_4FGL_J0958.4+5042_daily_bin1157.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/797258/ft2_4FGL_J0958.4+5042_daily_bin1157.fits
.....................!
real 15.79
user 15.25
sys 0.33

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/797258/ft1_filtered_4FGL_J0958.4+5042_daily_bin1157.fits evtable="EVENTS" scfile=/scratch/kocevski/797258/ft2_4FGL_J0958.4+5042_daily_bin1157.fits sctable="SC_DATA" expcube=/scratch/kocevski/797258/ltcube_539222401_539481601_4FGL_J0958.4+5042_daily_bin1157.fits outfile=/scratch/kocevski/797258/expmap_539222401_539481601_4FGL_J0958.4+5042_daily_bin1157.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/797258/ltcube_539222401_539481601_4FGL_J0958.4+5042_daily_bin1157.fits
.....................!
real 193.94
user 187.43
sys 5.50

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 231 point sources and 0 extended sources

Setting source of interest to:
4FGL J0958.4+5042 @ 149.606 50.7

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/797258/ft1_filtered_4FGL_J0958.4+5042_daily_bin1157.fits scfile=/scratch/kocevski/797258/ft2_4FGL_J0958.4+5042_daily_bin1157.fits outfile=/scratch/kocevski/797258/cmap_539222401_539481601_4FGL_J0958.4+5042_daily_bin1157.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=149.606 yref=50.7 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.55
user 0.39
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/797258/ft1_filtered_4FGL_J0958.4+5042_daily_bin1157.fits scfile=/scratch/kocevski/797258/ft2_4FGL_J0958.4+5042_daily_bin1157.fits outfile=/scratch/kocevski/797258/cmap_HighResolution_539222401_539481601_4FGL_J0958.4+5042_daily_bin1157.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=149.606 yref=50.7 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.41
sys 0.15

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/797258/ft1_filtered_4FGL_J0958.4+5042_daily_bin1157.fits evtable="EVENTS" scfile=/scratch/kocevski/797258/ft2_4FGL_J0958.4+5042_daily_bin1157.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/797258/Model_4FGL_J0958.4+5042_daily_bin1157.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/797258/ft1_filtered_4FGL_J0958.4+5042_daily_bin1157.fits......................!
real 23.68
user 22.14
sys 1.33

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/797258/ft1_filtered_4FGL_J0958.4+5042_daily_bin1157.fits', '/scratch/kocevski/797258/ft2_4FGL_J0958.4+5042_daily_bin1157.fits', expMap='/scratch/kocevski/797258/expmap_539222401_539481601_4FGL_J0958.4+5042_daily_bin1157.fits', expCube='/scratch/kocevski/797258/ltcube_539222401_539481601_4FGL_J0958.4+5042_daily_bin1157.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/797258/Model_4FGL_J0958.4+5042_daily_bin1157.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J0958.4+5042'

4FGL J0958.4+5042
   Spectrum: PowerLaw
369    Prefactor:  1.235e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-12)
370        Index:  2.663e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
371        Scale:  5.744e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/797258/ft1_filtered_4FGL_J0958.4+5042_daily_bin1157.fits
Spacecraft file(s): /scratch/kocevski/797258/ft2_4FGL_J0958.4+5042_daily_bin1157.fits
Exposure map: /scratch/kocevski/797258/expmap_539222401_539481601_4FGL_J0958.4+5042_daily_bin1157.fits
Exposure cube: /scratch/kocevski/797258/ltcube_539222401_539481601_4FGL_J0958.4+5042_daily_bin1157.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/797258/Model_4FGL_J0958.4+5042_daily_bin1157.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) = 1438.69203985

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    16.326       1.0000         .10000E-03   10000.    
     2 'norm      '    4.0079       1.0000         .10000E-03   10000.    
     3 'norm      '    2.9759       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10018E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    3.6408       1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10397E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10082E-03   1.0000         .10000E-03   10000.    
     8 'norm      '    1.9843       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    1.3553       1.0000         .10000E-03   10000.    
    12 'Prefactor '    4.0611       1.0000         .10000E-03   10000.    
    13 'Prefactor '    57.792       1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    15 'norm      '    .10003E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    78.340       1.0000         .10000E-03   10000.    
    17 'Prefactor '    22.248       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    19 'norm      '    2.9395       1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10022E-03   1.0000         .10000E-03   10000.    
    22 'norm      '    1.8731       1.0000         .10000E-03   10000.    
    23 'norm      '    .10035E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10033E-03   1.0000         .10000E-03   10000.    
    25 'Prefactor '    146.31       1.0000         .10000E-03   10000.    
    26 'norm      '    8.4523       1.0000         .10000E-03   10000.    
    27 'Prefactor '    .10100E-03   1.0000         .10000E-03   10000.    
    28 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    29 'Prefactor '    32.352       1.0000         .10000E-03   10000.    
    30 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    31 'norm      '    .10015E-03   1.0000         .10000E-03   10000.    
    32 'norm      '    2.8212       1.0000         .10000E-03   10000.    
    33 'Prefactor '    538.84       1.0000         .10000E-03   10000.    
    34 'Prefactor '    .14545E-03   1.0000         .10000E-03   10000.    
    35 'norm      '    .10028E-03   1.0000         .10000E-03   10000.    
    36 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
    37 'Prefactor '    134.65       1.0000         .10000E-03   10000.    
    38 'Prefactor '    .10006E-03   1.0000         .10000E-03   10000.    
    39 'Normalizat'    .88762E-01   1.0000         .10000E-01   10.000    
    40 'Prefactor '    1.3974       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .7370E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   1438.618     FROM MIGRAD    STATUS=CONVERGED    142 CALLS     7423 TOTAL
                     EDM=   .11E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY= 10.2%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     16.322        1.0179        .17945E-06    .84891E-04
   2  norm          4.0061        1.0480        .35121E-06    .14391E-03
   3  norm          2.9768        1.0302        .45731E-06    .14330E-03
   4  Prefactor     .10000E-03    11.212       -.60650E-05** at limit **
   5  Prefactor     3.6400        3.6631       -.68595E-06    .20195E-04
   6  Prefactor     .10392E-03    73.680       -.51704E-04** at limit **
   7  Prefactor     .10148E-03    47.678        .69021E-04** at limit **
   8  norm          1.9835        .88554        .13532E-06   -.50617E-03
   9  Prefactor     .10011E-03    19.878        .34923E-04** at limit **
  10  Prefactor     .10000E-03    1.0723       -.36311E-05** at limit **
  11  Prefactor     1.3503        1.1307        .12225E-05    .66353E-04
  12  Prefactor     4.0607        4.1068        .42312E-06   -.76031E-04
  13  Prefactor     57.793        1.0626        .29442E-06   -.37060E-04
  14  Prefactor     .10342E-03    23.944        .37983E-04** at limit **
  15  norm          .10830E-03    30.211       -.57718E-04** at limit **
  16  Prefactor     78.341        1.0315        .18687E-06   -.17625E-03
  17  Prefactor     22.246        1.0292        .32665E-06   -.57281E-04
  18  Prefactor     .10000E-03    4.3747        .36018E-06** at limit **
  19  norm          2.9367        1.0483        .53580E-06    .14538E-04
  20  Prefactor     .10024E-03    16.762        .12642E-04** at limit **
  21  Prefactor     .10001E-03    46.050        .70453E-04** at limit **
  22  norm          1.8730        1.5068       -.10596E-06    .92074E-04
  23  norm          .10001E-03    16.049       -.11184E-04** at limit **
  24  Prefactor     .10000E-03    12.613        .55354E-05** at limit **
  25  Prefactor     146.32        2.1538        .11680E-05   -.22607E-02
  26  norm          8.4516        1.0059       -.22798E-06   -.27156E-03
  27  Prefactor     .11770E-03    73.487       -.29247E-04** at limit **
  28  norm          .10012E-03    21.988       -.31232E-04** at limit **
  29  Prefactor     32.349        1.0584       -.39798E-06    .72747E-04
  30  Prefactor     .10000E-03    5.8942        .39691E-05** at limit **
  31  norm          .10000E-03    9.7534        .41784E-05** at limit **
  32  norm          2.8195        1.0248       -.53322E-06   -.24575E-03
  33  Prefactor     538.84        1.2004       -.22061E-06    .15899E-02
  34  Prefactor     .11363E-02    164.03       -.17480E-03** at limit **
  35  norm          .10000E-03    9.3961        .44927E-05** at limit **
  36  Prefactor     .11025E-03    46.181        .36724E-04** at limit **
  37  Prefactor     134.66        1.5613        .77252E-06   -.14147E-02
  38  Prefactor     .10662E-03    109.45       -.78614E-04** at limit **
  39  Normalizat    .88358E-01    .44512       -.64819E-05   -.24246E-04
  40  Prefactor     1.3977        .46379        .48649E-05   -.78541E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 16.3217
  norm       = 4.00613
  norm       = 2.97684
  Prefactor  = 0.0001
  Prefactor  = 3.64
  Prefactor  = 0.000103923
  Prefactor  = 0.000101477
  norm       = 1.98355
  Prefactor  = 0.000100107
  Prefactor  = 0.0001
  Prefactor  = 1.3503
  Prefactor  = 4.06073
  Prefactor  = 57.7932
  Prefactor  = 0.000103424
  norm       = 0.000108301
  Prefactor  = 78.3413
  Prefactor  = 22.2462
  Prefactor  = 0.0001
  norm       = 2.93673
  Prefactor  = 0.00010024
  Prefactor  = 0.000100008
  norm       = 1.87297
  norm       = 0.000100006
  Prefactor  = 0.000100001
  Prefactor  = 146.32
  norm       = 8.4516
  Prefactor  = 0.000117703
  norm       = 0.000100123
  Prefactor  = 32.349
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 2.81949
  Prefactor  = 538.837
  Prefactor  = 0.00113628
  norm       = 0.0001
  Prefactor  = 0.000110248
  Prefactor  = 134.657
  Prefactor  = 0.00010662
  Normalizat = 0.0883581
  Prefactor  = 1.39772
 **********
 **   18 **HESSE 
 **********

 FCN=   1438.618     FROM HESSE     STATUS=NOT POSDEF  1063 CALLS     8486 TOTAL
                     EDM=   .18E-05    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     16.322        17.518        .24781E-02   -1.4900    
   2  norm          4.0061        10.437        .50361E-02   -1.5308    
   3  norm          2.9768        21.071        .58840E-02   -1.5363    
   4  Prefactor     .10000E-03    9.9406        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     3.6400        4.6163        .52930E-02   -1.5326    
   6  Prefactor     .10392E-03    91.165        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10148E-03    125.33        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          1.9835        .98869        .51889E-02   -1.5426    
   9  Prefactor     .10011E-03    8.6601        .47499E-01   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .10000E-03    .94785        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     1.3503        58.748        .93873E-02   -1.5476    
  12  Prefactor     4.0607        4.3513        .50020E-02   -1.5305    
  13  Prefactor     57.793        74.267        .13193E-02   -1.4186    
  14  Prefactor     .10342E-03    39.166        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  norm          .10830E-03    43.019        .90712E-02   -1.5709    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     78.341        148.83        .11343E-02   -1.3935    
  17  Prefactor     22.246        50.846        .21230E-02   -1.4764    
  18  Prefactor     .10000E-03    3.8774        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  norm          2.9367        54.320        .59225E-02   -1.5365    
  20  Prefactor     .10024E-03    40.211        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .10001E-03    135.31        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  norm          1.8730        1.7653        .76071E-02   -1.5434    
  23  norm          .10001E-03    14.292        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     .10000E-03    11.522        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     146.32        295.48        .83285E-03   -1.3283    
  26  norm          8.4516        9.5340        .34472E-02   -1.5126    
  27  Prefactor     .11770E-03    218.78        .90712E-02   -1.5709    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  norm          .10012E-03    19.615        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  29  Prefactor     32.349        64.580        .17612E-02   -1.4570    
  30  Prefactor     .10000E-03    5.2155        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  31  norm          .10000E-03    8.5809        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  32  norm          2.8195        10.224        .60536E-02   -1.5372    
  33  Prefactor     538.84        836.57        .44289E-03   -1.1023    
  34  Prefactor     .11363E-02    682.81        .90712E-02   -1.5702    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  35  norm          .10000E-03    8.2766        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  36  Prefactor     .11025E-03    170.81        .90712E-02   -1.5709    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  37  Prefactor     134.66        206.09        .86764E-03   -1.3382    
  38  Prefactor     .10662E-03    259.08        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  39  Normalizat    .88358E-01    9.2791        .16369       -1.3934    
  40  Prefactor     1.3977        1.9294        .51322E-01   -.80446    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 1.79846e-06
Minuit parameter uncertainties:
  1  17.5233
  2  10.4422
  3  15.8474
  4  5.20872e-05
  5  4.61674
  6  0.037879
  7  0.0272676
  8  0.988702
  9  0.00192154
  10  1.18237e-05
  11  17.8313
  12  4.35161
  13  74.3865
  14  0.0231765
  15  0.0378219
  16  149.544
  17  50.9448
  18  8.64241e-06
  19  25.2867
  20  0.00621311
  21  0.00208776
  22  1.76538
  23  0.000589068
  24  0.000168643
  25  298.547
  26  9.5357
  27  0.124926
  28  0.00311071
  29  64.7201
  30  2.04309e-05
  31  7.83428e-08
  32  10.2305
  33  856.998
  34  1.70212
  35  8.26844e-05
  36  0.0839144
  37  207.209
  38  0.0831866
  39  2.26312
  40  2.04604
Done.

MINUIT Return Code (Fixed Index): 102
logL (Fixed Index) = 1438.6178879

Extracting fit parameters...

4FGL J0958.4+5042
   Spectrum: PowerLaw
369    Prefactor:  1.000e-04  1.686e-04  1.000e-04  1.000e+04 ( 1.000e-12)
370        Index:  2.663e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
371        Scale:  5.744e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
734    Prefactor:  1.398e+00  2.046e+00  0.000e+00  1.000e+01 ( 1.000e+00)
735        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
736        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
733   Normalization:  8.836e-02  2.263e+00  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 149.606 50.700
Photon Flux Upper Limit: 2.26e-07 ph cm-2 s-1
Energy Flux Upper Limit: 1.77e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/797258/likelihoodResults_539222401_539481601_4FGL_J0958.4+5042_daily_bin1157.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) = 1438.61825995
delta logL = -0.000372059246729

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 1438.61788847
delta logL = -5.7192710301e-07

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10008E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.6549       1.0000          .0000       10.000    
     3 'Normalizat'    .87958E-01   1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.3982       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .7370E+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=   1438.618     FROM MIGRAD    STATUS=CONVERGED     93 CALLS      256 TOTAL
                     EDM=   .28E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10058E-03    331.72        .13152E-02** at limit **
   2  Index         2.6033        7.0555        .50000        .44633E-05
   3  Normalizat    .88358E-01    .40478E-01    .68511E-02    .12009E-03
   4  Prefactor     1.3977        .49825E-01    .22686E-03   -.91330E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000100576
  Index      = 2.60328
  Normalizat = 0.0883577
  Prefactor  = 1.39772
 **********
 **   18 **HESSE 
 **********

 FCN=   1438.618     FROM HESSE     STATUS=NOT POSDEF    31 CALLS      287 TOTAL
                     EDM=   .13E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10058E-03    1243.1        .26304E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.6033        7.2026        .50000       -.49991    
   3  Normalizat    .88358E-01    .88830E-01    .13702E-02   -1.3934    
   4  Prefactor     1.3977        .10946        .90745E-05   -.80446    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 1.2571e-08
Minuit parameter uncertainties:
  1  0.0547014
  2  2053.7
  3  0.0889808
  4  0.109477
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/797258': 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) = 1438.61788785
delta logL = 4.9170694183e-08

Extracting fit parameters...

4FGL J0958.4+5042
   Spectrum: PowerLaw
369    Prefactor:  1.006e-04  5.470e-02  1.000e-04  1.000e+04 ( 1.000e-12)
370        Index:  2.603e+00  2.054e+03  0.000e+00  1.000e+01 (-1.000e+00)
371        Scale:  5.744e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
734    Prefactor:  1.398e+00  1.095e-01  0.000e+00  1.000e+01 ( 1.000e+00)
735        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
736        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
733   Normalization:  8.836e-02  8.898e-02  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 149.606 50.700

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/797258/cmap_HighResolution_539222401_539481601_4FGL_J0958.4+5042_daily_bin1157.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='1.77e-02', job_status='DONE', photon_flux_upper_limit='2.26e-07', time_completed='2021-09-01 17:19:35.794358', job_id='797258', GAL2='1.40', fit_tolerance='1e-08', EG2='0.09', EG='0.09', time_epoch_completed='1630541975.79', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='102', GAL='1.40', dlogl='4.92e-08', ts2='-0.00', photon_index_error='0.00', photon_index='2.66' WHERE bin_id='1157' AND source_name='4FGL J0958.4+5042' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Wed Sep  1 17:19:35 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0042>
Subject: Job 797258: <4FGL_J0958.4+5042_daily_bin1157> in cluster <slac> Done

Job <4FGL_J0958.4+5042_daily_bin1157> was submitted from host <rhel6-64j> by user <kocevski> in cluster <slac> at Wed Sep  1 17:05:24 2021
Job was executed on host(s) <bullet0042>, in queue <medium>, as user <kocevski> in cluster <slac> at Wed Sep  1 17:05:36 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Wed Sep  1 17:05:36 2021
Terminated at Wed Sep  1 17:19:36 2021
Results reported at Wed Sep  1 17:19:36 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J0958.4+5042_daily_bin1157 149.606 50.7 539222401 539481601 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J0958.4+5042 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   675.00 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             293.97 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   840 sec.
    Turnaround time :                            852 sec.

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

