/nfs/farm/g/glast/g/LCRepository/bin/miniconda2/envs/fermitools_v1.0.5/lib/python2.7/site-packages/pyfits/__init__.py:22: PyFITSDeprecationWarning: PyFITS is deprecated, please use astropy.io.fits
  PyFITSDeprecationWarning)  # noqa

Likelihood Analysis Tool
Support Contact: Daniel Kocevski (daniel.kocevski@nasa.gov)


Waiting 5 seconds before starting...
Proceeding.

Importing modules...
This is make3FGLxml version 01r0.
The default diffuse model files and names are for pass 8 and assume you have v10r00p05 of the Fermi Science Tools or higher.
This is make4FGLxml version 01r04.
The default diffuse model files and names are for pass 8 and 4FGL and assume you have v11r5p3 of the Fermi Science Tools or higher.

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

/nfs/farm/g/glast/g/LCRepository/bin/miniconda2/envs/fermitools_v1.0.5/lib/python2.7/site-packages/matplotlib/cbook/deprecation.py:106: MatplotlibDeprecationWarning: The mpl_toolkits.axes_grid module was deprecated in version 2.1. Use mpl_toolkits.axes_grid1 and mpl_toolkits.axisartist provies the same functionality instead.
  warnings.warn(message, mplDeprecation, stacklevel=1)

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

number of points = 7382
number of fields = 31
RA_SUN column already exists. File will not be modified.
Done.


Performing analysis on: 4FGL_J2216.9+2421_daily_bin1589
RA = 334.238, Dec = 24.3575
tmin = 651196801, tmax = 651456001
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='233185', job_status='RUN', time_executed='2021-09-28 07:41:02.932073', time_epoch_executed='1632840062.93' WHERE source_name='4FGL J2216.9+2421' and cadence='daily' and bin_id='1589'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/233185

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/233185/ft1_4FGL_J2216.9+2421_daily_bin1589.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/233185/ft2_4FGL_J2216.9+2421_daily_bin1589.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/233185/ft1_4FGL_J2216.9+2421_daily_bin1589.fits outfile=/scratch/kocevski/233185/ft1_filteredMKT_4FGL_J2216.9+2421_daily_bin1589.fits ra=334.238 dec=24.3575 rad=12.0 tmin=651196801.0 tmax=651456001.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.57
user 3.33
sys 0.21

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/233185/ft2_4FGL_J2216.9+2421_daily_bin1589.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/233185/ft2_4FGL_J2216.9+2421_daily_bin1589.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/233185/ft1_filteredMKT_4FGL_J2216.9+2421_daily_bin1589.fits evtable="EVENTS" outfile="/scratch/kocevski/233185/ft1_filtered_4FGL_J2216.9+2421_daily_bin1589.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.33
sys 0.15

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/233185/ft1_filtered_4FGL_J2216.9+2421_daily_bin1589.fits" evtable="EVENTS" scfile=/scratch/kocevski/233185/ft2_4FGL_J2216.9+2421_daily_bin1589.fits sctable="SC_DATA" outfile=/scratch/kocevski/233185/ltcube_651196801_651456001_4FGL_J2216.9+2421_daily_bin1589.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/233185/ft2_4FGL_J2216.9+2421_daily_bin1589.fits
.....................!
real 11.84
user 11.48
sys 0.31

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/233185/ft1_filtered_4FGL_J2216.9+2421_daily_bin1589.fits evtable="EVENTS" scfile=/scratch/kocevski/233185/ft2_4FGL_J2216.9+2421_daily_bin1589.fits sctable="SC_DATA" expcube=/scratch/kocevski/233185/ltcube_651196801_651456001_4FGL_J2216.9+2421_daily_bin1589.fits outfile=/scratch/kocevski/233185/expmap_651196801_651456001_4FGL_J2216.9+2421_daily_bin1589.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/233185/ltcube_651196801_651456001_4FGL_J2216.9+2421_daily_bin1589.fits
.....................!
real 190.90
user 185.17
sys 5.25

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 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 159 point sources and 1 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 J2216.9+2421 @ 334.238 24.3575

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/233185/ft1_filtered_4FGL_J2216.9+2421_daily_bin1589.fits scfile=/scratch/kocevski/233185/ft2_4FGL_J2216.9+2421_daily_bin1589.fits outfile=/scratch/kocevski/233185/cmap_651196801_651456001_4FGL_J2216.9+2421_daily_bin1589.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=334.238 yref=24.3575 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

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/233185/ft1_filtered_4FGL_J2216.9+2421_daily_bin1589.fits scfile=/scratch/kocevski/233185/ft2_4FGL_J2216.9+2421_daily_bin1589.fits outfile=/scratch/kocevski/233185/cmap_HighResolution_651196801_651456001_4FGL_J2216.9+2421_daily_bin1589.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=334.238 yref=24.3575 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/233185/ft1_filtered_4FGL_J2216.9+2421_daily_bin1589.fits evtable="EVENTS" scfile=/scratch/kocevski/233185/ft2_4FGL_J2216.9+2421_daily_bin1589.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/233185/Model_4FGL_J2216.9+2421_daily_bin1589.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
Working on...
/scratch/kocevski/233185/ft1_filtered_4FGL_J2216.9+2421_daily_bin1589.fits.....................!
real 125.83
user 124.33
sys 1.22

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/233185/ft1_filtered_4FGL_J2216.9+2421_daily_bin1589.fits', '/scratch/kocevski/233185/ft2_4FGL_J2216.9+2421_daily_bin1589.fits', expMap='/scratch/kocevski/233185/expmap_651196801_651456001_4FGL_J2216.9+2421_daily_bin1589.fits', expCube='/scratch/kocevski/233185/ltcube_651196801_651456001_4FGL_J2216.9+2421_daily_bin1589.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/233185/Model_4FGL_J2216.9+2421_daily_bin1589.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J2216.9+2421'

4FGL J2216.9+2421
   Spectrum: PowerLaw
286    Prefactor:  5.564e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
287        Index:  2.284e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
288        Scale:  1.223e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/233185/ft1_filtered_4FGL_J2216.9+2421_daily_bin1589.fits
Spacecraft file(s): /scratch/kocevski/233185/ft2_4FGL_J2216.9+2421_daily_bin1589.fits
Exposure map: /scratch/kocevski/233185/expmap_651196801_651456001_4FGL_J2216.9+2421_daily_bin1589.fits
Exposure cube: /scratch/kocevski/233185/ltcube_651196801_651456001_4FGL_J2216.9+2421_daily_bin1589.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/233185/Model_4FGL_J2216.9+2421_daily_bin1589.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) = 7736.2694049

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .14501E-03   1.0000         .10000E-03   10000.    
     2 'norm      '    .10002E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10082E-03   1.0000         .10000E-03   10000.    
     5 'norm      '    .12758       1.0000         .10000E-03   10000.    
     6 'Prefactor '    175.84       1.0000         .10000E-03   10000.    
     7 'norm      '    .48861       1.0000         .10000E-03   10000.    
     8 'Prefactor '    .13675E-03   1.0000         .10000E-03   10000.    
     9 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    62.924       1.0000         .10000E-03   10000.    
    11 'Prefactor '    5.7230       1.0000         .10000E-03   10000.    
    12 'norm      '    1.3553       1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    .81312       1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    16.334       1.0000         .10000E-03   10000.    
    17 'Prefactor '    1.2106       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    19 'Normalizat'    .62852       1.0000         .10000E-01   10.000    
    20 'Prefactor '    1.0884       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5350E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   7736.258     FROM MIGRAD    STATUS=CONVERGED    435 CALLS     2109 TOTAL
                     EDM=   .16E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .6%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    258.20       -.14744E-07** at limit **
   2  norm          .10000E-03    1.0497        .16110E-07** at limit **
   3  Prefactor     .10000E-03    3.3109        .18579E-07** at limit **
   4  Prefactor     .10000E-03    32.838        .20702E-07** at limit **
   5  norm          .12753        .43596       -.67035E-06   -.32032E-02
   6  Prefactor     175.84        70.222       -.11153E-05    .10459E-03
   7  norm          .48859        .79427       -.15528E-06   -.16556E-02
   8  Prefactor     .10000E-03    8.4657       -.52957E-06** at limit **
   9  norm          .10000E-03    1.5754        .18288E-07** at limit **
  10  Prefactor     62.938        103.52        .13801E-04   -.15057E-03
  11  Prefactor     5.7242        9.6754       -.14848E-05    .67553E-04
  12  norm          1.3552        .98559       -.11282E-06   -.48023E-03
  13  Prefactor     .10000E-03    13.903        .51731E-08** at limit **
  14  norm          .81383        1.3637       -.11570E-06   -.56020E-03
  15  Prefactor     .10000E-03    10.968        .31332E-08** at limit **
  16  Prefactor     16.332        11.188        .10108E-05   -.22729E-03
  17  Prefactor     1.2106        .29385       -.10708E-08    .55460E-04
  18  Prefactor     .10000E-03    2.7432       -.74643E-08** at limit **
  19  Normalizat    .62852        .23769       -.10236E-05    .67246E-04
  20  Prefactor     1.0884        .10879        .29145E-06    .17952E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.127533
  Prefactor  = 175.837
  norm       = 0.488592
  Prefactor  = 0.000100001
  norm       = 0.0001
  Prefactor  = 62.9376
  Prefactor  = 5.72418
  norm       = 1.35522
  Prefactor  = 0.0001
  norm       = 0.813826
  Prefactor  = 0.0001
  Prefactor  = 16.3325
  Prefactor  = 1.21059
  Prefactor  = 0.0001
  Normalizat = 0.628522
  Prefactor  = 1.08844
 **********
 **   18 **HESSE 
 **********

 FCN=   7736.258     FROM HESSE     STATUS=OK           295 CALLS     2404 TOTAL
                     EDM=   .30E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    260.11        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  norm          .10000E-03    1.0870        .17586E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10000E-03    3.3276        .15627E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    33.045        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  norm          .12753        .52307        .11994E-03   -1.5637    
   6  Prefactor     175.84        69.938        .30434E-04   -1.3048    
   7  norm          .48859        .74582        .97198E-03   -1.5568    
   8  Prefactor     .10000E-03    53.323        .48968E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  norm          .10000E-03    1.5803        .10780E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     62.938        96.214        .50587E-04   -1.4120    
  11  Prefactor     5.7242        9.6579        .16790E-03   -1.5229    
  12  norm          1.3552        .97576        .71465E-04   -1.5475    
  13  Prefactor     .10000E-03    13.947        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          .81383        1.0619        .12780E-02   -1.5528    
  15  Prefactor     .10000E-03    10.972        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     16.332        10.974        .99101E-04   -1.4899    
  17  Prefactor     1.2106        .29349        .22593E-04   -1.5488    
  18  Prefactor     .10000E-03    2.7463        .14227E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Normalizat    .62852        .26072        .42705E-03   -1.0679    
  20  Prefactor     1.0884        .12219        .16094E-03   -.89837    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.992e-09
Minuit parameter uncertainties:
  1  6.69848e-05
  2  1.63423e-06
  3  3.65409e-06
  4  6.16851e-05
  5  0.516364
  6  69.9713
  7  0.745832
  8  0.000426049
  9  2.28735e-06
  10  96.4534
  11  9.66055
  12  0.975773
  13  1.77373e-06
  14  1.06195
  15  4.43861e-07
  16  10.9756
  17  0.29349
  18  8.33886e-07
  19  0.261227
  20  0.122225
Done.

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

Extracting fit parameters...

4FGL J2216.9+2421
   Spectrum: PowerLaw
286    Prefactor:  1.000e-04  4.260e-04  1.000e-04  1.000e+04 ( 1.000e-13)
287        Index:  2.284e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
288        Scale:  1.223e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
532    Prefactor:  1.088e+00  1.222e-01  0.000e+00  1.000e+01 ( 1.000e+00)
533        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
534        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
531   Normalization:  6.285e-01  2.612e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 334.238 24.358
Photon Flux Upper Limit: 7.28e-08 ph cm-2 s-1
Energy Flux Upper Limit: 5.58e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/233185/likelihoodResults_651196801_651456001_4FGL_J2216.9+2421_daily_bin1589.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) = 7736.25792816
delta logL = -8.72000346135e-05

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 7736.25792815
delta logL = -8.71897827892e-05

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .96356E-02   1.0000         .10000E-03   10000.    
     2 'Index     '    2.2845       1.0000          .0000       10.000    
     3 'Normalizat'    .62852       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.0884       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5350E+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=   7736.185     FROM MIGRAD    STATUS=CONVERGED    141 CALLS      304 TOTAL
                     EDM=   .20E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .37518        141.57        .14058E-03   -.16093E-04
   2  Index         3.7141        7.4943        .87931E-02    .10910E-04
   3  Normalizat    .60741        .19868        .43400E-03   -.34997E-04
   4  Prefactor     1.0942        .96194E-01    .16055E-03   -.86673E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.375179
  Index      = 3.71408
  Normalizat = 0.607413
  Prefactor  = 1.0942
 **********
 **   18 **HESSE 
 **********

 FCN=   7736.185     FROM HESSE     STATUS=OK            25 CALLS      329 TOTAL
                     EDM=   .90E-11    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .37518        5.8627        .56232E-05   -1.5585    
   2  Index         3.7141        3.3115        .35173E-03   -.26011    
   3  Normalizat    .60741        .25184        .17360E-04   -1.0767    
   4  Prefactor     1.0942        .12132        .64220E-05   -.89652    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 8.95026e-12
Minuit parameter uncertainties:
  1  2.96613
  2  3.64843
  3  0.252313
  4  0.121346
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/233185': 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): 0
logL (Free Index) = 7736.18493977
delta logL = 0.072901193008

Extracting fit parameters...

4FGL J2216.9+2421
   Spectrum: PowerLaw
286    Prefactor:  3.752e-01  2.966e+00  1.000e-04  1.000e+04 ( 1.000e-13)
287        Index:  3.714e+00  3.648e+00  0.000e+00  1.000e+01 (-1.000e+00)
288        Scale:  1.223e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
532    Prefactor:  1.094e+00  1.213e-01  0.000e+00  1.000e+01 ( 1.000e+00)
533        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
534        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
531   Normalization:  6.074e-01  2.523e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 334.238 24.358

Creating a high resolution counts map...
INFO: Auto-setting vmin to -1.000e-01 [aplpy.core]
INFO: Auto-setting vmax to  1.110e+00 [aplpy.core]
Saving /scratch/kocevski/233185/cmap_HighResolution_651196801_651456001_4FGL_J2216.9+2421_daily_bin1589.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='5.58e-03', job_status='DONE', photon_flux_upper_limit='7.28e-08', time_completed='2021-09-28 07:53:11.444695', job_id='233185', GAL2='1.09', fit_tolerance='1e-08', EG2='0.61', EG='0.63', time_epoch_completed='1632840791.44', return_code2='0', ts='-0.00', comment='SUCCESS', return_code='0', GAL='1.09', dlogl='7.29e-02', ts2='0.16', photon_index_error='0.00', photon_index='2.28' WHERE bin_id='1589' AND source_name='4FGL J2216.9+2421' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Tue Sep 28 07:53:11 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0066>
Subject: Job 233185: <4FGL_J2216.9+2421_daily_bin1589> in cluster <slac> Done

Job <4FGL_J2216.9+2421_daily_bin1589> was submitted from host <rhel6-64j> by user <kocevski> in cluster <slac> at Tue Sep 28 07:40:45 2021
Job was executed on host(s) <bullet0066>, in queue <medium>, as user <kocevski> in cluster <slac> at Tue Sep 28 07:40:47 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Tue Sep 28 07:40:47 2021
Terminated at Tue Sep 28 07:53:12 2021
Results reported at Tue Sep 28 07:53:12 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J2216.9+2421_daily_bin1589 334.238 24.3575 651196801 651456001 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J2216.9+2421 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   716.28 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             398.68 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   744 sec.
    Turnaround time :                            747 sec.

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

