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


Performing analysis on: 4FGL_J2252.0+4031_daily_bin751
RA = 343.01, Dec = 40.5232
tmin = 433987201, tmax = 434246401
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='559002', job_status='RUN', time_executed='2021-09-29 01:03:48.388946', time_epoch_executed='1632902628.39' WHERE source_name='4FGL J2252.0+4031' and cadence='daily' and bin_id='751'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/559002

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/559002/ft1_4FGL_J2252.0+4031_daily_bin751.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/559002/ft2_4FGL_J2252.0+4031_daily_bin751.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/559002/ft1_4FGL_J2252.0+4031_daily_bin751.fits outfile=/scratch/kocevski/559002/ft1_filteredMKT_4FGL_J2252.0+4031_daily_bin751.fits ra=343.01 dec=40.5232 rad=12.0 tmin=433987201.0 tmax=434246401.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 6.15
user 5.82
sys 0.26

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/559002/ft2_4FGL_J2252.0+4031_daily_bin751.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/559002/ft2_4FGL_J2252.0+4031_daily_bin751.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/559002/ft1_filteredMKT_4FGL_J2252.0+4031_daily_bin751.fits evtable="EVENTS" outfile="/scratch/kocevski/559002/ft1_filtered_4FGL_J2252.0+4031_daily_bin751.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.48
user 0.33
sys 0.15

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/559002/ft1_filtered_4FGL_J2252.0+4031_daily_bin751.fits" evtable="EVENTS" scfile=/scratch/kocevski/559002/ft2_4FGL_J2252.0+4031_daily_bin751.fits sctable="SC_DATA" outfile=/scratch/kocevski/559002/ltcube_433987201_434246401_4FGL_J2252.0+4031_daily_bin751.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/559002/ft2_4FGL_J2252.0+4031_daily_bin751.fits
.....................!
real 12.10
user 11.74
sys 0.33

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/559002/ft1_filtered_4FGL_J2252.0+4031_daily_bin751.fits evtable="EVENTS" scfile=/scratch/kocevski/559002/ft2_4FGL_J2252.0+4031_daily_bin751.fits sctable="SC_DATA" expcube=/scratch/kocevski/559002/ltcube_433987201_434246401_4FGL_J2252.0+4031_daily_bin751.fits outfile=/scratch/kocevski/559002/expmap_433987201_434246401_4FGL_J2252.0+4031_daily_bin751.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/559002/ltcube_433987201_434246401_4FGL_J2252.0+4031_daily_bin751.fits
.....................!
real 189.60
user 185.25
sys 4.03

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 FHES J2304.0+5406 in ROI with RadialGaussian spatial model.
Extended source CTB 109 in ROI with RadialDisk spatial model.
Added 173 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 J2252.0+4031 @ 343.01 40.5232

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/559002/ft1_filtered_4FGL_J2252.0+4031_daily_bin751.fits scfile=/scratch/kocevski/559002/ft2_4FGL_J2252.0+4031_daily_bin751.fits outfile=/scratch/kocevski/559002/cmap_433987201_434246401_4FGL_J2252.0+4031_daily_bin751.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=343.01 yref=40.5232 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.38
sys 0.13

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/559002/ft1_filtered_4FGL_J2252.0+4031_daily_bin751.fits scfile=/scratch/kocevski/559002/ft2_4FGL_J2252.0+4031_daily_bin751.fits outfile=/scratch/kocevski/559002/cmap_HighResolution_433987201_434246401_4FGL_J2252.0+4031_daily_bin751.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=343.01 yref=40.5232 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.38
sys 0.14

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/559002/ft1_filtered_4FGL_J2252.0+4031_daily_bin751.fits evtable="EVENTS" scfile=/scratch/kocevski/559002/ft2_4FGL_J2252.0+4031_daily_bin751.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/559002/Model_4FGL_J2252.0+4031_daily_bin751.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 CTB 109
adding source EG_v02
adding source FHES J2304.0+5406
adding source GAL_V02
Working on...
/scratch/kocevski/559002/ft1_filtered_4FGL_J2252.0+4031_daily_bin751.fits.....................!
real 72.35
user 71.06
sys 1.15

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/559002/ft1_filtered_4FGL_J2252.0+4031_daily_bin751.fits', '/scratch/kocevski/559002/ft2_4FGL_J2252.0+4031_daily_bin751.fits', expMap='/scratch/kocevski/559002/expmap_433987201_434246401_4FGL_J2252.0+4031_daily_bin751.fits', expCube='/scratch/kocevski/559002/ltcube_433987201_434246401_4FGL_J2252.0+4031_daily_bin751.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/559002/Model_4FGL_J2252.0+4031_daily_bin751.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J2252.0+4031'

4FGL J2252.0+4031
   Spectrum: PowerLaw
404    Prefactor:  2.093e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
405        Index:  2.052e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
406        Scale:  2.181e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/559002/ft1_filtered_4FGL_J2252.0+4031_daily_bin751.fits
Spacecraft file(s): /scratch/kocevski/559002/ft2_4FGL_J2252.0+4031_daily_bin751.fits
Exposure map: /scratch/kocevski/559002/expmap_433987201_434246401_4FGL_J2252.0+4031_daily_bin751.fits
Exposure cube: /scratch/kocevski/559002/ltcube_433987201_434246401_4FGL_J2252.0+4031_daily_bin751.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/559002/Model_4FGL_J2252.0+4031_daily_bin751.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) = 5372.89336836

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    .49295       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .18162E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    9.1488       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .12900E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10064E-03   1.0000         .10000E-03   10000.    
     7 'norm      '    4.5815       1.0000         .10000E-03   10000.    
     8 'Prefactor '    32.289       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .11044E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .17913E-01   1.0000         .10000E-03   10000.    
    11 'norm      '    2.3083       1.0000         .10000E-03   10000.    
    12 'Prefactor '    .42641E-02   1.0000         .10000E-03   10000.    
    13 'norm      '    .10011E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    3.0959       1.0000         .10000E-03   10000.    
    15 'Prefactor '    55.320       1.0000         .10000E-03   10000.    
    16 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
    17 'Prefactor '    .10271E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    51.869       1.0000         .10000E-03   10000.    
    19 'Normalizat'    1.1011       1.0000         .10000E-01   10.000    
    20 'Prefactor '    .94063       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5890E+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=   5372.859     FROM MIGRAD    STATUS=CONVERGED    803 CALLS     2479 TOTAL
                     EDM=   .18E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .49424        1.1384        .11176E-03   -.68972E-04
   2  Prefactor     .10000E-03    41.309        .18142E-02** at limit **
   3  Prefactor     9.1236        17.573        .13250E-03   -.28485E-04
   4  Prefactor     .10000E-03    46.292        .18142E-02** at limit **
   5  Prefactor     .10000E-03    4.3386        .14891E-02** at limit **
   6  Prefactor     .10000E-03    18.556        .18142E-02** at limit **
   7  norm          4.5808        4.3822        .14487E-03    .26132E-04
   8  Prefactor     32.231        44.476        .70516E-04   -.22571E-05
   9  Prefactor     .10000E-03    12.725        .18142E-02** at limit **
  10  Prefactor     .10005E-03    33.159        .13800    ** at limit **
  11  norm          2.3084        2.2883        .10385E-03    .14341E-04
  12  Prefactor     .24043        26.059        .83619E-01    .11066E-03
  13  norm          .10000E-03    4.8463        .15662E-02** at limit **
  14  norm          3.0868        14.822        .23048E-03   -.93719E-05
  15  Prefactor     55.330        35.190        .53931E-04   -.10329E-04
  16  norm          .10000E-03    3.8185        .13824E-02** at limit **
  17  Prefactor     .10000E-03    15.299        .18142E-02** at limit **
  18  Prefactor     51.835        64.374        .27844E-03    .33889E-05
  19  Normalizat    1.1002        .38370        .44482E-03    .51550E-04
  20  Prefactor     .94069        .11379        .14794E-03   -.63168E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 0.494244
  Prefactor  = 0.000100001
  Prefactor  = 9.12357
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 4.58077
  Prefactor  = 32.2312
  Prefactor  = 0.0001
  Prefactor  = 0.00010005
  norm       = 2.30844
  Prefactor  = 0.240433
  norm       = 0.0001
  norm       = 3.08676
  Prefactor  = 55.3302
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 51.8347
  Normalizat = 1.10022
  Prefactor  = 0.940695
 **********
 **   18 **HESSE 
 **********

 FCN=   5372.859     FROM HESSE     STATUS=OK           291 CALLS     2770 TOTAL
                     EDM=   .15E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          .49424        1.1381        .44702E-05   -1.5567    
   2  Prefactor     .10000E-03    41.310        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     9.1236        17.568        .53002E-05   -1.5104    
   4  Prefactor     .10000E-03    46.292        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10000E-03    4.3388        .29783E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    18.558        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  norm          4.5808        4.3821        .57948E-05   -1.5280    
   8  Prefactor     32.231        44.481        .28206E-05   -1.4572    
   9  Prefactor     .10000E-03    12.729        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .10005E-03    32.981        .13867       -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  norm          2.3084        2.2883        .41540E-05   -1.5404    
  12  Prefactor     .24043        23.868        .88237E-01   -1.5610    
  13  norm          .10000E-03    4.8472        .31325E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          3.0868        14.819        .92193E-05   -1.5357    
  15  Prefactor     55.330        35.204        .21572E-05   -1.4219    
  16  norm          .10000E-03    3.8202        .27648E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  Prefactor     .10000E-03    15.299        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     51.835        64.372        .11137E-04   -1.4267    
  19  Normalizat    1.1002        .38363        .17793E-04   -.89745    
  20  Prefactor     .94069        .11385        .59176E-05   -.94733    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.46429e-10
Minuit parameter uncertainties:
  1  1.13814
  2  0.000306577
  3  17.5777
  4  5.15564e-06
  5  7.7612e-07
  6  1.06755e-05
  7  4.38236
  8  44.5267
  9  6.8018e-05
  10  0.002558
  11  2.28835
  12  4.79209
  13  2.06542e-06
  14  13.5318
  15  35.2168
  16  2.84495e-06
  17  6.83213e-06
  18  64.4585
  19  0.384606
  20  0.113882
Done.

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

Extracting fit parameters...

4FGL J2252.0+4031
   Spectrum: PowerLaw
404    Prefactor:  1.000e-04  6.802e-05  1.000e-04  1.000e+04 ( 1.000e-13)
405        Index:  2.052e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
406        Scale:  2.181e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
586    Prefactor:  9.407e-01  1.139e-01  0.000e+00  1.000e+01 ( 1.000e+00)
587        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
588        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
581   Normalization:  1.100e+00  3.846e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 343.010 40.523
Photon Flux Upper Limit: 1.48e-07 ph cm-2 s-1
Energy Flux Upper Limit: 1.11e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/559002/likelihoodResults_433987201_434246401_4FGL_J2252.0+4031_daily_bin751.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) = 5372.85949325
delta logL = -0.000374585784812

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 5372.85912008
delta logL = -1.41749933391e-06

Fit tolerance = 1e-08

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

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

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   5370.801     FROM MIGRAD    STATUS=CONVERGED    158 CALLS      320 TOTAL
                     EDM=   .23E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .66001E-02    .59701E-01    .90712E-03    .10234E-02
   2  Index         5.3492        1.7882        .63195E-01    .14555E-03
   3  Normalizat    .85657        .10200        .11181        .38731E-04
   4  Prefactor     .98218        .31681E-01    .32785E-01    .82378E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.00660014
  Index      = 5.34915
  Normalizat = 0.856573
  Prefactor  = 0.982184
 **********
 **   18 **HESSE 
 **********

 FCN=   5370.801     FROM HESSE     STATUS=NOT POSDEF    35 CALLS      355 TOTAL
                     EDM=   .18E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .66001E-02    .11358        .34500E-04   -1.5692    
   2  Index         5.3492        2.6869        .25876E-02    .69887E-01
   3  Normalizat    .85657        .30461        .49582E-03   -.98003    
   4  Prefactor     .98218        .93237E-01    .14487E-03   -.93326    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 1.81195e-10
Minuit parameter uncertainties:
  1  0.054344
  2  2.83755
  3  0.305221
  4  0.0932524
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/559002': 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) = 5370.80076359
delta logL = 2.05835507835

Extracting fit parameters...

4FGL J2252.0+4031
   Spectrum: PowerLaw
404    Prefactor:  6.600e-03  5.434e-02  1.000e-04  1.000e+04 ( 1.000e-13)
405        Index:  5.349e+00  2.838e+00  0.000e+00  1.000e+01 (-1.000e+00)
406        Scale:  2.181e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
586    Prefactor:  9.822e-01  9.325e-02  0.000e+00  1.000e+01 ( 1.000e+00)
587        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
588        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
581   Normalization:  8.566e-01  3.052e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 4.54
Ra Dec: 343.010 40.523
Photon Index (Free Index): 5.35 +/- 2.84
Photon Flux (Free Index): 2.22e-07 +/- 1.30e-07
Energy Flux (Free Index): 2.87e-05 +/- 1.88e-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/559002/cmap_HighResolution_433987201_434246401_4FGL_J2252.0+4031_daily_bin751.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='1.11e-02', comment='SUCCESS', energy_flux2='2.87e-05', dlogl='2.06e+00', photon_flux2='2.22e-07', job_status='DONE', time_completed='2021-09-29 01:14:28.343689', photon_index_error2='2.84', photon_index2='5.35', ts='-0.00', fit_tolerance='1e-08', GAL='0.94', photon_index_error='0.00', photon_flux_upper_limit='1.48e-07', energy_flux_error2='1.88e-05', EG='1.10', time_epoch_completed='1632903268.34', return_code='0', job_id='559002', GAL2='0.98', EG2='0.86', return_code2='102', photon_flux_error2='1.30e-07', ts2='4.54', photon_index='2.05' WHERE bin_id='751' AND source_name='4FGL J2252.0+4031' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Wed Sep 29 01:14:28 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0171>
Subject: Job 559002: <4FGL_J2252.0+4031_daily_bin751> in cluster <slac> Done

Job <4FGL_J2252.0+4031_daily_bin751> was submitted from host <rhel6-64f> by user <kocevski> in cluster <slac> at Wed Sep 29 01:00:30 2021
Job was executed on host(s) <bullet0171>, in queue <medium>, as user <kocevski> in cluster <slac> at Wed Sep 29 01:00:31 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Wed Sep 29 01:00:31 2021
Terminated at Wed Sep 29 01:14:29 2021
Results reported at Wed Sep 29 01:14:29 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J2252.0+4031_daily_bin751 343.01 40.5232 433987201 434246401 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J2252.0+4031 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   635.00 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             314.37 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   837 sec.
    Turnaround time :                            839 sec.

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

