/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 174 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 = 7397
number of fields = 27
No RA_SUN column yet. Adding RA_SUN/DEC_SUN columns.
Done.


Performing analysis on: 4FGL_J2221.9-3504_daily_bin322
RA = 335.497, Dec = -35.0712
tmin = 322790401, tmax = 323049601
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='270459', job_status='RUN', time_executed='2021-09-28 09:48:56.582620', time_epoch_executed='1632847736.58' WHERE source_name='4FGL J2221.9-3504' and cadence='daily' and bin_id='322'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/270459

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/270459/ft1_4FGL_J2221.9-3504_daily_bin322.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/270459/ft2_4FGL_J2221.9-3504_daily_bin322.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/270459/ft1_4FGL_J2221.9-3504_daily_bin322.fits outfile=/scratch/kocevski/270459/ft1_filteredMKT_4FGL_J2221.9-3504_daily_bin322.fits ra=335.497 dec=-35.0712 rad=12.0 tmin=322790401.0 tmax=323049601.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 12.02
user 11.66
sys 0.32

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/270459/ft2_4FGL_J2221.9-3504_daily_bin322.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/270459/ft1_filteredMKT_4FGL_J2221.9-3504_daily_bin322.fits evtable="EVENTS" outfile="/scratch/kocevski/270459/ft1_filtered_4FGL_J2221.9-3504_daily_bin322.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.32
sys 0.16

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/270459/ft1_filtered_4FGL_J2221.9-3504_daily_bin322.fits" evtable="EVENTS" scfile=/scratch/kocevski/270459/ft2_4FGL_J2221.9-3504_daily_bin322.fits sctable="SC_DATA" outfile=/scratch/kocevski/270459/ltcube_322790401_323049601_4FGL_J2221.9-3504_daily_bin322.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/270459/ft2_4FGL_J2221.9-3504_daily_bin322.fits
.....................!
real 11.40
user 11.04
sys 0.33

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/270459/ft1_filtered_4FGL_J2221.9-3504_daily_bin322.fits evtable="EVENTS" scfile=/scratch/kocevski/270459/ft2_4FGL_J2221.9-3504_daily_bin322.fits sctable="SC_DATA" expcube=/scratch/kocevski/270459/ltcube_322790401_323049601_4FGL_J2221.9-3504_daily_bin322.fits outfile=/scratch/kocevski/270459/expmap_322790401_323049601_4FGL_J2221.9-3504_daily_bin322.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/270459/ltcube_322790401_323049601_4FGL_J2221.9-3504_daily_bin322.fits
.....................!
real 190.13
user 185.14
sys 4.61

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/270459/ft1_filtered_4FGL_J2221.9-3504_daily_bin322.fits scfile=/scratch/kocevski/270459/ft2_4FGL_J2221.9-3504_daily_bin322.fits outfile=/scratch/kocevski/270459/cmap_322790401_323049601_4FGL_J2221.9-3504_daily_bin322.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.55
user 0.35
sys 0.18

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

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/270459/ft1_filtered_4FGL_J2221.9-3504_daily_bin322.fits evtable="EVENTS" scfile=/scratch/kocevski/270459/ft2_4FGL_J2221.9-3504_daily_bin322.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/270459/Model_4FGL_J2221.9-3504_daily_bin322.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/270459/ft1_filtered_4FGL_J2221.9-3504_daily_bin322.fits.....................!
real 37.20
user 35.83
sys 1.24

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

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10045E-03   1.0000         .10000E-03   10000.    
     4 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    20.057       1.0000         .10000E-03   10000.    
     6 'Prefactor '    17.306       1.0000         .10000E-03   10000.    
     7 'norm      '    8.1270       1.0000         .10000E-03   10000.    
     8 'norm      '    1.5870       1.0000         .10000E-03   10000.    
     9 'Prefactor '    8.5472       1.0000         .10000E-03   10000.    
    10 'Prefactor '    18.386       1.0000         .10000E-03   10000.    
    11 'Prefactor '    12.171       1.0000         .10000E-03   10000.    
    12 'Prefactor '    13.116       1.0000         .10000E-03   10000.    
    13 'norm      '    .10020E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    65.408       1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10502E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    25.179       1.0000         .10000E-03   10000.    
    17 'norm      '    .25415E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    27.687       1.0000         .10000E-03   10000.    
    19 'Prefactor '    11.809       1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    21 'norm      '    .10177E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10200E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    15.015       1.0000         .10000E-03   10000.    
    24 'norm      '    .12001E-03   1.0000         .10000E-03   10000.    
    25 'Prefactor '    64.374       1.0000         .10000E-03   10000.    
    26 'Prefactor '    .14581E-03   1.0000         .10000E-03   10000.    
    27 'Normalizat'    .10000E-01   1.0000         .10000E-01   10.000    
    28 'Prefactor '    1.6820       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5630E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   3725.314     FROM MIGRAD    STATUS=CONVERGED    107 CALLS     3540 TOTAL
                     EDM=   .19E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  3.1%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .10000E-03    4.5640       -.25625E-07** at limit **
   2  Prefactor     .10000E-03    8.6465        .51123E-06** at limit **
   3  Prefactor     .10072E-03    22.090       -.96338E-06** at limit **
   4  norm          .10000E-03    3.3585       -.25494E-06** at limit **
   5  Prefactor     20.054        1.6448       -.16632E-06   -.20345E-02
   6  Prefactor     17.294        6.2405       -.92058E-06    .12004E-02
   7  norm          8.1278        1.1185        .10816E-06   -.12001E-03
   8  norm          1.5871        .49878        .18960E-07    .35704E-03
   9  Prefactor     8.5467        1.1155        .74028E-08   -.35188E-03
  10  Prefactor     18.381        2.3047       -.29794E-06   -.14350E-02
  11  Prefactor     12.137        11.662       -.19518E-05   -.10746E-01
  12  Prefactor     13.115        1.0181        .18048E-07   -.12640E-03
  13  norm          .10008E-03    12.291        .45889E-06** at limit **
  14  Prefactor     65.405        1.5498       -.91415E-07    .21541E-03
  15  Prefactor     .10004E-03    23.067       -.84497E-06** at limit **
  16  Prefactor     25.168        4.7446       -.57645E-06   -.13155E-02
  17  norm          .10000E-03    8.2522       -.43298E-05** at limit **
  18  Prefactor     27.777        42.062        .49764E-05   -.51679E-02
  19  Prefactor     11.808        1.2211        .12069E-07   -.15120E-02
  20  Prefactor     .10015E-03    9.5505       -.45877E-06** at limit **
  21  norm          .10000E-03    5.1755        .65107E-07** at limit **
  22  Prefactor     .10029E-03    10.217       -.92554E-07** at limit **
  23  Prefactor     15.011        2.8757       -.38927E-06   -.15052E-02
  24  norm          .10000E-03    1.0678        .86508E-07** at limit **
  25  Prefactor     64.370        1.9766       -.13240E-06    .64944E-03
  26  Prefactor     .10121E-03    19.754        .71838E-06** at limit **
  27  Normalizat    .10000E-01    .28022        .55186E-05** at limit **
  28  Prefactor     1.6820        .12556        .15790E-06    .29513E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 0.0001
  Prefactor  = 0.000100004
  Prefactor  = 0.00010072
  norm       = 0.0001
  Prefactor  = 20.0542
  Prefactor  = 17.2936
  norm       = 8.12784
  norm       = 1.58705
  Prefactor  = 8.54672
  Prefactor  = 18.3813
  Prefactor  = 12.1373
  Prefactor  = 13.1147
  norm       = 0.000100079
  Prefactor  = 65.4051
  Prefactor  = 0.000100044
  Prefactor  = 25.1683
  norm       = 0.000100003
  Prefactor  = 27.777
  Prefactor  = 11.8084
  Prefactor  = 0.000100146
  norm       = 0.0001
  Prefactor  = 0.000100295
  Prefactor  = 15.0108
  norm       = 0.0001
  Prefactor  = 64.3703
  Prefactor  = 0.000101213
  Normalizat = 0.01
  Prefactor  = 1.68202
 **********
 **   18 **HESSE 
 **********

 FCN=   3725.314     FROM HESSE     STATUS=OK           601 CALLS     4141 TOTAL
                     EDM=   .11E-05    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          .10000E-03    4.5542        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     .10000E-03    8.6075        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10072E-03    38.431        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  norm          .10000E-03    3.3507        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     20.054        30.799        .22358E-02   -1.4812    
   6  Prefactor     17.294        145.12        .24069E-02   -1.4876    
   7  norm          8.1278        7.9757        .35159E-02   -1.5138    
   8  norm          1.5871        .52485        .52475E-02   -1.5456    
   9  Prefactor     8.5467        9.4855        .34278E-02   -1.5123    
  10  Prefactor     18.381        21.922        .23352E-02   -1.4850    
  11  Prefactor     12.137        21.934        .28705E-02   -1.5011    
  12  Prefactor     13.115        10.232        .27651E-02   -1.4984    
  13  norm          .10008E-03    12.432        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     65.405        88.424        .12406E-02   -1.4089    
  15  Prefactor     .10004E-03    23.168        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     25.168        41.229        .19958E-02   -1.4704    
  17  norm          .10000E-03    2.5931        .46623E-01   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     27.777        61.638        .19034E-02   -1.4653    
  19  Prefactor     11.808        28.264        .29143E-02   -1.5021    
  20  Prefactor     .10015E-03    9.8015        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  norm          .10000E-03    5.0497        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     .10029E-03    10.736        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     15.011        13.495        .25841E-02   -1.4933    
  24  norm          .10000E-03    .69681        .16965E-01   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     64.370        100.12        .12504E-02   -1.4102    
  26  Prefactor     .10121E-03    37.115        .90712E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  Normalizat    .10000E-01    .20287        .22016       -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  Prefactor     1.6820        .17570        .44125E-01   -.72561    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.10924e-06
Minuit parameter uncertainties:
  1  1.43298e-07
  2  0.000374028
  3  0.010524
  4  1.39573e-05
  5  30.823
  6  100.526
  7  7.97679
  8  0.52485
  9  9.48717
  10  21.9312
  11  21.9488
  12  10.2336
  13  0.0019775
  14  88.6024
  15  0.00202659
  16  41.2756
  17  0.000165534
  18  61.78
  19  28.2961
  20  0.00238988
  21  3.78455e-06
  22  0.00355764
  23  13.4977
  24  2.40208e-06
  25  100.388
  26  0.0134262
  27  2.43557e-06
  28  0.175761
Done.

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

Extracting fit parameters...

4FGL J2221.9-3504
   Spectrum: PowerLaw
253    Prefactor:  1.214e+01  2.195e+01  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:  1.682e+00  1.758e-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.000e-02  2.436e-06  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.37
Ra Dec: 335.497 -35.071
Photon Flux Upper Limit: 2.86e-07 ph cm-2 s-1
Energy Flux Upper Limit: 2.25e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/270459/likelihoodResults_322790401_323049601_4FGL_J2221.9-3504_daily_bin322.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) = 3725.29327037
delta logL = 0.0207045026409

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 3725.28899497
delta logL = 0.0249798999607

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    10.185       1.0000         .10000E-03   10000.    
     2 'Index     '    2.9623       1.0000          .0000       10.000    
     3 'Normalizat'    .10001E-01   1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.6812       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=   3725.289     FROM MIGRAD    STATUS=CONVERGED     79 CALLS      237 TOTAL
                     EDM=   .18E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     10.185        22.923        .12555E-03    .17291E-03
   2  Index         2.9624        1.4183        .10978E-01    .41726E-04
   3  Normalizat    .10000E-01    .26703        .12890E-02** at limit **
   4  Prefactor     1.6814        .12743        .19500E-03   -.18627E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 10.1847
  Index      = 2.96241
  Normalizat = 0.01
  Prefactor  = 1.68138
 **********
 **   18 **HESSE 
 **********

 FCN=   3725.289     FROM HESSE     STATUS=OK            25 CALLS      262 TOTAL
                     EDM=   .17E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     10.185        21.259        .50220E-05   -1.5070    
   2  Index         2.9624        1.3185        .43913E-03   -.41973    
   3  Normalizat    .10000E-01    .26703        .25781E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     1.6814        .12727        .39000E-04   -.72579    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.67029e-10
Minuit parameter uncertainties:
  1  21.2746
  2  1.33755
  3  9.08771e-08
  4  0.127295
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/270459': 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) = 3725.2889923
delta logL = 0.0249825737023

Extracting fit parameters...

4FGL J2221.9-3504
   Spectrum: PowerLaw
253    Prefactor:  1.018e+01  2.127e+01  1.000e-04  1.000e+04 ( 1.000e-12)
254        Index:  2.962e+00  1.338e+00  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:  1.681e+00  1.273e-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.000e-02  9.088e-08  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 0.37
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/270459/cmap_HighResolution_322790401_323049601_4FGL_J2221.9-3504_daily_bin322.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='2.25e-02', job_status='DONE', photon_flux_upper_limit='2.86e-07', time_completed='2021-09-28 09:59:07.393269', job_id='270459', GAL2='1.68', fit_tolerance='1e-08', EG2='0.01', EG='0.01', time_epoch_completed='1632848347.39', return_code2='0', ts='0.37', comment='SUCCESS', return_code='0', GAL='1.68', dlogl='2.50e-02', ts2='0.41', photon_index_error='0.00', photon_index='2.68' WHERE bin_id='322' AND source_name='4FGL J2221.9-3504' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Tue Sep 28 09:59:07 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0117>
Subject: Job 270459: <4FGL_J2221.9-3504_daily_bin322> in cluster <slac> Done

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

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J2221.9-3504_daily_bin322 335.497 -35.0712 322790401 323049601 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 :                                   608.17 sec.
    Max Memory :                                 1094 MB
    Average Memory :                             248.46 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   794 sec.
    Turnaround time :                            798 sec.

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

