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


Performing analysis on: 4FGL_J2221.9-3504_daily_bin461
RA = 335.497, Dec = -35.0712
tmin = 358819201, tmax = 359078401
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='271673', job_status='RUN', time_executed='2021-09-28 09:53:47.442046', time_epoch_executed='1632848027.44' WHERE source_name='4FGL J2221.9-3504' and cadence='daily' and bin_id='461'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/271673

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

Retrieving the FT1 file...

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

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

Retrieving 49 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/271673/ft1_4FGL_J2221.9-3504_daily_bin461.fits


Retrieving the FT1 file...

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

Retrieving 49 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/271673/ft2_4FGL_J2221.9-3504_daily_bin461.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/271673/ft1_4FGL_J2221.9-3504_daily_bin461.fits outfile=/scratch/kocevski/271673/ft1_filteredMKT_4FGL_J2221.9-3504_daily_bin461.fits ra=335.497 dec=-35.0712 rad=12.0 tmin=358819201.0 tmax=359078401.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 5.33
user 5.06
sys 0.24

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/271673/ft2_4FGL_J2221.9-3504_daily_bin461.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/271673/ft1_filteredMKT_4FGL_J2221.9-3504_daily_bin461.fits evtable="EVENTS" outfile="/scratch/kocevski/271673/ft1_filtered_4FGL_J2221.9-3504_daily_bin461.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.51
user 0.33
sys 0.15

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/271673/ft1_filtered_4FGL_J2221.9-3504_daily_bin461.fits" evtable="EVENTS" scfile=/scratch/kocevski/271673/ft2_4FGL_J2221.9-3504_daily_bin461.fits sctable="SC_DATA" outfile=/scratch/kocevski/271673/ltcube_358819201_359078401_4FGL_J2221.9-3504_daily_bin461.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/271673/ft2_4FGL_J2221.9-3504_daily_bin461.fits
.....................!
real 11.79
user 11.43
sys 0.33

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/271673/ft1_filtered_4FGL_J2221.9-3504_daily_bin461.fits evtable="EVENTS" scfile=/scratch/kocevski/271673/ft2_4FGL_J2221.9-3504_daily_bin461.fits sctable="SC_DATA" expcube=/scratch/kocevski/271673/ltcube_358819201_359078401_4FGL_J2221.9-3504_daily_bin461.fits outfile=/scratch/kocevski/271673/expmap_358819201_359078401_4FGL_J2221.9-3504_daily_bin461.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/271673/ltcube_358819201_359078401_4FGL_J2221.9-3504_daily_bin461.fits
.....................!
real 191.17
user 185.73
sys 5.12

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/271673/ft1_filtered_4FGL_J2221.9-3504_daily_bin461.fits scfile=/scratch/kocevski/271673/ft2_4FGL_J2221.9-3504_daily_bin461.fits outfile=/scratch/kocevski/271673/cmap_358819201_359078401_4FGL_J2221.9-3504_daily_bin461.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.52
user 0.37
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/271673/ft1_filtered_4FGL_J2221.9-3504_daily_bin461.fits scfile=/scratch/kocevski/271673/ft2_4FGL_J2221.9-3504_daily_bin461.fits outfile=/scratch/kocevski/271673/cmap_HighResolution_358819201_359078401_4FGL_J2221.9-3504_daily_bin461.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.54
user 0.38
sys 0.15

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/271673/ft1_filtered_4FGL_J2221.9-3504_daily_bin461.fits evtable="EVENTS" scfile=/scratch/kocevski/271673/ft2_4FGL_J2221.9-3504_daily_bin461.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/271673/Model_4FGL_J2221.9-3504_daily_bin461.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/271673/ft1_filtered_4FGL_J2221.9-3504_daily_bin461.fits.....................!
real 46.76
user 45.49
sys 1.19

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/271673/ft1_filtered_4FGL_J2221.9-3504_daily_bin461.fits', '/scratch/kocevski/271673/ft2_4FGL_J2221.9-3504_daily_bin461.fits', expMap='/scratch/kocevski/271673/expmap_358819201_359078401_4FGL_J2221.9-3504_daily_bin461.fits', expCube='/scratch/kocevski/271673/ltcube_358819201_359078401_4FGL_J2221.9-3504_daily_bin461.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/271673/Model_4FGL_J2221.9-3504_daily_bin461.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/271673/ft1_filtered_4FGL_J2221.9-3504_daily_bin461.fits
Spacecraft file(s): /scratch/kocevski/271673/ft2_4FGL_J2221.9-3504_daily_bin461.fits
Exposure map: /scratch/kocevski/271673/expmap_358819201_359078401_4FGL_J2221.9-3504_daily_bin461.fits
Exposure cube: /scratch/kocevski/271673/ltcube_358819201_359078401_4FGL_J2221.9-3504_daily_bin461.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/271673/Model_4FGL_J2221.9-3504_daily_bin461.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) = 5861.54122775

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    9.9779       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10217E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    5.3866       1.0000         .10000E-03   10000.    
     4 'norm      '    3.3943       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10058E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .23631E-03   1.0000         .10000E-03   10000.    
     7 'norm      '    .16022E-03   1.0000         .10000E-03   10000.    
     8 'norm      '    .90327       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10123E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10075E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10143E-03   1.0000         .10000E-03   10000.    
    13 'norm      '    6.7227       1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10044E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    24.886       1.0000         .10000E-03   10000.    
    16 'Prefactor '    .16060E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    .50198E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    29.809       1.0000         .10000E-03   10000.    
    19 'Prefactor '    12.148       1.0000         .10000E-03   10000.    
    20 'Prefactor '    8.4295       1.0000         .10000E-03   10000.    
    21 'norm      '    9.3178       1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10170E-03   1.0000         .10000E-03   10000.    
    24 'norm      '    5.1834       1.0000         .10000E-03   10000.    
    25 'Prefactor '    .10942E-03   1.0000         .10000E-03   10000.    
    26 'Prefactor '    .17732       1.0000         .10000E-03   10000.    
    27 'Normalizat'    1.1368       1.0000         .10000E-01   10.000    
    28 'Prefactor '    .93614       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=   5861.531     FROM MIGRAD    STATUS=CONVERGED    683 CALLS     3475 TOTAL
                     EDM=   .61E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  3.5%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          9.9781        5.9527        .14089E-06    .47481E-04
   2  Prefactor     .10000E-03    9.5727        .18697E-06** at limit **
   3  Prefactor     5.3926        9.9366       -.13029E-06   -.39142E-04
   4  norm          3.4003        9.9544        .23771E-05    .13639E-03
   5  Prefactor     .10000E-03    10.625        .55627E-07** at limit **
   6  Prefactor     .10000E-03    55.785       -.73796E-07** at limit **
   7  norm          .10000E-03    2.8080        .23007E-06** at limit **
   8  norm          .90318        .38614       -.14990E-07   -.48080E-03
   9  Prefactor     .10000E-03    8.2865        .31566E-08** at limit **
  10  Prefactor     .10000E-03    6.3890       -.39253E-07** at limit **
  11  Prefactor     .10000E-03    3.3422       -.24862E-08** at limit **
  12  Prefactor     .10000E-03    5.8067        .23848E-06** at limit **
  13  norm          6.7216        12.667        .55536E-06    .14247E-03
  14  Prefactor     .10000E-03    19.709        .62659E-07** at limit **
  15  Prefactor     24.867        23.250       -.10267E-06   -.12386E-03
  16  Prefactor     .10000E-03    25.489       -.24977E-06** at limit **
  17  norm          .10003E-03    2.9457       -.20694E-05** at limit **
  18  Prefactor     29.769        43.099        .50023E-05    .33113E-03
  19  Prefactor     12.145        11.960        .21627E-06    .84519E-04
  20  Prefactor     8.4310        7.6257        .20557E-07    .39710E-06
  21  norm          9.3162        5.4194        .91862E-07    .47734E-03
  22  Prefactor     .10000E-03    7.7380        .31800E-07** at limit **
  23  Prefactor     .10000E-03    10.242       -.38353E-07** at limit **
  24  norm          5.1835        1.1148        .12609E-07    .13407E-02
  25  Prefactor     .10000E-03    41.253        .23620E-06** at limit **
  26  Prefactor     .16952        6.0925       -.50946E-06    .98045E-04
  27  Normalizat    1.1368        .19738        .60473E-06    .24775E-03
  28  Prefactor     .93597        .17842       -.10047E-05    .26207E-03
                               ERR DEF=  .500    
Final values: 
  norm       = 9.9781
  Prefactor  = 0.0001
  Prefactor  = 5.39263
  norm       = 3.40033
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 0.903184
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 6.72157
  Prefactor  = 0.0001
  Prefactor  = 24.8674
  Prefactor  = 0.000100001
  norm       = 0.000100026
  Prefactor  = 29.7686
  Prefactor  = 12.1454
  Prefactor  = 8.43098
  norm       = 9.31623
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 5.18355
  Prefactor  = 0.000100001
  Prefactor  = 0.16952
  Normalizat = 1.13676
  Prefactor  = 0.935966
 **********
 **   18 **HESSE 
 **********

 FCN=   5861.531     FROM HESSE     STATUS=OK           513 CALLS     3988 TOTAL
                     EDM=   .45E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          9.9781        5.9545        .63427E-03   -1.5076    
   2  Prefactor     .10000E-03    9.6849        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     5.3926        9.9119        .17315E-03   -1.5243    
   4  norm          3.4003        10.176        .10980E-02   -1.5339    
   5  Prefactor     .10000E-03    10.644        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    55.954        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  norm          .10000E-03    5.4862        .24421E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          .90318        .38514        .29837E-04   -1.5518    
   9  Prefactor     .10000E-03    8.3385        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .10000E-03    6.3961        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .10000E-03    3.3560        .13667E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10000E-03    6.0629        .35942E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  norm          6.7216        12.672        .77378E-03   -1.5189    
  14  Prefactor     .10000E-03    19.722        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     24.867        23.311        .80299E-04   -1.4710    
  16  Prefactor     .10000E-03    25.690        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          .10003E-03    8.2377        .17789E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     29.769        45.598        .73383E-04   -1.4616    
  19  Prefactor     12.145        12.002        .57467E-03   -1.5011    
  20  Prefactor     8.4310        7.6430        .13807E-03   -1.5127    
  21  norm          9.3162        5.4274        .12808E-03   -1.5097    
  22  Prefactor     .10000E-03    7.7488        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .10000E-03    10.338        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  norm          5.1835        1.1277        .34542E-04   -1.5253    
  25  Prefactor     .10000E-03    41.399        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  Prefactor     .16952        73.391        .35724E-02   -1.5626    
  27  Normalizat    1.1368        .23286        .25942E-03   -.88580    
  28  Prefactor     .93597        .20847        .25229E-03   -.94895    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 4.49714e-09
Minuit parameter uncertainties:
  1  5.95481
  2  4.10776e-05
  3  9.91491
  4  10.1813
  5  4.42851e-05
  6  0.000332648
  7  4.2241e-05
  8  0.385141
  9  6.90831e-06
  10  3.14359e-05
  11  1.51091e-06
  12  4.11504e-05
  13  12.6769
  14  7.72212e-05
  15  23.3192
  16  0.000280376
  17  0.000932679
  18  45.6515
  19  12.0046
  20  7.64388
  21  5.4277
  22  3.24354e-05
  23  9.75388e-06
  24  1.12768
  25  0.000463636
  26  7.06104
  27  0.233073
  28  0.208651
Done.

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

Extracting fit parameters...

4FGL J2221.9-3504
   Spectrum: PowerLaw
253    Prefactor:  1.000e-04  1.511e-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:  9.360e-01  2.087e-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:  1.137e+00  2.331e-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: 7.02e-08 ph cm-2 s-1
Energy Flux Upper Limit: 5.52e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/271673/likelihoodResults_358819201_359078401_4FGL_J2221.9-3504_daily_bin461.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) = 5861.53254278
delta logL = -0.00141598476785

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 5861.53112678
delta logL = 1.61780917551e-08

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.6693       1.0000          .0000       10.000    
     3 'Normalizat'    1.1368       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .93598       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.
 MIGRAD TERMINATED WITHOUT CONVERGENCE.

 FCN=   5861.531     FROM MIGRAD    STATUS=FAILED        88 CALLS      240 TOTAL
                     EDM=   .20E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10072E-03    146.33        .13698E-02** at limit **
   2  Index         2.5977        5.0140        .50000        .14681E-04
   3  Normalizat    1.1368        .33631E-01    .25942E-03   -.54078E-04
   4  Prefactor     .93597        .30156E-01    .25229E-03   -.22847E-04
                               ERR DEF=  .500    
 START SIMPLEX MINIMIZATION.    CONVERGENCE WHEN EDM .LT.   .20E-04
 SIMPLEX MINIMIZATION HAS CONVERGED.

 FCN=   5861.531     FROM SIMPLEX   STATUS=UNCHANGED    139 CALLS      379 TOTAL
                     EDM=   .99E-05    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10072E-03    146.33        .28810E-03** at limit **
   2  Index         2.5977        5.0140        .49219E-04    .14681E-04
   3  Normalizat    1.1368        .33631E-01    .63236E-06   -.54078E-04
   4  Prefactor     .93597        .30156E-01    .50616E-06   -.22847E-04
                               ERR DEF=  .500    

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   5861.531     FROM MIGRAD    STATUS=CONVERGED     38 CALLS      417 TOTAL
                     EDM=   .97E-10    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    698.06        .27396E-03** at limit **
   2  Index         2.4081        6.0914        .50000        .22894E-06
   3  Normalizat    1.1368        .11329        .10377E-04    .23095E-03
   4  Prefactor     .93597        .10158        .10092E-04    .25550E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Index      = 2.40812
  Normalizat = 1.13676
  Prefactor  = 0.935966
 **********
 **   18 **HESSE 
 **********

 FCN=   5861.531     FROM HESSE     STATUS=OK            29 CALLS      446 TOTAL
                     EDM=   .14E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    3.8357        .54792E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.4081        6.1379        .50000       -.54495    
   3  Normalizat    1.1368        .22448        .20754E-05   -.88580    
   4  Prefactor     .93597        .20132        .20183E-05   -.94895    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.44265e-10
Minuit parameter uncertainties:
  1  4.83113e-05
  2  132.268
  3  0.224666
  4  0.201477
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/271673': 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) = 5861.53112616
delta logL = 6.38109668216e-07

Extracting fit parameters...

4FGL J2221.9-3504
   Spectrum: PowerLaw
253    Prefactor:  1.000e-04  4.831e-05  1.000e-04  1.000e+04 ( 1.000e-12)
254        Index:  2.408e+00  1.323e+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:  9.360e-01  2.015e-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:  1.137e+00  2.247e-01  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/271673/cmap_HighResolution_358819201_359078401_4FGL_J2221.9-3504_daily_bin461.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='5.52e-03', job_status='DONE', photon_flux_upper_limit='7.02e-08', time_completed='2021-09-28 10:06:22.820709', job_id='271673', GAL2='0.94', fit_tolerance='1e-08', EG2='1.14', EG='1.14', time_epoch_completed='1632848782.82', return_code2='0', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.94', dlogl='6.38e-07', ts2='-0.00', photon_index_error='0.00', photon_index='2.68' WHERE bin_id='461' AND source_name='4FGL J2221.9-3504' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Tue Sep 28 10:06:22 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0246>
Subject: Job 271673: <4FGL_J2221.9-3504_daily_bin461> in cluster <slac> Done

Job <4FGL_J2221.9-3504_daily_bin461> was submitted from host <rhel6-64d> by user <kocevski> in cluster <slac> at Tue Sep 28 09:50:28 2021
Job was executed on host(s) <bullet0246>, in queue <medium>, as user <kocevski> in cluster <slac> at Tue Sep 28 09:50:31 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:50:31 2021
Terminated at Tue Sep 28 10:06:23 2021
Results reported at Tue Sep 28 10:06:23 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J2221.9-3504_daily_bin461 335.497 -35.0712 358819201 359078401 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 :                                   754.24 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             279.03 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   952 sec.
    Turnaround time :                            955 sec.

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

