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


Performing analysis on: 4FGL_J1257.2+3646_daily_bin973
RA = 194.31, Dec = 36.7706
tmin = 491529601, tmax = 491788801
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='38388', job_status='RUN', time_executed='2021-09-06 11:45:46.737657', time_epoch_executed='1630953946.74' WHERE source_name='4FGL J1257.2+3646' and cadence='daily' and bin_id='973'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/38388

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/38388/ft1_4FGL_J1257.2+3646_daily_bin973.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/38388/ft2_4FGL_J1257.2+3646_daily_bin973.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/38388/ft1_4FGL_J1257.2+3646_daily_bin973.fits outfile=/scratch/kocevski/38388/ft1_filteredMKT_4FGL_J1257.2+3646_daily_bin973.fits ra=194.31 dec=36.7706 rad=12.0 tmin=491529601.0 tmax=491788801.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.49
user 3.26
sys 0.20

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/38388/ft2_4FGL_J1257.2+3646_daily_bin973.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/38388/ft2_4FGL_J1257.2+3646_daily_bin973.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/38388/ft1_filteredMKT_4FGL_J1257.2+3646_daily_bin973.fits evtable="EVENTS" outfile="/scratch/kocevski/38388/ft1_filtered_4FGL_J1257.2+3646_daily_bin973.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.54
user 0.34
sys 0.15

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/38388/ft1_filtered_4FGL_J1257.2+3646_daily_bin973.fits" evtable="EVENTS" scfile=/scratch/kocevski/38388/ft2_4FGL_J1257.2+3646_daily_bin973.fits sctable="SC_DATA" outfile=/scratch/kocevski/38388/ltcube_491529601_491788801_4FGL_J1257.2+3646_daily_bin973.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/38388/ft2_4FGL_J1257.2+3646_daily_bin973.fits
.....................!
real 12.32
user 11.89
sys 0.32

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/38388/ft1_filtered_4FGL_J1257.2+3646_daily_bin973.fits evtable="EVENTS" scfile=/scratch/kocevski/38388/ft2_4FGL_J1257.2+3646_daily_bin973.fits sctable="SC_DATA" expcube=/scratch/kocevski/38388/ltcube_491529601_491788801_4FGL_J1257.2+3646_daily_bin973.fits outfile=/scratch/kocevski/38388/expmap_491529601_491788801_4FGL_J1257.2+3646_daily_bin973.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/38388/ltcube_491529601_491788801_4FGL_J1257.2+3646_daily_bin973.fits
.....................!
real 191.66
user 185.57
sys 5.17

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

Setting source of interest to:
4FGL J1257.2+3646 @ 194.31 36.7706

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/38388/ft1_filtered_4FGL_J1257.2+3646_daily_bin973.fits scfile=/scratch/kocevski/38388/ft2_4FGL_J1257.2+3646_daily_bin973.fits outfile=/scratch/kocevski/38388/cmap_491529601_491788801_4FGL_J1257.2+3646_daily_bin973.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=194.31 yref=36.7706 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 1.20
user 0.38
sys 0.17

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/38388/ft1_filtered_4FGL_J1257.2+3646_daily_bin973.fits scfile=/scratch/kocevski/38388/ft2_4FGL_J1257.2+3646_daily_bin973.fits outfile=/scratch/kocevski/38388/cmap_HighResolution_491529601_491788801_4FGL_J1257.2+3646_daily_bin973.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=194.31 yref=36.7706 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 1.00
user 0.39
sys 0.17

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/38388/ft1_filtered_4FGL_J1257.2+3646_daily_bin973.fits evtable="EVENTS" scfile=/scratch/kocevski/38388/ft2_4FGL_J1257.2+3646_daily_bin973.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/38388/Model_4FGL_J1257.2+3646_daily_bin973.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/38388/ft1_filtered_4FGL_J1257.2+3646_daily_bin973.fits.....................!
real 52.60
user 42.80
sys 1.30

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/38388/ft1_filtered_4FGL_J1257.2+3646_daily_bin973.fits', '/scratch/kocevski/38388/ft2_4FGL_J1257.2+3646_daily_bin973.fits', expMap='/scratch/kocevski/38388/expmap_491529601_491788801_4FGL_J1257.2+3646_daily_bin973.fits', expCube='/scratch/kocevski/38388/ltcube_491529601_491788801_4FGL_J1257.2+3646_daily_bin973.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/38388/Model_4FGL_J1257.2+3646_daily_bin973.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1257.2+3646'

4FGL J1257.2+3646
   Spectrum: PowerLaw
300    Prefactor:  1.472e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
301        Index:  2.027e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
302        Scale:  1.897e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/38388/ft1_filtered_4FGL_J1257.2+3646_daily_bin973.fits
Spacecraft file(s): /scratch/kocevski/38388/ft2_4FGL_J1257.2+3646_daily_bin973.fits
Exposure map: /scratch/kocevski/38388/expmap_491529601_491788801_4FGL_J1257.2+3646_daily_bin973.fits
Exposure cube: /scratch/kocevski/38388/ltcube_491529601_491788801_4FGL_J1257.2+3646_daily_bin973.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/38388/Model_4FGL_J1257.2+3646_daily_bin973.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) = 5098.58271466

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .15680E-03   1.0000         .10000E-03   10000.    
     2 'norm      '    8.8913       1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10038E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    18.617       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10007E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    12.454       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10012E-03   1.0000         .10000E-03   10000.    
    11 'norm      '    .28397       1.0000         .10000E-03   10000.    
    12 'Prefactor '    152.46       1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10009E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    3.5545       1.0000         .10000E-03   10000.    
    15 'norm      '    3.8795       1.0000         .10000E-03   10000.    
    16 'norm      '    .10220E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    .46682E-02   1.0000         .10000E-03   10000.    
    18 'norm      '    7.0652       1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    67.557       1.0000         .10000E-03   10000.    
    22 'Prefactor '    10.777       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    24 'Normalizat'    .82294       1.0000         .10000E-01   10.000    
    25 'Prefactor '    .92843       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6020E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   5098.563     FROM MIGRAD    STATUS=CONVERGED    592 CALLS     2931 TOTAL
                     EDM=   .20E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.3%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    100.46       -.13502E-04** at limit **
   2  norm          8.8915        3.0992       -.10386E-06    .14718E-03
   3  Prefactor     .10000E-03    1.8507        .61663E-07** at limit **
   4  Prefactor     .10000E-03    .74211        .97413E-07** at limit **
   5  Prefactor     .10000E-03    1.1610       -.16245E-07** at limit **
   6  Prefactor     18.619        10.331        .34072E-07    .66222E-04
   7  Prefactor     .10000E-03    69.218        .27297E-04** at limit **
   8  Prefactor     12.453        18.883       -.10759E-05   -.36780E-03
   9  Prefactor     .10000E-03    58.123       -.18473E-04** at limit **
  10  Prefactor     .10000E-03    2.1608        .26869E-06** at limit **
  11  norm          .30795        2.7199       -.19996E-05    .11213E-02
  12  Prefactor     152.46        65.773       -.13142E-05   -.71751E-05
  13  Prefactor     .10000E-03    13.689        .36325E-05** at limit **
  14  Prefactor     3.5555        7.4213       -.70469E-06   -.11290E-03
  15  norm          3.8798        3.7402        .40446E-07    .17517E-03
  16  norm          .10000E-03    12.528       -.35760E-05** at limit **
  17  norm          .10028E-03    2.3192       -.15293E-05** at limit **
  18  norm          7.0816        7.2234        .35432E-05    .13571E-02
  19  Prefactor     .10000E-03    1.2788       -.20356E-07** at limit **
  20  Prefactor     .10000E-03    4.1631        .74904E-07** at limit **
  21  Prefactor     67.568        46.357        .73254E-05    .60718E-04
  22  Prefactor     10.783        17.513       -.98248E-07    .68251E-04
  23  Prefactor     .10000E-03    21.521        .76379E-06** at limit **
  24  Normalizat    .82292        .16517        .85819E-06    .52367E-03
  25  Prefactor     .92841        .20915       -.70409E-06    .47006E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  norm       = 8.8915
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 18.6187
  Prefactor  = 0.0001
  Prefactor  = 12.453
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.307949
  Prefactor  = 152.46
  Prefactor  = 0.0001
  Prefactor  = 3.55546
  norm       = 3.87978
  norm       = 0.0001
  norm       = 0.000100279
  norm       = 7.08161
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 67.5677
  Prefactor  = 10.7831
  Prefactor  = 0.0001
  Normalizat = 0.822916
  Prefactor  = 0.92841
 **********
 **   18 **HESSE 
 **********

 FCN=   5098.563     FROM HESSE     STATUS=OK           427 CALLS     3358 TOTAL
                     EDM=   .12E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    102.08        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  norm          8.8915        3.0882        .71975E-04   -1.5112    
   3  Prefactor     .10000E-03    1.8521        .94865E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    .75769        .59998E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10000E-03    2.3536        .14903E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     18.619        10.299        .92825E-04   -1.4845    
   7  Prefactor     .10000E-03    67.972        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     12.453        18.999        .56753E-03   -1.5002    
   9  Prefactor     .10000E-03    57.443        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .10000E-03    2.1677        .10245E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  norm          .30795        12.442        .21579E-02   -1.5597    
  12  Prefactor     152.46        65.830        .32645E-04   -1.3232    
  13  Prefactor     .10000E-03    13.711        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     3.5555        7.4053        .21438E-03   -1.5331    
  15  norm          3.8798        3.7314        .13087E-03   -1.5314    
  16  norm          .10000E-03    12.593        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          .10028E-03    70.806        .18280E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  norm          7.0816        6.7854        .15092E-03   -1.5176    
  19  Prefactor     .10000E-03    1.3227        .15752E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .10000E-03    4.1690        .14225E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     67.568        46.126        .24416E-03   -1.4062    
  22  Prefactor     10.783        17.515        .12204E-03   -1.5051    
  23  Prefactor     .10000E-03    21.534        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Normalizat    .82292        .19482        .22267E-03   -.99224    
  25  Prefactor     .92841        .24814        .26707E-03   -.95155    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.21314e-08
Minuit parameter uncertainties:
  1  0.000257028
  2  3.08825
  3  4.67894e-07
  4  6.72179e-07
  5  8.43681e-06
  6  10.2999
  7  0.000235602
  8  19.0086
  9  9.39231e-05
  10  3.8626e-06
  11  3.91505
  12  65.8618
  13  1.61885e-05
  14  7.40718
  15  3.73163
  16  2.73335e-05
  17  0.00890697
  18  6.7861
  19  1.26039e-05
  20  1.63188e-05
  21  46.1507
  22  17.5233
  23  9.83342e-06
  24  0.194982
  25  0.248446
Done.

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

Extracting fit parameters...

4FGL J1257.2+3646
   Spectrum: PowerLaw
300    Prefactor:  1.000e-04  3.863e-06  1.000e-04  1.000e+04 ( 1.000e-13)
301        Index:  2.027e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
302        Scale:  1.897e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
599    Prefactor:  9.284e-01  2.484e-01  0.000e+00  1.000e+01 ( 1.000e+00)
600        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
601        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
598   Normalization:  8.229e-01  1.950e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 194.310 36.771
Photon Flux Upper Limit: 3.93e-08 ph cm-2 s-1
Energy Flux Upper Limit: 2.96e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/38388/likelihoodResults_491529601_491788801_4FGL_J1257.2+3646_daily_bin973.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) = 5098.56482642
delta logL = -0.00218022982608

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 5098.56264733
delta logL = -1.14036083687e-06

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10764E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.0006       1.0000          .0000       10.000    
     3 'Normalizat'    .82300       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .92832       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6020E+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.
 MIGRAD TERMINATED WITHOUT CONVERGENCE.

 FCN=   5098.563     FROM MIGRAD    STATUS=FAILED        86 CALLS      228 TOTAL
                     EDM=   .45E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10134E-03    27.610        .10543E-02** at limit **
   2  Index         1.9454        5.6912        .50000        .81852E-04
   3  Normalizat    .82292        .13484E-01    .22267E-03   -.38343E-04
   4  Prefactor     .92841        .17185E-01    .26707E-03   -.40057E-04
                               ERR DEF=  .500    
 START SIMPLEX MINIMIZATION.    CONVERGENCE WHEN EDM .LT.   .20E-04
 SIMPLEX MINIMIZATION HAS CONVERGED.

 FCN=   5098.563     FROM SIMPLEX   STATUS=UNCHANGED    131 CALLS      359 TOTAL
                     EDM=   .13E-04    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10134E-03    27.610        .29107E-03** at limit **
   2  Index         1.9454        5.6912        .21354E-03    .81852E-04
   3  Normalizat    .82292        .13484E-01    .90526E-06   -.38343E-04
   4  Prefactor     .92841        .17185E-01    .20072E-05   -.40057E-04
                               ERR DEF=  .500    

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   5098.563     FROM MIGRAD    STATUS=CONVERGED     47 CALLS      406 TOTAL
                     EDM=   .56E-10    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    31.387        .21086E-02** at limit **
   2  Index         1.5741        5.0797        .50000        .57705E-06
   3  Normalizat    .82292        .13081E-01    .89069E-05    .10303E-02
   4  Prefactor     .92841        .16671E-01    .10683E-04    .86479E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Index      = 1.57414
  Normalizat = 0.822917
  Prefactor  = 0.928411
 **********
 **   18 **HESSE 
 **********

 FCN=   5098.563     FROM HESSE     STATUS=NOT POSDEF    29 CALLS      435 TOTAL
                     EDM=   .26E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    145.09        .42173E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         1.5741        6.5811        .50000       -.75484    
   3  Normalizat    .82292        .29554E-01    .17814E-05   -.99224    
   4  Prefactor     .92841        .37660E-01    .21365E-05   -.95155    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 2.6342e-10
Minuit parameter uncertainties:
  1  0.000368928
  2  443.273
  3  0.0295544
  4  0.0376615
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/38388': 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) = 5098.56264067
delta logL = 5.51118773728e-06

Extracting fit parameters...

4FGL J1257.2+3646
   Spectrum: PowerLaw
300    Prefactor:  1.000e-04  3.689e-04  1.000e-04  1.000e+04 ( 1.000e-13)
301        Index:  1.574e+00  4.433e+02  0.000e+00  1.000e+01 (-1.000e+00)
302        Scale:  1.897e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
599    Prefactor:  9.284e-01  3.766e-02  0.000e+00  1.000e+01 ( 1.000e+00)
600        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
601        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
598   Normalization:  8.229e-01  2.955e-02  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 194.310 36.771

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/38388/cmap_HighResolution_491529601_491788801_4FGL_J1257.2+3646_daily_bin973.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='2.96e-03', job_status='DONE', photon_flux_upper_limit='3.93e-08', time_completed='2021-09-06 11:57:02.545066', job_id='38388', GAL2='0.93', fit_tolerance='1e-08', EG2='0.82', EG='0.82', time_epoch_completed='1630954622.55', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.93', dlogl='5.51e-06', ts2='-0.00', photon_index_error='0.00', photon_index='2.03' WHERE bin_id='973' AND source_name='4FGL J1257.2+3646' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 11:57:02 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0091>
Subject: Job 38388: <4FGL_J1257.2+3646_daily_bin973> in cluster <slac> Done

Job <4FGL_J1257.2+3646_daily_bin973> was submitted from host <rhel6-64k> by user <kocevski> in cluster <slac> at Mon Sep  6 11:45:31 2021
Job was executed on host(s) <bullet0091>, in queue <medium>, as user <kocevski> in cluster <slac> at Mon Sep  6 11:45:33 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Mon Sep  6 11:45:33 2021
Terminated at Mon Sep  6 11:57:03 2021
Results reported at Mon Sep  6 11:57:03 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1257.2+3646_daily_bin973 194.31 36.7706 491529601 491788801 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1257.2+3646 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   656.46 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             382.95 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   689 sec.
    Turnaround time :                            692 sec.

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

