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


Performing analysis on: 4FGL_J2049.9+1002_daily_bin1339
RA = 312.478, Dec = 10.0407
tmin = 586396801, tmax = 586656001
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='163379', job_status='RUN', time_executed='2021-09-25 18:53:38.630202', time_epoch_executed='1632621218.63' WHERE source_name='4FGL J2049.9+1002' and cadence='daily' and bin_id='1339'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/163379

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

Retrieving the FT1 file...

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

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

Retrieving 31 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/163379/ft1_4FGL_J2049.9+1002_daily_bin1339.fits


Retrieving the FT1 file...

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

Retrieving 31 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/163379/ft2_4FGL_J2049.9+1002_daily_bin1339.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/163379/ft1_4FGL_J2049.9+1002_daily_bin1339.fits outfile=/scratch/kocevski/163379/ft1_filteredMKT_4FGL_J2049.9+1002_daily_bin1339.fits ra=312.478 dec=10.0407 rad=12.0 tmin=586396801.0 tmax=586656001.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 2.60
user 2.41
sys 0.18

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/163379/ft2_4FGL_J2049.9+1002_daily_bin1339.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/163379/ft2_4FGL_J2049.9+1002_daily_bin1339.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/163379/ft1_filteredMKT_4FGL_J2049.9+1002_daily_bin1339.fits evtable="EVENTS" outfile="/scratch/kocevski/163379/ft1_filtered_4FGL_J2049.9+1002_daily_bin1339.fits" apply_filter=yes overwrite=yes header_obstimes=yes tstart=0.0 tstop=0.0 gtifile="default" chatter=3 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

This is gtmktime version HEAD
Applying GTI filter:
IN_SAA!=T && LIVETIME>0 && gtifilter('/nfs/farm/g/glast/g/LCRepository/Likelihood/GTIs/nogrb.gti',(START+STOP)/2) && (angsep(RA_SUN,DEC_SUN,RA_ZENITH,DEC_ZENITH)>115 || gtifilter('/nfs/farm/g/glast/g/LCRepository/Likelihood/GTIs/nosolarflares.gti',(START+STOP)/2))
real 0.50
user 0.35
sys 0.14

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/163379/ft1_filtered_4FGL_J2049.9+1002_daily_bin1339.fits" evtable="EVENTS" scfile=/scratch/kocevski/163379/ft2_4FGL_J2049.9+1002_daily_bin1339.fits sctable="SC_DATA" outfile=/scratch/kocevski/163379/ltcube_586396801_586656001_4FGL_J2049.9+1002_daily_bin1339.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/163379/ft2_4FGL_J2049.9+1002_daily_bin1339.fits
.....................!
real 8.83
user 8.40
sys 0.34

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/163379/ft1_filtered_4FGL_J2049.9+1002_daily_bin1339.fits evtable="EVENTS" scfile=/scratch/kocevski/163379/ft2_4FGL_J2049.9+1002_daily_bin1339.fits sctable="SC_DATA" expcube=/scratch/kocevski/163379/ltcube_586396801_586656001_4FGL_J2049.9+1002_daily_bin1339.fits outfile=/scratch/kocevski/163379/expmap_586396801_586656001_4FGL_J2049.9+1002_daily_bin1339.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/163379/ltcube_586396801_586656001_4FGL_J2049.9+1002_daily_bin1339.fits
.....................!
real 193.16
user 187.58
sys 4.96

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
Extended source W 51C in ROI, make sure /nfs/farm/g/glast/g/LCRepository/Likelihood/ExtendedSources/Extended_archive_v18/Templates/W51C.fits is the correct path to the extended template.
Extended source Cygnus Loop in ROI, make sure /nfs/farm/g/glast/g/LCRepository/Likelihood/ExtendedSources/Extended_archive_v18/Templates/CygnusLoop.fits is the correct path to the extended template.
Added 201 point sources and 2 extended sources
If using unbinned likelihood you will need to rerun gtdiffrsp for the extended sources or rerun the makeModel function with optional argument psForce=True

Setting source of interest to:
4FGL J2049.9+1002 @ 312.478 10.0407

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/163379/ft1_filtered_4FGL_J2049.9+1002_daily_bin1339.fits scfile=/scratch/kocevski/163379/ft2_4FGL_J2049.9+1002_daily_bin1339.fits outfile=/scratch/kocevski/163379/cmap_586396801_586656001_4FGL_J2049.9+1002_daily_bin1339.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=312.478 yref=10.0407 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.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/163379/ft1_filtered_4FGL_J2049.9+1002_daily_bin1339.fits scfile=/scratch/kocevski/163379/ft2_4FGL_J2049.9+1002_daily_bin1339.fits outfile=/scratch/kocevski/163379/cmap_HighResolution_586396801_586656001_4FGL_J2049.9+1002_daily_bin1339.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=312.478 yref=10.0407 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.56
user 0.38
sys 0.16

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/163379/ft1_filtered_4FGL_J2049.9+1002_daily_bin1339.fits evtable="EVENTS" scfile=/scratch/kocevski/163379/ft2_4FGL_J2049.9+1002_daily_bin1339.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/163379/Model_4FGL_J2049.9+1002_daily_bin1339.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 Cygnus Loop
adding source EG_v02
adding source GAL_V02
adding source W 51C
Working on...
/scratch/kocevski/163379/ft1_filtered_4FGL_J2049.9+1002_daily_bin1339.fits.....................!
real 147.65
user 145.97
sys 1.22

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/163379/ft1_filtered_4FGL_J2049.9+1002_daily_bin1339.fits', '/scratch/kocevski/163379/ft2_4FGL_J2049.9+1002_daily_bin1339.fits', expMap='/scratch/kocevski/163379/expmap_586396801_586656001_4FGL_J2049.9+1002_daily_bin1339.fits', expCube='/scratch/kocevski/163379/ltcube_586396801_586656001_4FGL_J2049.9+1002_daily_bin1339.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/163379/Model_4FGL_J2049.9+1002_daily_bin1339.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J2049.9+1002'

4FGL J2049.9+1002
   Spectrum: LogParabola
407         norm:  4.360e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-12)
408        alpha:  2.394e+00  0.000e+00  0.000e+00  5.000e+00 ( 1.000e+00) fixed
409         beta:  1.463e-01  0.000e+00  0.000e+00  1.000e+01 ( 1.000e+00) fixed
410           Eb:  6.403e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/163379/ft1_filtered_4FGL_J2049.9+1002_daily_bin1339.fits
Spacecraft file(s): /scratch/kocevski/163379/ft2_4FGL_J2049.9+1002_daily_bin1339.fits
Exposure map: /scratch/kocevski/163379/expmap_586396801_586656001_4FGL_J2049.9+1002_daily_bin1339.fits
Exposure cube: /scratch/kocevski/163379/ltcube_586396801_586656001_4FGL_J2049.9+1002_daily_bin1339.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/163379/Model_4FGL_J2049.9+1002_daily_bin1339.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) = 6341.89307349

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    6.7613       1.0000         .10000E-03   10000.    
     2 'norm      '    6.3835       1.0000         .10000E-03   10000.    
     3 'Prefactor '    44.092       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .39946E-02   1.0000         .10000E-03   10000.    
     5 'norm      '    .10466E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    45.894       1.0000         .10000E-03   10000.    
     7 'norm      '    10.187       1.0000         .10000E-03   10000.    
     8 'norm      '    .10035E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    26.206       1.0000         .10000E-03   10000.    
    10 'Prefactor '    5.4113       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10121E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    15.260       1.0000         .10000E-03   10000.    
    13 'Prefactor '    53.248       1.0000         .10000E-03   10000.    
    14 'Prefactor '    .16386E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    5.4921       1.0000         .10000E-03   10000.    
    16 'Prefactor '    .11511E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    26.034       1.0000         .10000E-03   10000.    
    19 'Prefactor '    1.8066       1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10007E-03   1.0000         .10000E-03   10000.    
    21 'Normalizat'    .56816       1.0000         .10000E-01   10.000    
    22 'Prefactor '    1.1115       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6980E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   6341.876     FROM MIGRAD    STATUS=CONVERGED    468 CALLS     2427 TOTAL
                     EDM=   .18E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  4.1%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     6.7621        11.159        .39293E-06    .49355E-04
   2  norm          6.3847        7.6965       -.61036E-08    .17396E-04
   3  Prefactor     44.089        20.379        .15226E-05    .10850E-02
   4  Prefactor     .10000E-03    68.296       -.17593E-05** at limit **
   5  norm          .10000E-03    .41961       -.80355E-06** at limit **
   6  Prefactor     45.851        103.01        .99224E-05    .18144E-03
   7  norm          10.184        22.533       -.15722E-05    .21084E-03
   8  norm          .10000E-03    28.321       -.66520E-07** at limit **
   9  Prefactor     26.206        18.562        .47369E-06    .89183E-04
  10  Prefactor     5.4147        23.474        .19208E-05    .33148E-04
  11  Prefactor     .10000E-03    52.665        .18082E-05** at limit **
  12  Prefactor     15.267        17.199        .18866E-06    .19975E-04
  13  Prefactor     53.220        36.395        .22381E-05    .15682E-04
  14  Prefactor     .10002E-03    59.381       -.58701E-05** at limit **
  15  Prefactor     5.4499        59.122        .47967E-05   -.72510E-04
  16  Prefactor     .10000E-03    70.463       -.12694E-05** at limit **
  17  norm          .10000E-03    2.1683        .67265E-07** at limit **
  18  Prefactor     26.019        31.301        .15308E-05   -.41222E-04
  19  Prefactor     1.8060        9.8732        .13080E-04   -.45738E-03
  20  Prefactor     .10000E-03    12.911        .39630E-06** at limit **
  21  Normalizat    .56858        .40476       -.20217E-04    .51886E-04
  22  Prefactor     1.1113        .12470        .32816E-05    .76029E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 6.7621
  norm       = 6.38466
  Prefactor  = 44.0893
  Prefactor  = 0.000100001
  norm       = 0.0001
  Prefactor  = 45.8511
  norm       = 10.1836
  norm       = 0.0001
  Prefactor  = 26.206
  Prefactor  = 5.41469
  Prefactor  = 0.0001
  Prefactor  = 15.2672
  Prefactor  = 53.22
  Prefactor  = 0.000100016
  Prefactor  = 5.44988
  Prefactor  = 0.000100001
  norm       = 0.0001
  Prefactor  = 26.0187
  Prefactor  = 1.80603
  Prefactor  = 0.0001
  Normalizat = 0.568579
  Prefactor  = 1.11132
 **********
 **   18 **HESSE 
 **********

 FCN=   6341.876     FROM HESSE     STATUS=OK           342 CALLS     2769 TOTAL
                     EDM=   .30E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     6.7621        11.157        .15431E-03   -1.5188    
   2  norm          6.3847        7.6983        .15886E-03   -1.5203    
   3  Prefactor     44.089        20.084        .60377E-04   -1.4379    
   4  Prefactor     .10000E-03    70.002        .38992E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  norm          .10000E-03    .62249        .96828E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     45.851        102.61        .59185E-04   -1.4353    
   7  norm          10.184        22.229        .12554E-03   -1.5070    
   8  norm          .10000E-03    28.322        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     26.206        18.542        .78255E-04   -1.4684    
  10  Prefactor     5.4147        23.389        .17275E-03   -1.5243    
  11  Prefactor     .10000E-03    52.718        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     15.267        17.125        .10253E-03   -1.4926    
  13  Prefactor     53.220        36.326        .54965E-04   -1.4248    
  14  Prefactor     .10002E-03    60.361        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     5.4499        58.441        .17145E-03   -1.5241    
  16  Prefactor     .10000E-03    70.443        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          .10000E-03    2.1785        .11452E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     26.019        31.219        .78512E-04   -1.4687    
  19  Prefactor     1.8060        9.9571        .15545E-02   -1.5439    
  20  Prefactor     .10000E-03    13.138        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Normalizat    .56858        .40589        .59505E-03   -1.0934    
  22  Prefactor     1.1113        .12871        .15023E-03   -.89106    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 3.03189e-09
Minuit parameter uncertainties:
  1  11.1605
  2  7.69953
  3  20.087
  4  0.000444308
  5  2.61372e-05
  6  103.011
  7  22.2472
  8  2.20821e-05
  9  18.5463
  10  22.5217
  11  0.000254351
  12  17.1301
  13  36.3407
  14  0.00199679
  15  35.7373
  16  0.000421544
  17  5.83074e-06
  18  31.2384
  19  8.48315
  20  2.10724e-05
  21  0.408036
  22  0.128749
Done.

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

Extracting fit parameters...

4FGL J2049.9+1002
   Spectrum: LogParabola
407         norm:  1.018e+01  2.225e+01  1.000e-04  1.000e+04 ( 1.000e-12)
408        alpha:  2.394e+00  0.000e+00  0.000e+00  5.000e+00 ( 1.000e+00) fixed
409         beta:  1.463e-01  0.000e+00  0.000e+00  1.000e+01 ( 1.000e+00) fixed
410           Eb:  6.403e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
691    Prefactor:  1.111e+00  1.287e-01  0.000e+00  1.000e+01 ( 1.000e+00)
692        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
693        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
690   Normalization:  5.686e-01  4.080e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.42
Ra Dec: 312.478 10.041
Photon Flux Upper Limit: 2.11e-07 ph cm-2 s-1
Energy Flux Upper Limit: 6.69e-05 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/163379/likelihoodResults_586396801_586656001_4FGL_J2049.9+1002_daily_bin1339.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): 0
logL (Free Index) = 6341.60944229
delta logL = 0.266730331924

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 6341.59575982
delta logL = 0.280412800635

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    5.5726       1.0000         .10000E-03   10000.    
     2 'alpha     '    3.4414       1.0000          .0000       5.0000    
     3 'Normalizat'    .50164       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.1259       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6980E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   6341.596     FROM MIGRAD    STATUS=CONVERGED     58 CALLS      252 TOTAL
                     EDM=   .30E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          5.5649        140.06        .42547E-02    .64983E-03
   2  alpha         3.4422        4.0070        .45631        .81685E-04
   3  Normalizat    .50162        .92429E-01    .14229        .34354E-04
   4  Prefactor     1.1259        .31188E-01    .36676E-01   -.51851E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 5.56494
  alpha      = 3.44224
  Normalizat = 0.501617
  Prefactor  = 1.12594
 **********
 **   18 **HESSE 
 **********

 FCN=   6341.596     FROM HESSE     STATUS=NOT POSDEF    33 CALLS      285 TOTAL
                     EDM=   .75E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          5.5649        282.56        .17019E-03   -1.5236    
   2  alpha         3.4422        2.9938        .20052E-01    .38644    
   3  Normalizat    .50162        .42175        .63081E-03   -1.1234    
   4  Prefactor     1.1259        .15371        .14931E-03   -.88642    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 7.49862e-09
Minuit parameter uncertainties:
  1  79.7085
  2  10.2118
  3  0.424479
  4  0.153775
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/163379': 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) = 6341.59575964
delta logL = 0.280412982833

Extracting fit parameters...

4FGL J2049.9+1002
   Spectrum: LogParabola
407         norm:  5.565e+00  7.971e+01  1.000e-04  1.000e+04 ( 1.000e-12)
408        alpha:  3.442e+00  1.021e+01  0.000e+00  5.000e+00 ( 1.000e+00)
409         beta:  1.463e-01  0.000e+00  0.000e+00  1.000e+01 ( 1.000e+00) fixed
410           Eb:  6.403e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
691    Prefactor:  1.126e+00  1.538e-01  0.000e+00  1.000e+01 ( 1.000e+00)
692        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
693        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
690   Normalization:  5.016e-01  4.245e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 1.05
Ra Dec: 312.478 10.041
Photon Index (Free Index): 3.44 +/- 10.21
Photon Flux (Free Index): 9.87e-08 +/- 1.07e-07
Energy Flux (Free Index): 1.79e-05 +/- 5.97e-05

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/163379/cmap_HighResolution_586396801_586656001_4FGL_J2049.9+1002_daily_bin1339.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='6.69e-05', comment='SUCCESS', energy_flux2='1.79e-05', dlogl='2.80e-01', photon_flux2='9.87e-08', job_status='DONE', time_completed='2021-09-25 19:07:11.634209', photon_index_error2='10.21', photon_index2='3.44', ts='0.42', fit_tolerance='1e-08', GAL='1.11', photon_index_error='0.00', photon_flux_upper_limit='2.11e-07', energy_flux_error2='5.97e-05', EG='0.57', time_epoch_completed='1632622031.63', return_code='0', job_id='163379', GAL2='1.13', EG2='0.50', return_code2='102', photon_flux_error2='1.07e-07', ts2='1.05', photon_index='2.39' WHERE bin_id='1339' AND source_name='4FGL J2049.9+1002' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sat Sep 25 19:07:11 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0227>
Subject: Job 163379: <4FGL_J2049.9+1002_daily_bin1339> in cluster <slac> Done

Job <4FGL_J2049.9+1002_daily_bin1339> was submitted from host <rhel6-64h> by user <kocevski> in cluster <slac> at Sat Sep 25 18:50:40 2021
Job was executed on host(s) <bullet0227>, in queue <medium>, as user <kocevski> in cluster <slac> at Sat Sep 25 18:53:26 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sat Sep 25 18:53:26 2021
Terminated at Sat Sep 25 19:07:12 2021
Results reported at Sat Sep 25 19:07:12 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J2049.9+1002_daily_bin1339 312.478 10.0407 586396801 586656001 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J2049.9+1002 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   809.00 sec.
    Max Memory :                                 1258 MB
    Average Memory :                             326.36 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   825 sec.
    Turnaround time :                            992 sec.

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

