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


Performing analysis on: 4FGL_J1249.8+3707_daily_bin250
RA = 192.46, Dec = 37.1306
tmin = 304128001, tmax = 304387201
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='935693', job_status='RUN', time_executed='2021-09-06 06:33:43.902348', time_epoch_executed='1630935223.9' WHERE source_name='4FGL J1249.8+3707' and cadence='daily' and bin_id='250'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/935693

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/935693/ft1_4FGL_J1249.8+3707_daily_bin250.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/935693/ft2_4FGL_J1249.8+3707_daily_bin250.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/935693/ft1_4FGL_J1249.8+3707_daily_bin250.fits outfile=/scratch/kocevski/935693/ft1_filteredMKT_4FGL_J1249.8+3707_daily_bin250.fits ra=192.46 dec=37.1306 rad=12.0 tmin=304128001.0 tmax=304387201.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.40
user 3.17
sys 0.21

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/935693/ft2_4FGL_J1249.8+3707_daily_bin250.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/935693/ft1_filteredMKT_4FGL_J1249.8+3707_daily_bin250.fits evtable="EVENTS" outfile="/scratch/kocevski/935693/ft1_filtered_4FGL_J1249.8+3707_daily_bin250.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.49
user 0.31
sys 0.17

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/935693/ft1_filtered_4FGL_J1249.8+3707_daily_bin250.fits" evtable="EVENTS" scfile=/scratch/kocevski/935693/ft2_4FGL_J1249.8+3707_daily_bin250.fits sctable="SC_DATA" outfile=/scratch/kocevski/935693/ltcube_304128001_304387201_4FGL_J1249.8+3707_daily_bin250.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/935693/ft2_4FGL_J1249.8+3707_daily_bin250.fits
.....................!
real 12.00
user 11.64
sys 0.32

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/935693/ft1_filtered_4FGL_J1249.8+3707_daily_bin250.fits evtable="EVENTS" scfile=/scratch/kocevski/935693/ft2_4FGL_J1249.8+3707_daily_bin250.fits sctable="SC_DATA" expcube=/scratch/kocevski/935693/ltcube_304128001_304387201_4FGL_J1249.8+3707_daily_bin250.fits outfile=/scratch/kocevski/935693/expmap_304128001_304387201_4FGL_J1249.8+3707_daily_bin250.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/935693/ltcube_304128001_304387201_4FGL_J1249.8+3707_daily_bin250.fits
.....................!
real 191.33
user 185.65
sys 5.29

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/935693/ft1_filtered_4FGL_J1249.8+3707_daily_bin250.fits scfile=/scratch/kocevski/935693/ft2_4FGL_J1249.8+3707_daily_bin250.fits outfile=/scratch/kocevski/935693/cmap_304128001_304387201_4FGL_J1249.8+3707_daily_bin250.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.58
user 0.38
sys 0.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/935693/ft1_filtered_4FGL_J1249.8+3707_daily_bin250.fits scfile=/scratch/kocevski/935693/ft2_4FGL_J1249.8+3707_daily_bin250.fits outfile=/scratch/kocevski/935693/cmap_HighResolution_304128001_304387201_4FGL_J1249.8+3707_daily_bin250.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.55
user 0.38
sys 0.15

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

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/935693/ft1_filtered_4FGL_J1249.8+3707_daily_bin250.fits', '/scratch/kocevski/935693/ft2_4FGL_J1249.8+3707_daily_bin250.fits', expMap='/scratch/kocevski/935693/expmap_304128001_304387201_4FGL_J1249.8+3707_daily_bin250.fits', expCube='/scratch/kocevski/935693/ltcube_304128001_304387201_4FGL_J1249.8+3707_daily_bin250.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/935693/Model_4FGL_J1249.8+3707_daily_bin250.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/935693/ft1_filtered_4FGL_J1249.8+3707_daily_bin250.fits
Spacecraft file(s): /scratch/kocevski/935693/ft2_4FGL_J1249.8+3707_daily_bin250.fits
Exposure map: /scratch/kocevski/935693/expmap_304128001_304387201_4FGL_J1249.8+3707_daily_bin250.fits
Exposure cube: /scratch/kocevski/935693/ltcube_304128001_304387201_4FGL_J1249.8+3707_daily_bin250.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/935693/Model_4FGL_J1249.8+3707_daily_bin250.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) = 6246.45542417

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .15267E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    13.884       1.0000         .10000E-03   10000.    
     3 'norm      '    13.589       1.0000         .10000E-03   10000.    
     4 'Prefactor '    3.2357       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    1.2490       1.0000         .10000E-03   10000.    
     7 'Prefactor '    11.287       1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10074E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10010E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10007E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    10.163       1.0000         .10000E-03   10000.    
    12 'norm      '    .67705E-03   1.0000         .10000E-03   10000.    
    13 'Prefactor '    .59487       1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10226E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    8.8830       1.0000         .10000E-03   10000.    
    16 'norm      '    8.9100       1.0000         .10000E-03   10000.    
    17 'norm      '    21.542       1.0000         .10000E-03   10000.    
    18 'norm      '    3.1228       1.0000         .10000E-03   10000.    
    19 'norm      '    .10033E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    5.6859       1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10230E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    13.857       1.0000         .10000E-03   10000.    
    24 'Prefactor '    42.944       1.0000         .10000E-03   10000.    
    25 'Normalizat'    1.2720       1.0000         .10000E-01   10.000    
    26 'Prefactor '    .82074       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=   6246.449     FROM MIGRAD    STATUS=CONVERGED    690 CALLS     3156 TOTAL
                     EDM=   .26E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .2%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    74.120        .74256E-07** at limit **
   2  Prefactor     13.896        29.717       -.91614E-05   -.42033E-05
   3  norm          13.588        4.1302        .13143E-06    .61989E-04
   4  Prefactor     3.2352        3.2227        .13676E-06    .27082E-03
   5  Prefactor     .10000E-03    .90855        .10737E-07** at limit **
   6  Prefactor     1.2495        2.0920        .87286E-07   -.60865E-03
   7  Prefactor     11.285        8.8959       -.45459E-05    .14862E-04
   8  Prefactor     .10000E-03    20.902       -.66748E-06** at limit **
   9  Prefactor     .10000E-03    5.7878       -.40735E-07** at limit **
  10  Prefactor     .10000E-03    25.409        .79326E-06** at limit **
  11  Prefactor     10.163        6.4668       -.13535E-06    .39349E-04
  12  norm          .10021E-03    2.1705       -.39814E-06** at limit **
  13  Prefactor     .11713E-03    73.005       -.58172E-05** at limit **
  14  Prefactor     .10000E-03    12.288       -.47705E-07** at limit **
  15  Prefactor     8.8848        12.618       -.38661E-06   -.10709E-04
  16  norm          8.9102        5.6539        .12736E-06   -.96464E-05
  17  norm          21.548        14.824        .57807E-05    .14890E-03
  18  norm          3.1220        2.9511        .26290E-06    .13055E-04
  19  norm          .10000E-03    3.6073        .13270E-08** at limit **
  20  Prefactor     .10000E-03    .73693        .73167E-07** at limit **
  21  Prefactor     5.6840        8.6595       -.73937E-05   -.10193E-03
  22  Prefactor     .10000E-03    16.228        .54472E-07** at limit **
  23  Prefactor     13.854        16.792       -.37796E-05   -.88604E-06
  24  Prefactor     42.921        50.962        .96580E-05    .88378E-05
  25  Normalizat    1.2723        .17325        .12484E-05    .36543E-03
  26  Prefactor     .82033        .21111        .74493E-06    .22776E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 13.8958
  norm       = 13.5883
  Prefactor  = 3.23519
  Prefactor  = 0.0001
  Prefactor  = 1.24945
  Prefactor  = 11.2846
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 10.1629
  norm       = 0.00010021
  Prefactor  = 0.00011713
  Prefactor  = 0.0001
  Prefactor  = 8.88479
  norm       = 8.91019
  norm       = 21.5478
  norm       = 3.12202
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 5.68404
  Prefactor  = 0.0001
  Prefactor  = 13.8543
  Prefactor  = 42.921
  Normalizat = 1.27231
  Prefactor  = 0.820328
 **********
 **   18 **HESSE 
 **********

 FCN=   6246.449     FROM HESSE     STATUS=OK           476 CALLS     3632 TOTAL
                     EDM=   .61E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    75.060        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     13.896        29.781        .10749E-03   -1.4962    
   3  norm          13.588        4.1116        .83607E-04   -1.4971    
   4  Prefactor     3.2352        3.2327        .13808E-03   -1.5348    
   5  Prefactor     .10000E-03    .91486        .73443E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     1.2495        2.0488        .13875E-03   -1.5484    
   7  Prefactor     11.285        8.8602        .11925E-03   -1.5036    
   8  Prefactor     .10000E-03    21.018        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     .10000E-03    5.7892        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .10000E-03    25.415        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     10.163        6.4639        .12569E-03   -1.5070    
  12  norm          .10021E-03    4.0168        .40981E-01   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     .11713E-03    68.980        .16851       -1.5709    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     .10000E-03    12.313        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     8.8848        12.607        .13448E-03   -1.5112    
  16  norm          8.9102        5.6475        .13428E-03   -1.5111    
  17  norm          21.548        14.868        .86299E-04   -1.4779    
  18  norm          3.1220        2.9299        .12514E-03   -1.5355    
  19  norm          .10000E-03    3.6170        .14596E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .10000E-03    .73905        .66233E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     5.6840        8.6870        .16846E-03   -1.5231    
  22  Prefactor     .10000E-03    16.237        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     13.854        16.797        .10760E-03   -1.4963    
  24  Prefactor     42.921        50.947        .61175E-04   -1.4397    
  25  Normalizat    1.2723        .20491        .22202E-03   -.84397    
  26  Prefactor     .82033        .24724        .33483E-03   -.98983    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 6.08483e-10
Minuit parameter uncertainties:
  1  7.25404e-05
  2  29.8131
  3  4.11164
  4  3.23291
  5  1.75043e-06
  6  2.04892
  7  8.86125
  8  2.84612e-05
  9  1.40377e-06
  10  6.06375e-06
  11  6.46436
  12  0.00183586
  13  0.0688296
  14  7.96099e-06
  15  12.6106
  16  5.64782
  17  14.8706
  18  2.93003
  19  3.03223e-06
  20  6.53983e-06
  21  8.68897
  22  1.93506e-05
  23  16.8031
  24  50.9985
  25  0.205043
  26  0.24758
Done.

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

Extracting fit parameters...

4FGL J1249.8+3707
   Spectrum: PowerLaw
313    Prefactor:  1.000e-04  1.404e-06  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:  8.203e-01  2.476e-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.272e+00  2.050e-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: 2.96e-08 ph cm-2 s-1
Energy Flux Upper Limit: 2.18e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/935693/likelihoodResults_304128001_304387201_4FGL_J1249.8+3707_daily_bin250.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) = 6246.45022452
delta logL = -0.000809818481684

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 6246.44941469
delta logL = 1.82408257388e-08

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10093E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    1.7545       1.0000          .0000       10.000    
     3 'Normalizat'    1.2724       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .82021       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.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   6246.449     FROM MIGRAD    STATUS=CONVERGED     92 CALLS      249 TOTAL
                     EDM=   .48E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10302E-03    .88442        .18142E-01** at limit **
   2  Index         1.6602        8.8351        .50000        .25089E-04
   3  Normalizat    1.2723        .15761E-02    .22201E-03    .19612E-04
   4  Prefactor     .82033        .19622E-02    .33483E-03    .50931E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000103016
  Index      = 1.66022
  Normalizat = 1.27231
  Prefactor  = 0.820327
 **********
 **   18 **HESSE 
 **********

 FCN=   6246.449     FROM HESSE     STATUS=NOT POSDEF    29 CALLS      278 TOTAL
                     EDM=   .33E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10302E-03    59.963        .19639E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         1.6602        5.8221        .50000       -.73146    
   3  Normalizat    1.2723        .13109E-01    .88806E-05   -.84397    
   4  Prefactor     .82033        .16319E-01    .13393E-04   -.98983    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 3.25446e-08
Minuit parameter uncertainties:
  1  0.0269225
  2  330.737
  3  0.0131089
  4  0.0163192
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/935693': 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) = 6246.44941402
delta logL = 6.83913640387e-07

Extracting fit parameters...

4FGL J1249.8+3707
   Spectrum: PowerLaw
313    Prefactor:  1.030e-04  2.692e-02  1.000e-04  1.000e+04 ( 1.000e-14)
314        Index:  1.660e+00  3.307e+02  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:  8.203e-01  1.632e-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.272e+00  1.311e-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/935693/cmap_HighResolution_304128001_304387201_4FGL_J1249.8+3707_daily_bin250.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='2.18e-03', job_status='DONE', photon_flux_upper_limit='2.96e-08', time_completed='2021-09-06 06:46:47.781725', job_id='935693', GAL2='0.82', fit_tolerance='1e-08', EG2='1.27', EG='1.27', time_epoch_completed='1630936007.78', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.82', dlogl='6.84e-07', ts2='-0.00', photon_index_error='0.00', photon_index='1.78' WHERE bin_id='250' AND source_name='4FGL J1249.8+3707' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 06:46:47 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0096>
Subject: Job 935693: <4FGL_J1249.8+3707_daily_bin250> in cluster <slac> Done

Job <4FGL_J1249.8+3707_daily_bin250> was submitted from host <rhel6-64h> by user <kocevski> in cluster <slac> at Mon Sep  6 06:30:44 2021
Job was executed on host(s) <bullet0096>, in queue <medium>, as user <kocevski> in cluster <slac> at Mon Sep  6 06:30:45 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:30:45 2021
Terminated at Mon Sep  6 06:46:48 2021
Results reported at Mon Sep  6 06:46:48 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1249.8+3707_daily_bin250 192.46 37.1306 304128001 304387201 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 :                                   781.00 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             290.86 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   963 sec.
    Turnaround time :                            964 sec.

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

