/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 3 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 = 7685
number of fields = 22
No RA_SUN column yet. Adding RA_SUN/DEC_SUN columns.
Done.


Performing analysis on: 4FGL_J2221.9-3504_daily_bin52
RA = 335.497, Dec = -35.0712
tmin = 252806401, tmax = 253065601
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='270069', job_status='RUN', time_executed='2021-09-28 09:45:32.808391', time_epoch_executed='1632847532.81' WHERE source_name='4FGL J2221.9-3504' and cadence='daily' and bin_id='52'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/270069

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/270069/ft1_4FGL_J2221.9-3504_daily_bin52.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/270069/ft2_4FGL_J2221.9-3504_daily_bin52.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/270069/ft1_4FGL_J2221.9-3504_daily_bin52.fits outfile=/scratch/kocevski/270069/ft1_filteredMKT_4FGL_J2221.9-3504_daily_bin52.fits ra=335.497 dec=-35.0712 rad=12.0 tmin=252806401.0 tmax=253065601.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 1.42
user 1.24
sys 0.17

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

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

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/270069/ft1_filtered_4FGL_J2221.9-3504_daily_bin52.fits" evtable="EVENTS" scfile=/scratch/kocevski/270069/ft2_4FGL_J2221.9-3504_daily_bin52.fits sctable="SC_DATA" outfile=/scratch/kocevski/270069/ltcube_252806401_253065601_4FGL_J2221.9-3504_daily_bin52.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/270069/ft2_4FGL_J2221.9-3504_daily_bin52.fits
.....................!
real 13.21
user 12.84
sys 0.34

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/270069/ft1_filtered_4FGL_J2221.9-3504_daily_bin52.fits evtable="EVENTS" scfile=/scratch/kocevski/270069/ft2_4FGL_J2221.9-3504_daily_bin52.fits sctable="SC_DATA" expcube=/scratch/kocevski/270069/ltcube_252806401_253065601_4FGL_J2221.9-3504_daily_bin52.fits outfile=/scratch/kocevski/270069/expmap_252806401_253065601_4FGL_J2221.9-3504_daily_bin52.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/270069/ltcube_252806401_253065601_4FGL_J2221.9-3504_daily_bin52.fits
.....................!
real 191.52
user 185.96
sys 5.19

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/270069/ft1_filtered_4FGL_J2221.9-3504_daily_bin52.fits scfile=/scratch/kocevski/270069/ft2_4FGL_J2221.9-3504_daily_bin52.fits outfile=/scratch/kocevski/270069/cmap_252806401_253065601_4FGL_J2221.9-3504_daily_bin52.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.36
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/270069/ft1_filtered_4FGL_J2221.9-3504_daily_bin52.fits scfile=/scratch/kocevski/270069/ft2_4FGL_J2221.9-3504_daily_bin52.fits outfile=/scratch/kocevski/270069/cmap_HighResolution_252806401_253065601_4FGL_J2221.9-3504_daily_bin52.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.37
sys 0.16

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/270069/ft1_filtered_4FGL_J2221.9-3504_daily_bin52.fits evtable="EVENTS" scfile=/scratch/kocevski/270069/ft2_4FGL_J2221.9-3504_daily_bin52.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/270069/Model_4FGL_J2221.9-3504_daily_bin52.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/270069/ft1_filtered_4FGL_J2221.9-3504_daily_bin52.fits.....................!
real 55.59
user 54.28
sys 1.16

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

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    7.5917       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .14353E-01   1.0000         .10000E-03   10000.    
     3 'Prefactor '    4.0771       1.0000         .10000E-03   10000.    
     4 'norm      '    26.957       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .19516E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    41.699       1.0000         .10000E-03   10000.    
     7 'norm      '    4.1094       1.0000         .10000E-03   10000.    
     8 'norm      '    1.8934       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    28.297       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10013E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    3.7210       1.0000         .10000E-03   10000.    
    13 'norm      '    .10004E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    14.093       1.0000         .10000E-03   10000.    
    16 'Prefactor '    25.970       1.0000         .10000E-03   10000.    
    17 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    4.5678       1.0000         .10000E-03   10000.    
    20 'Prefactor '    13.663       1.0000         .10000E-03   10000.    
    21 'norm      '    3.5067       1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10294E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    8.5602       1.0000         .10000E-03   10000.    
    24 'norm      '    .10008E-03   1.0000         .10000E-03   10000.    
    25 'Prefactor '    90.238       1.0000         .10000E-03   10000.    
    26 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
    27 'Normalizat'    1.1300       1.0000         .10000E-01   10.000    
    28 'Prefactor '    .83446       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=   7031.268     FROM MIGRAD    STATUS=CONVERGED    682 CALLS     3466 TOTAL
                     EDM=   .58E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .7%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          7.5921        4.8701       -.55831E-06   -.15427E-04
   2  Prefactor     .10001E-03    5.8152       -.15981E-06** at limit **
   3  Prefactor     4.0618        9.1567       -.94649E-06   -.14547E-03
   4  norm          26.950        10.379       -.44796E-06   -.10623E-04
   5  Prefactor     .10000E-03    14.680        .10009E-04** at limit **
   6  Prefactor     41.689        50.699       -.11479E-04   -.13804E-03
   7  norm          4.1077        4.6537        .24128E-05   -.50100E-03
   8  norm          1.8935        .44201       -.48182E-07    .22862E-04
   9  Prefactor     .10000E-03    3.3120        .28565E-07** at limit **
  10  Prefactor     28.297        19.783       -.54311E-06   -.79036E-05
  11  Prefactor     .10000E-03    3.1563       -.13916E-08** at limit **
  12  Prefactor     3.7209        3.0773       -.10416E-06   -.23598E-03
  13  norm          .10000E-03    8.2753        .85675E-06** at limit **
  14  Prefactor     .10000E-03    23.711        .49644E-05** at limit **
  15  Prefactor     14.094        14.173       -.35216E-07    .59664E-05
  16  Prefactor     25.969        21.415       -.48129E-06   -.34813E-05
  17  norm          .10000E-03    .75029        .14624E-07** at limit **
  18  Prefactor     .10000E-03    17.333       -.12626E-04** at limit **
  19  Prefactor     4.5657        9.3809       -.77709E-06   -.13601E-03
  20  Prefactor     13.664        7.8071       -.24540E-06   -.25498E-04
  21  norm          3.5071        2.9347       -.41927E-06   -.17325E-02
  22  Prefactor     .10000E-03    9.4778       -.16653E-05** at limit **
  23  Prefactor     8.5600        6.9005       -.14454E-06    .46691E-04
  24  norm          .10000E-03    .15144        .15587E-07** at limit **
  25  Prefactor     90.231        59.050       -.60003E-05    .50484E-05
  26  Prefactor     .10000E-03    4.3099       -.42636E-07** at limit **
  27  Normalizat    1.1303        .18796        .10813E-05   -.37855E-04
  28  Prefactor     .83412        .15995        .51085E-06    .34719E-05
                               ERR DEF=  .500    
Final values: 
  norm       = 7.59208
  Prefactor  = 0.000100008
  Prefactor  = 4.06178
  norm       = 26.9502
  Prefactor  = 0.000100001
  Prefactor  = 41.6888
  norm       = 4.10767
  norm       = 1.89347
  Prefactor  = 0.0001
  Prefactor  = 28.2972
  Prefactor  = 0.0001
  Prefactor  = 3.72085
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 14.0935
  Prefactor  = 25.9689
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 4.56567
  Prefactor  = 13.6636
  norm       = 3.50705
  Prefactor  = 0.0001
  Prefactor  = 8.56005
  norm       = 0.0001
  Prefactor  = 90.2314
  Prefactor  = 0.0001
  Normalizat = 1.13032
  Prefactor  = 0.834125
 **********
 **   18 **HESSE 
 **********

 FCN=   7031.268     FROM HESSE     STATUS=OK           523 CALLS     3989 TOTAL
                     EDM=   .12E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          7.5921        4.8704        .14288E-03   -1.5157    
   2  Prefactor     .10001E-03    96.584        .36429E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     4.0618        8.8200        .19967E-03   -1.5305    
   4  norm          26.950        10.322        .77160E-04   -1.4669    
   5  Prefactor     .10000E-03    14.947        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     41.689        50.979        .62078E-04   -1.4416    
   7  norm          4.1077        4.5793        .16848E-03   -1.5303    
   8  norm          1.8935        .44313        .25167E-04   -1.5433    
   9  Prefactor     .10000E-03    3.3148        .14903E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     28.297        19.807        .75314E-04   -1.4644    
  11  Prefactor     .10000E-03    3.1737        .14545E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     3.7209        3.0763        .12928E-03   -1.5322    
  13  norm          .10000E-03    8.2843        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     .10000E-03    23.734        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     14.094        14.171        .10669E-03   -1.4957    
  16  Prefactor     25.969        21.429        .78608E-04   -1.4688    
  17  norm          .10000E-03    .75890        .70908E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .10000E-03    17.156        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     4.5657        9.4269        .18835E-03   -1.5281    
  20  Prefactor     13.664        7.8084        .10836E-03   -1.4969    
  21  norm          3.5071        2.9694        .62868E-03   -1.5333    
  22  Prefactor     .10000E-03    9.5043        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     8.5600        6.8201        .13701E-03   -1.5123    
  24  norm          .10000E-03    .15396        .62936E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     90.231        59.039        .42300E-04   -1.3805    
  26  Prefactor     .10000E-03    4.3152        .16992E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  Normalizat    1.1303        .22385        .25918E-03   -.88784    
  28  Prefactor     .83412        .18940        .26135E-03   -.98482    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.21691e-09
Minuit parameter uncertainties:
  1  4.87068
  2  0.00180405
  3  8.8228
  4  10.3232
  5  0.000217817
  6  51.0327
  7  4.57969
  8  0.443131
  9  3.57847e-06
  10  19.8117
  11  3.65328e-06
  12  3.07647
  13  2.02413e-06
  14  1.15045e-05
  15  14.1748
  16  21.4357
  17  7.69191e-08
  18  2.41366e-06
  19  9.43
  20  7.80894
  21  2.96952
  22  2.94973e-05
  23  6.82071
  24  6.36662e-07
  25  59.0777
  26  2.05105e-06
  27  0.224039
  28  0.189549
Done.

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

Extracting fit parameters...

4FGL J2221.9-3504
   Spectrum: PowerLaw
253    Prefactor:  1.000e-04  3.653e-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.341e-01  1.895e-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.130e+00  2.240e-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: 6.28e-08 ph cm-2 s-1
Energy Flux Upper Limit: 4.93e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/270069/likelihoodResults_252806401_253065601_4FGL_J2221.9-3504_daily_bin52.txt

Performing a free index iterative likelihood fit...

Freezing all point sources, except source of interest...

Done.

Freeing candidate source...
Done.

Fit tolerance = 1

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 7031.26951275
delta logL = -0.00149832677198

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 7031.26801445
delta logL = -1.88883859664e-08

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.6723       1.0000          .0000       10.000    
     3 'Normalizat'    1.1303       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .83414       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=   7031.268     FROM MIGRAD    STATUS=FAILED        95 CALLS      246 TOTAL
                     EDM=   .55E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    689.84        .14557E-02** at limit **
   2  Index         2.4514        6.2171        .50000       -.29950E-06
   3  Normalizat    1.1303        .11847        .25918E-03    .19155E-03
   4  Prefactor     .83412        .10484        .26135E-03    .21306E-03
                               ERR DEF=  .500    
 START SIMPLEX MINIMIZATION.    CONVERGENCE WHEN EDM .LT.   .20E-04
 SIMPLEX MINIMIZATION HAS CONVERGED.

 FCN=   7031.268     FROM SIMPLEX   STATUS=UNCHANGED    194 CALLS      440 TOTAL
                     EDM=   .99E-05    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    689.84        .29224E-03** at limit **
   2  Index         2.4514        6.2171        .23872E-06   -.29950E-06
   3  Normalizat    1.1303        .11847        .15108E-07    .19155E-03
   4  Prefactor     .83412        .10484        .32404E-08    .21306E-03
                               ERR DEF=  .500    

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   7031.268     FROM MIGRAD    STATUS=CONVERGED     34 CALLS      474 TOTAL
                     EDM=   .10E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    3.4501        .29115E-03** at limit **
   2  Index         2.4529        8.6314        .50000       -.20220E-06
   3  Normalizat    1.1303        .20832        .51835E-04    .19077E-03
   4  Prefactor     .83412        .18433        .10454E-04    .21271E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Index      = 2.45287
  Normalizat = 1.13032
  Prefactor  = 0.834125
 **********
 **   18 **HESSE 
 **********

 FCN=   7031.268     FROM HESSE     STATUS=OK            29 CALLS      503 TOTAL
                     EDM=   .11E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    3.2510        .58230E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.4529        6.7688        .50000       -.53452    
   3  Normalizat    1.1303        .20831        .10367E-04   -.88784    
   4  Prefactor     .83412        .18432        .20908E-05   -.98482    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.13237e-10
Minuit parameter uncertainties:
  1  3.0532e-05
  2  147.244
  3  0.208457
  4  0.184457
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/270069': 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) = 7031.26801409
delta logL = 3.35946424457e-07

Extracting fit parameters...

4FGL J2221.9-3504
   Spectrum: PowerLaw
253    Prefactor:  1.000e-04  3.053e-05  1.000e-04  1.000e+04 ( 1.000e-12)
254        Index:  2.453e+00  1.472e+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.341e-01  1.845e-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.130e+00  2.085e-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 -1.000e-01 [aplpy.core]
INFO: Auto-setting vmax to  1.110e+00 [aplpy.core]
Saving /scratch/kocevski/270069/cmap_HighResolution_252806401_253065601_4FGL_J2221.9-3504_daily_bin52.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='4.93e-03', job_status='DONE', photon_flux_upper_limit='6.28e-08', time_completed='2021-09-28 09:59:06.939133', job_id='270069', GAL2='0.83', fit_tolerance='1e-08', EG2='1.13', EG='1.13', time_epoch_completed='1632848346.94', return_code2='0', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.83', dlogl='3.36e-07', ts2='-0.00', photon_index_error='0.00', photon_index='2.68' WHERE bin_id='52' AND source_name='4FGL J2221.9-3504' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Tue Sep 28 09:59:06 PDT 2021


------------------------------------------------------------
Sender: LSF System <scs@bullet0143>
Subject: Job 270069: <4FGL_J2221.9-3504_daily_bin52> in cluster <slac> Done

Job <4FGL_J2221.9-3504_daily_bin52> was submitted from host <rhel6-64f> by user <kocevski> in cluster <slac> at Tue Sep 28 09:45:19 2021
Job was executed on host(s) <bullet0143>, in queue <medium>, as user <kocevski> in cluster <slac> at Tue Sep 28 09:45:20 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:45:20 2021
Terminated at Tue Sep 28 09:59:07 2021
Results reported at Tue Sep 28 09:59:07 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J2221.9-3504_daily_bin52 335.497 -35.0712 252806401 253065601 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 :                                   814.24 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             302.11 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   827 sec.
    Turnaround time :                            828 sec.

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

