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


Performing analysis on: 4FGL_J1249.8+3707_daily_bin179
RA = 192.46, Dec = 37.1306
tmin = 285724801, tmax = 285984001
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='934525', job_status='RUN', time_executed='2021-09-06 06:28:27.857223', time_epoch_executed='1630934907.86' WHERE source_name='4FGL J1249.8+3707' and cadence='daily' and bin_id='179'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/934525

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

Retrieving the FT1 file...

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

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

Retrieving 48 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/934525/ft1_4FGL_J1249.8+3707_daily_bin179.fits


Retrieving the FT1 file...

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

Retrieving 48 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/934525/ft2_4FGL_J1249.8+3707_daily_bin179.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/934525/ft1_4FGL_J1249.8+3707_daily_bin179.fits outfile=/scratch/kocevski/934525/ft1_filteredMKT_4FGL_J1249.8+3707_daily_bin179.fits ra=192.46 dec=37.1306 rad=12.0 tmin=285724801.0 tmax=285984001.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 4.20
user 3.94
sys 0.21

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/934525/ft2_4FGL_J1249.8+3707_daily_bin179.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/934525/ft2_4FGL_J1249.8+3707_daily_bin179.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/934525/ft1_filteredMKT_4FGL_J1249.8+3707_daily_bin179.fits evtable="EVENTS" outfile="/scratch/kocevski/934525/ft1_filtered_4FGL_J1249.8+3707_daily_bin179.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.13

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/934525/ft1_filtered_4FGL_J1249.8+3707_daily_bin179.fits" evtable="EVENTS" scfile=/scratch/kocevski/934525/ft2_4FGL_J1249.8+3707_daily_bin179.fits sctable="SC_DATA" outfile=/scratch/kocevski/934525/ltcube_285724801_285984001_4FGL_J1249.8+3707_daily_bin179.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/934525/ft2_4FGL_J1249.8+3707_daily_bin179.fits
.....................!
real 11.76
user 11.40
sys 0.31

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/934525/ft1_filtered_4FGL_J1249.8+3707_daily_bin179.fits evtable="EVENTS" scfile=/scratch/kocevski/934525/ft2_4FGL_J1249.8+3707_daily_bin179.fits sctable="SC_DATA" expcube=/scratch/kocevski/934525/ltcube_285724801_285984001_4FGL_J1249.8+3707_daily_bin179.fits outfile=/scratch/kocevski/934525/expmap_285724801_285984001_4FGL_J1249.8+3707_daily_bin179.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/934525/ltcube_285724801_285984001_4FGL_J1249.8+3707_daily_bin179.fits
.....................!
real 190.43
user 185.99
sys 4.07

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

Setting source of interest to:
4FGL J1249.8+3707 @ 192.46 37.1306

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/934525/ft1_filtered_4FGL_J1249.8+3707_daily_bin179.fits scfile=/scratch/kocevski/934525/ft2_4FGL_J1249.8+3707_daily_bin179.fits outfile=/scratch/kocevski/934525/cmap_285724801_285984001_4FGL_J1249.8+3707_daily_bin179.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=192.46 yref=37.1306 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.53
user 0.36
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/934525/ft1_filtered_4FGL_J1249.8+3707_daily_bin179.fits scfile=/scratch/kocevski/934525/ft2_4FGL_J1249.8+3707_daily_bin179.fits outfile=/scratch/kocevski/934525/cmap_HighResolution_285724801_285984001_4FGL_J1249.8+3707_daily_bin179.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=192.46 yref=37.1306 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.54
user 0.38
sys 0.15

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/934525/ft1_filtered_4FGL_J1249.8+3707_daily_bin179.fits evtable="EVENTS" scfile=/scratch/kocevski/934525/ft2_4FGL_J1249.8+3707_daily_bin179.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/934525/Model_4FGL_J1249.8+3707_daily_bin179.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/934525/ft1_filtered_4FGL_J1249.8+3707_daily_bin179.fits.....................!
real 44.52
user 43.20
sys 1.17

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/934525/ft1_filtered_4FGL_J1249.8+3707_daily_bin179.fits', '/scratch/kocevski/934525/ft2_4FGL_J1249.8+3707_daily_bin179.fits', expMap='/scratch/kocevski/934525/expmap_285724801_285984001_4FGL_J1249.8+3707_daily_bin179.fits', expCube='/scratch/kocevski/934525/ltcube_285724801_285984001_4FGL_J1249.8+3707_daily_bin179.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/934525/Model_4FGL_J1249.8+3707_daily_bin179.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1249.8+3707'

4FGL J1249.8+3707
   Spectrum: PowerLaw
313    Prefactor:  2.229e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-14)
314        Index:  1.780e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
315        Scale:  4.011e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/934525/ft1_filtered_4FGL_J1249.8+3707_daily_bin179.fits
Spacecraft file(s): /scratch/kocevski/934525/ft2_4FGL_J1249.8+3707_daily_bin179.fits
Exposure map: /scratch/kocevski/934525/expmap_285724801_285984001_4FGL_J1249.8+3707_daily_bin179.fits
Exposure cube: /scratch/kocevski/934525/ltcube_285724801_285984001_4FGL_J1249.8+3707_daily_bin179.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/934525/Model_4FGL_J1249.8+3707_daily_bin179.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) = 5020.44194256

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    47.645       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
     3 'norm      '    .10002E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    14.913       1.0000         .10000E-03   10000.    
     5 'Prefactor '    1.6568       1.0000         .10000E-03   10000.    
     6 'Prefactor '    8.0199       1.0000         .10000E-03   10000.    
     7 'Prefactor '    9.0143       1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10035E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10019E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    12 'norm      '    .10006E-03   1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10082E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    31.666       1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10009E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    .10014E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    31.771       1.0000         .10000E-03   10000.    
    18 'norm      '    .50014E-03   1.0000         .10000E-03   10000.    
    19 'norm      '    .25189       1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    7.9928       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10008E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10136E-03   1.0000         .10000E-03   10000.    
    25 'Normalizat'    1.2829       1.0000         .10000E-01   10.000    
    26 'Prefactor '    .55075       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6280E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   5020.338     FROM MIGRAD    STATUS=CONVERGED    620 CALLS     2657 TOTAL
                     EDM=   .16E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  4.0%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     47.632        41.282       -.98926E-06   -.24816E-03
   2  Prefactor     .10000E-03    17.064        .76290E-06** at limit **
   3  norm          .10000E-03    1.5044       -.17816E-06** at limit **
   4  Prefactor     14.913        8.4438       -.47609E-07    .43438E-04
   5  Prefactor     1.6566        2.4443        .61407E-06    .12450E-02
   6  Prefactor     8.0201        3.1115       -.92958E-07    .78965E-04
   7  Prefactor     9.0147        8.6526       -.14312E-06   -.38219E-04
   8  Prefactor     .10005E-03    58.754        .52183E-05** at limit **
   9  Prefactor     .10000E-03    15.935       -.74406E-06** at limit **
  10  Prefactor     .10001E-03    31.175       -.16030E-05** at limit **
  11  Prefactor     .10000E-03    2.2010       -.27741E-07** at limit **
  12  norm          .10000E-03    1.6685       -.17467E-07** at limit **
  13  Prefactor     .10000E-03    40.535        .11696E-05** at limit **
  14  Prefactor     31.673        22.840        .43361E-06   -.14213E-03
  15  Prefactor     .10000E-03    4.1770       -.12346E-07** at limit **
  16  norm          .10000E-03    5.5765       -.17271E-07** at limit **
  17  norm          31.773        20.472        .48421E-07    .85927E-04
  18  norm          .10002E-03    8.2341        .73289E-05** at limit **
  19  norm          .27857        6.7351       -.48944E-05   -.46099E-03
  20  Prefactor     .10000E-03    1.0099       -.12552E-07** at limit **
  21  Prefactor     .10000E-03    6.6085       -.24842E-06** at limit **
  22  Prefactor     7.9969        32.579        .52843E-06    .35754E-04
  23  Prefactor     .10000E-03    9.5041       -.10168E-06** at limit **
  24  Prefactor     .10005E-03    80.581       -.43589E-05** at limit **
  25  Normalizat    1.2828        .18164       -.26574E-07    .66722E-04
  26  Prefactor     .55089        .22160        .13164E-05    .98056E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 47.6322
  Prefactor  = 0.000100001
  norm       = 0.0001
  Prefactor  = 14.9134
  Prefactor  = 1.65663
  Prefactor  = 8.02009
  Prefactor  = 9.0147
  Prefactor  = 0.000100053
  Prefactor  = 0.000100001
  Prefactor  = 0.000100006
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.000100003
  Prefactor  = 31.6734
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 31.7727
  norm       = 0.00010002
  norm       = 0.278573
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 7.99691
  Prefactor  = 0.0001
  Prefactor  = 0.000100046
  Normalizat = 1.28281
  Prefactor  = 0.550894
 **********
 **   18 **HESSE 
 **********

 FCN=   5020.338     FROM HESSE     STATUS=OK           448 CALLS     3105 TOTAL
                     EDM=   .65E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     47.632        41.597        .29046E-03   -1.4327    
   2  Prefactor     .10000E-03    17.192        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm          .10000E-03    1.5200        .84563E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     14.913        8.4451        .10372E-03   -1.4935    
   5  Prefactor     1.6566        2.4528        .12796E-03   -1.5451    
   6  Prefactor     8.0201        3.1047        .72853E-04   -1.5141    
   7  Prefactor     9.0147        8.6515        .13349E-03   -1.5107    
   8  Prefactor     .10005E-03    62.521        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     .10000E-03    16.142        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .10001E-03    31.609        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .10000E-03    2.2077        .10265E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  norm          .10000E-03    1.6766        .89318E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     .10000E-03    40.777        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     31.673        22.680        .71204E-04   -1.4582    
  15  Prefactor     .10000E-03    4.1800        .14142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          .10000E-03    5.8005        .32637E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          31.773        20.472        .71087E-04   -1.4580    
  18  norm          .10002E-03    9.5923        .18351E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  norm          .27857        29.037        .27096E-02   -1.5602    
  20  Prefactor     .10000E-03    1.0154        .69476E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .10000E-03    6.6431        .17795E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     7.9969        32.581        .14182E-03   -1.5142    
  23  Prefactor     .10000E-03    9.5350        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     .10005E-03    83.591        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Normalizat    1.2828        .20370        .19637E-03   -.84081    
  26  Prefactor     .55089        .24731        .35228E-03   -1.0970    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 6.47552e-09
Minuit parameter uncertainties:
  1  41.6228
  2  0.000317723
  3  1.83394e-05
  4  8.44576
  5  2.45296
  6  3.10475
  7  8.65272
  8  0.00365415
  9  0.000280031
  10  0.000900147
  11  4.29232e-06
  12  4.97748e-06
  13  0.000733955
  14  22.6863
  15  4.04502e-06
  16  1.60752e-05
  17  20.477
  18  0.000876648
  19  5.69001
  20  3.48795e-06
  21  7.57099e-05
  22  32.3135
  23  3.62643e-05
  24  0.00390701
  25  0.203827
  26  0.247792
Done.

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

Extracting fit parameters...

4FGL J1249.8+3707
   Spectrum: PowerLaw
313    Prefactor:  1.000e-04  2.800e-04  1.000e-04  1.000e+04 ( 1.000e-14)
314        Index:  1.780e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
315        Scale:  4.011e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
625    Prefactor:  5.509e-01  2.478e-01  0.000e+00  1.000e+01 ( 1.000e+00)
626        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
627        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
624   Normalization:  1.283e+00  2.038e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 192.460 37.131
Photon Flux Upper Limit: 3.89e-08 ph cm-2 s-1
Energy Flux Upper Limit: 2.86e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/934525/likelihoodResults_285724801_285984001_4FGL_J1249.8+3707_daily_bin179.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) = 5020.33840594
delta logL = -0.000295048471344

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 5020.33811396
delta logL = -3.07288610202e-06

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .21214E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    1.8851       1.0000          .0000       10.000    
     3 'Normalizat'    1.2828       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .55089       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6280E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   5020.338     FROM MIGRAD    STATUS=CONVERGED     52 CALLS      240 TOTAL
                     EDM=   .64E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    42.765        .90712E-02** at limit **
   2  Index         1.9011        5.3851        .50000       -.74769E-05
   3  Normalizat    1.2828        .67233E-02    .33120E-01    .19559E-03
   4  Prefactor     .55089        .82543E-02    .79544E-01    .13788E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000100001
  Index      = 1.90109
  Normalizat = 1.28281
  Prefactor  = 0.550892
 **********
 **   18 **HESSE 
 **********

 FCN=   5020.338     FROM HESSE     STATUS=NOT POSDEF    31 CALLS      271 TOTAL
                     EDM=   .14E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    1874.4        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         1.9011        8.7952        .50000       -.66847    
   3  Normalizat    1.2828        .53897E-01    .19637E-03   -.84081    
   4  Prefactor     .55089        .65982E-01    .35228E-03   -1.0970    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 1.43549e-10
Minuit parameter uncertainties:
  1  0.0031707
  2  42.3072
  3  0.0538994
  4  0.0659912
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/934525': 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) = 5020.33811067
delta logL = 2.17401975533e-07

Extracting fit parameters...

4FGL J1249.8+3707
   Spectrum: PowerLaw
313    Prefactor:  1.000e-04  3.171e-03  1.000e-04  1.000e+04 ( 1.000e-14)
314        Index:  1.901e+00  4.231e+01  0.000e+00  1.000e+01 (-1.000e+00)
315        Scale:  4.011e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
625    Prefactor:  5.509e-01  6.599e-02  0.000e+00  1.000e+01 ( 1.000e+00)
626        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
627        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
624   Normalization:  1.283e+00  5.390e-02  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 192.460 37.131

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/934525/cmap_HighResolution_285724801_285984001_4FGL_J1249.8+3707_daily_bin179.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='2.86e-03', job_status='DONE', photon_flux_upper_limit='3.89e-08', time_completed='2021-09-06 06:39:30.430298', job_id='934525', GAL2='0.55', fit_tolerance='1e-08', EG2='1.28', EG='1.28', time_epoch_completed='1630935570.43', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.55', dlogl='2.17e-07', ts2='-0.00', photon_index_error='0.00', photon_index='1.78' WHERE bin_id='179' AND source_name='4FGL J1249.8+3707' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 06:39:30 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0090>
Subject: Job 934525: <4FGL_J1249.8+3707_daily_bin179> in cluster <slac> Done

Job <4FGL_J1249.8+3707_daily_bin179> was submitted from host <rhel6-64p> by user <kocevski> in cluster <slac> at Mon Sep  6 06:26:06 2021
Job was executed on host(s) <bullet0090>, in queue <medium>, as user <kocevski> in cluster <slac> at Mon Sep  6 06:26:07 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Mon Sep  6 06:26:07 2021
Terminated at Mon Sep  6 06:39:31 2021
Results reported at Mon Sep  6 06:39:31 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1249.8+3707_daily_bin179 192.46 37.1306 285724801 285984001 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1249.8+3707 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   659.00 sec.
    Max Memory :                                 1094 MB
    Average Memory :                             296.96 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   803 sec.
    Turnaround time :                            805 sec.

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

