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


Performing analysis on: 4FGL_J2221.9-3504_daily_bin1012
RA = 335.497, Dec = -35.0712
tmin = 501638401, tmax = 501897601
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='273524', job_status='RUN', time_executed='2021-09-28 09:57:17.528385', time_epoch_executed='1632848237.53' WHERE source_name='4FGL J2221.9-3504' and cadence='daily' and bin_id='1012'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/273524

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/273524/ft1_4FGL_J2221.9-3504_daily_bin1012.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/273524/ft2_4FGL_J2221.9-3504_daily_bin1012.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/273524/ft1_4FGL_J2221.9-3504_daily_bin1012.fits outfile=/scratch/kocevski/273524/ft1_filteredMKT_4FGL_J2221.9-3504_daily_bin1012.fits ra=335.497 dec=-35.0712 rad=12.0 tmin=501638401.0 tmax=501897601.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.49
user 3.27
sys 0.19

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/273524/ft2_4FGL_J2221.9-3504_daily_bin1012.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/273524/ft2_4FGL_J2221.9-3504_daily_bin1012.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/273524/ft1_filteredMKT_4FGL_J2221.9-3504_daily_bin1012.fits evtable="EVENTS" outfile="/scratch/kocevski/273524/ft1_filtered_4FGL_J2221.9-3504_daily_bin1012.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/273524/ft1_filtered_4FGL_J2221.9-3504_daily_bin1012.fits" evtable="EVENTS" scfile=/scratch/kocevski/273524/ft2_4FGL_J2221.9-3504_daily_bin1012.fits sctable="SC_DATA" outfile=/scratch/kocevski/273524/ltcube_501638401_501897601_4FGL_J2221.9-3504_daily_bin1012.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/273524/ft2_4FGL_J2221.9-3504_daily_bin1012.fits
.....................!
real 11.69
user 11.32
sys 0.34

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/273524/ft1_filtered_4FGL_J2221.9-3504_daily_bin1012.fits evtable="EVENTS" scfile=/scratch/kocevski/273524/ft2_4FGL_J2221.9-3504_daily_bin1012.fits sctable="SC_DATA" expcube=/scratch/kocevski/273524/ltcube_501638401_501897601_4FGL_J2221.9-3504_daily_bin1012.fits outfile=/scratch/kocevski/273524/expmap_501638401_501897601_4FGL_J2221.9-3504_daily_bin1012.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/273524/ltcube_501638401_501897601_4FGL_J2221.9-3504_daily_bin1012.fits
.....................!
real 190.04
user 185.36
sys 4.37

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

Setting source of interest to:
4FGL J2221.9-3504 @ 335.497 -35.0712

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/273524/ft1_filtered_4FGL_J2221.9-3504_daily_bin1012.fits scfile=/scratch/kocevski/273524/ft2_4FGL_J2221.9-3504_daily_bin1012.fits outfile=/scratch/kocevski/273524/cmap_501638401_501897601_4FGL_J2221.9-3504_daily_bin1012.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=335.497 yref=-35.0712 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.37
sys 0.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/273524/ft1_filtered_4FGL_J2221.9-3504_daily_bin1012.fits scfile=/scratch/kocevski/273524/ft2_4FGL_J2221.9-3504_daily_bin1012.fits outfile=/scratch/kocevski/273524/cmap_HighResolution_501638401_501897601_4FGL_J2221.9-3504_daily_bin1012.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=335.497 yref=-35.0712 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.57
user 0.37
sys 0.16

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/273524/ft1_filtered_4FGL_J2221.9-3504_daily_bin1012.fits evtable="EVENTS" scfile=/scratch/kocevski/273524/ft2_4FGL_J2221.9-3504_daily_bin1012.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/273524/Model_4FGL_J2221.9-3504_daily_bin1012.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/273524/ft1_filtered_4FGL_J2221.9-3504_daily_bin1012.fits....................!
real 51.38
user 50.19
sys 1.10

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/273524/ft1_filtered_4FGL_J2221.9-3504_daily_bin1012.fits', '/scratch/kocevski/273524/ft2_4FGL_J2221.9-3504_daily_bin1012.fits', expMap='/scratch/kocevski/273524/expmap_501638401_501897601_4FGL_J2221.9-3504_daily_bin1012.fits', expCube='/scratch/kocevski/273524/ltcube_501638401_501897601_4FGL_J2221.9-3504_daily_bin1012.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/273524/Model_4FGL_J2221.9-3504_daily_bin1012.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J2221.9-3504'

4FGL J2221.9-3504
   Spectrum: PowerLaw
253    Prefactor:  1.240e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-12)
254        Index:  2.677e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
255        Scale:  5.158e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/273524/ft1_filtered_4FGL_J2221.9-3504_daily_bin1012.fits
Spacecraft file(s): /scratch/kocevski/273524/ft2_4FGL_J2221.9-3504_daily_bin1012.fits
Exposure map: /scratch/kocevski/273524/expmap_501638401_501897601_4FGL_J2221.9-3504_daily_bin1012.fits
Exposure cube: /scratch/kocevski/273524/ltcube_501638401_501897601_4FGL_J2221.9-3504_daily_bin1012.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/273524/Model_4FGL_J2221.9-3504_daily_bin1012.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) = 6499.81260547

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    10.533       1.0000         .10000E-03   10000.    
     2 'Prefactor '    10.050       1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     4 'norm      '    4.5452       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10073E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10031E-03   1.0000         .10000E-03   10000.    
     7 'norm      '    3.6779       1.0000         .10000E-03   10000.    
     8 'norm      '    .76728       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    52.734       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10006E-03   1.0000         .10000E-03   10000.    
    13 'norm      '    .10007E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    27.439       1.0000         .10000E-03   10000.    
    15 'Prefactor '    26.768       1.0000         .10000E-03   10000.    
    16 'Prefactor '    1.3604       1.0000         .10000E-03   10000.    
    17 'norm      '    .10005E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10062E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
    21 'norm      '    .10018E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10275E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    9.0506       1.0000         .10000E-03   10000.    
    24 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
    25 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    26 'Prefactor '    .13647E-03   1.0000         .10000E-03   10000.    
    27 'Normalizat'    .94062       1.0000         .10000E-01   10.000    
    28 'Prefactor '    .88510       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5630E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   6499.686     FROM MIGRAD    STATUS=CONVERGED    657 CALLS     3449 TOTAL
                     EDM=   .33E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.6%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          10.534        4.7894       -.63715E-07   -.44218E-04
   2  Prefactor     10.051        8.3435        .51945E-07   -.70882E-03
   3  Prefactor     .10000E-03    8.8344        .75782E-06** at limit **
   4  norm          4.5454        4.4928        .41771E-06   -.13678E-02
   5  Prefactor     .10000E-03    16.924       -.29825E-05** at limit **
   6  Prefactor     .10000E-03    31.611       -.22477E-05** at limit **
   7  norm          3.6785        4.5783        .12165E-05    .82391E-04
   8  norm          .76729        .32972       -.61481E-07    .24070E-03
   9  Prefactor     .10000E-03    2.6689        .47411E-06** at limit **
  10  Prefactor     52.733        20.509       -.11182E-06   -.13531E-04
  11  Prefactor     .10000E-03    2.1717        .16888E-06** at limit **
  12  Prefactor     .10000E-03    .74401       -.12433E-06** at limit **
  13  norm          .10000E-03    8.5292       -.91561E-06** at limit **
  14  Prefactor     27.437        28.641       -.13907E-05   -.29619E-04
  15  Prefactor     26.769        21.548        .48148E-06    .62521E-05
  16  Prefactor     1.3603        34.327        .86779E-07   -.46190E-04
  17  norm          .10000E-03    .70689       -.85794E-07** at limit **
  18  Prefactor     .10000E-03    21.618        .58109E-05** at limit **
  19  Prefactor     .10000E-03    2.5035        .31606E-07** at limit **
  20  Prefactor     .10000E-03    2.6564       -.42716E-06** at limit **
  21  norm          .10000E-03    1.2259        .51143E-07** at limit **
  22  Prefactor     .10000E-03    7.7648        .40783E-06** at limit **
  23  Prefactor     9.0421        6.7840       -.11692E-06    .46967E-04
  24  norm          .10000E-03    .20600        .35989E-07** at limit **
  25  Prefactor     .10000E-03    13.132        .14909E-05** at limit **
  26  Prefactor     .10000E-03    17.324       -.26513E-05** at limit **
  27  Normalizat    .94067        .16365       -.83905E-06    .35119E-04
  28  Prefactor     .88506        .14575        .37998E-06   -.27205E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 10.5335
  Prefactor  = 10.0505
  Prefactor  = 0.0001
  norm       = 4.54537
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 3.67849
  norm       = 0.767286
  Prefactor  = 0.0001
  Prefactor  = 52.7335
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 27.4369
  Prefactor  = 26.7692
  Prefactor  = 1.36033
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 9.04211
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Normalizat = 0.940672
  Prefactor  = 0.885064
 **********
 **   18 **HESSE 
 **********

 FCN=   6499.686     FROM HESSE     STATUS=OK           513 CALLS     3962 TOTAL
                     EDM=   .27E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          10.534        4.7911        .11526E-03   -1.5059    
   2  Prefactor     10.051        8.5351        .63199E-03   -1.5074    
   3  Prefactor     .10000E-03    8.9498        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  norm          4.5454        7.7764        .94413E-03   -1.5282    
   5  Prefactor     .10000E-03    17.156        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    31.740        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  norm          3.6785        4.6124        .17146E-03   -1.5324    
   8  norm          .76729        .33082        .27702E-04   -1.5533    
   9  Prefactor     .10000E-03    2.6704        .12863E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     52.733        20.532        .55231E-04   -1.4254    
  11  Prefactor     .10000E-03    2.1788        .11600E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10000E-03    .74604        .67873E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  norm          .10000E-03    8.5496        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     27.437        28.647        .76480E-04   -1.4660    
  15  Prefactor     26.769        21.548        .77430E-04   -1.4673    
  16  Prefactor     1.3603        35.043        .37445E-03   -1.5475    
  17  norm          .10000E-03    .71352        .66172E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .10000E-03    21.760        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10000E-03    2.5094        .12457E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .10000E-03    2.6802        .12823E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  norm          .10000E-03    1.2361        .87108E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     .10000E-03    7.8099        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     9.0421        6.7695        .13322E-03   -1.5106    
  24  norm          .10000E-03    .20609        .18142E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     .10000E-03    13.142        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  Prefactor     .10000E-03    17.317        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  Normalizat    .94067        .19153        .23904E-03   -.95045    
  28  Prefactor     .88506        .17117        .22605E-03   -.96665    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.73867e-09
Minuit parameter uncertainties:
  1  4.79127
  2  8.53618
  3  1.58243e-05
  4  7.77815
  5  0.000124593
  6  0.000123179
  7  4.6128
  8  0.330819
  9  4.84156e-06
  10  20.535
  11  1.51823e-06
  12  2.40765e-07
  13  1.51628e-05
  14  28.6609
  15  21.554
  16  13.8171
  17  1.33287e-07
  18  0.000183044
  19  1.1801e-06
  20  1.5066e-06
  21  1.61581e-06
  22  1.80954e-05
  23  6.77003
  24  2.41241e-07
  25  3.63697e-05
  26  1.13565e-05
  27  0.191672
  28  0.17127
Done.

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

Extracting fit parameters...

4FGL J2221.9-3504
   Spectrum: PowerLaw
253    Prefactor:  1.000e-04  1.518e-06  1.000e-04  1.000e+04 ( 1.000e-12)
254        Index:  2.677e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
255        Scale:  5.158e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
560    Prefactor:  8.851e-01  1.713e-01  0.000e+00  1.000e+01 ( 1.000e+00)
561        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
562        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
559   Normalization:  9.407e-01  1.917e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 335.497 -35.071
Photon Flux Upper Limit: 5.00e-08 ph cm-2 s-1
Energy Flux Upper Limit: 3.93e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/273524/likelihoodResults_501638401_501897601_4FGL_J2221.9-3504_daily_bin1012.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) = 6499.68772508
delta logL = -0.0021812402174

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 6499.68554416
delta logL = -3.22848791257e-07

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10048E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.6633       1.0000          .0000       10.000    
     3 'Normalizat'    .94078       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .88493       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5630E+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=   6499.686     FROM MIGRAD    STATUS=CONVERGED    100 CALLS      247 TOTAL
                     EDM=   .67E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    26.664        .11687E-01** at limit **
   2  Index         2.1332        6.1472        .50000        .39252E-06
   3  Normalizat    .94067        .12792E-01    .23904E-03    .95593E-04
   4  Prefactor     .88506        .11833E-01    .22605E-03    .11607E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Index      = 2.1332
  Normalizat = 0.940671
  Prefactor  = 0.885064
 **********
 **   18 **HESSE 
 **********

 FCN=   6499.686     FROM HESSE     STATUS=NOT POSDEF    29 CALLS      276 TOTAL
                     EDM=   .57E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    224.09        .12651E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.1332        8.7085        .50000       -.61060    
   3  Normalizat    .94067        .41094E-01    .95618E-05   -.95045    
   4  Prefactor     .88506        .38015E-01    .90421E-05   -.96665    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 5.66952e-09
Minuit parameter uncertainties:
  1  5.21284e-05
  2  890.184
  3  0.0410949
  4  0.0380157
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/273524': 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) = 6499.68554016
delta logL = 3.67838765669e-06

Extracting fit parameters...

4FGL J2221.9-3504
   Spectrum: PowerLaw
253    Prefactor:  1.000e-04  5.213e-05  1.000e-04  1.000e+04 ( 1.000e-12)
254        Index:  2.133e+00  8.902e+02  0.000e+00  1.000e+01 (-1.000e+00)
255        Scale:  5.158e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
560    Prefactor:  8.851e-01  3.802e-02  0.000e+00  1.000e+01 ( 1.000e+00)
561        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
562        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
559   Normalization:  9.407e-01  4.109e-02  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 335.497 -35.071

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/273524/cmap_HighResolution_501638401_501897601_4FGL_J2221.9-3504_daily_bin1012.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='3.93e-03', job_status='DONE', photon_flux_upper_limit='5.00e-08', time_completed='2021-09-28 10:10:09.847045', job_id='273524', GAL2='0.89', fit_tolerance='1e-08', EG2='0.94', EG='0.94', time_epoch_completed='1632849009.85', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.89', dlogl='3.68e-06', ts2='-0.00', photon_index_error='0.00', photon_index='2.68' WHERE bin_id='1012' AND source_name='4FGL J2221.9-3504' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Tue Sep 28 10:10:09 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0243>
Subject: Job 273524: <4FGL_J2221.9-3504_daily_bin1012> in cluster <slac> Done

Job <4FGL_J2221.9-3504_daily_bin1012> was submitted from host <rhel6-64h> by user <kocevski> in cluster <slac> at Tue Sep 28 09:56:00 2021
Job was executed on host(s) <bullet0243>, in queue <medium>, as user <kocevski> in cluster <slac> at Tue Sep 28 09:56:01 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Tue Sep 28 09:56:01 2021
Terminated at Tue Sep 28 10:10:10 2021
Results reported at Tue Sep 28 10:10:10 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J2221.9-3504_daily_bin1012 335.497 -35.0712 501638401 501897601 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J2221.9-3504 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   771.45 sec.
    Max Memory :                                 1094 MB
    Average Memory :                             307.00 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   849 sec.
    Turnaround time :                            850 sec.

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

