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


Performing analysis on: 4FGL_J2221.9-3504_daily_bin582
RA = 335.497, Dec = -35.0712
tmin = 390182401, tmax = 390441601
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='271872', job_status='RUN', time_executed='2021-09-28 09:54:03.249226', time_epoch_executed='1632848043.25' WHERE source_name='4FGL J2221.9-3504' and cadence='daily' and bin_id='582'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/271872

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/271872/ft1_4FGL_J2221.9-3504_daily_bin582.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/271872/ft2_4FGL_J2221.9-3504_daily_bin582.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/271872/ft1_4FGL_J2221.9-3504_daily_bin582.fits outfile=/scratch/kocevski/271872/ft1_filteredMKT_4FGL_J2221.9-3504_daily_bin582.fits ra=335.497 dec=-35.0712 rad=12.0 tmin=390182401.0 tmax=390441601.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 4.11
user 3.88
sys 0.22

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

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

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/271872/ft1_filtered_4FGL_J2221.9-3504_daily_bin582.fits" evtable="EVENTS" scfile=/scratch/kocevski/271872/ft2_4FGL_J2221.9-3504_daily_bin582.fits sctable="SC_DATA" outfile=/scratch/kocevski/271872/ltcube_390182401_390441601_4FGL_J2221.9-3504_daily_bin582.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/271872/ft2_4FGL_J2221.9-3504_daily_bin582.fits
.....................!
real 15.21
user 14.82
sys 0.35

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/271872/ft1_filtered_4FGL_J2221.9-3504_daily_bin582.fits evtable="EVENTS" scfile=/scratch/kocevski/271872/ft2_4FGL_J2221.9-3504_daily_bin582.fits sctable="SC_DATA" expcube=/scratch/kocevski/271872/ltcube_390182401_390441601_4FGL_J2221.9-3504_daily_bin582.fits outfile=/scratch/kocevski/271872/expmap_390182401_390441601_4FGL_J2221.9-3504_daily_bin582.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/271872/ltcube_390182401_390441601_4FGL_J2221.9-3504_daily_bin582.fits
.....................!
real 191.71
user 185.78
sys 5.56

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/271872/ft1_filtered_4FGL_J2221.9-3504_daily_bin582.fits scfile=/scratch/kocevski/271872/ft2_4FGL_J2221.9-3504_daily_bin582.fits outfile=/scratch/kocevski/271872/cmap_390182401_390441601_4FGL_J2221.9-3504_daily_bin582.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.57
user 0.40
sys 0.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/271872/ft1_filtered_4FGL_J2221.9-3504_daily_bin582.fits scfile=/scratch/kocevski/271872/ft2_4FGL_J2221.9-3504_daily_bin582.fits outfile=/scratch/kocevski/271872/cmap_HighResolution_390182401_390441601_4FGL_J2221.9-3504_daily_bin582.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.60
user 0.42
sys 0.17

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/271872/ft1_filtered_4FGL_J2221.9-3504_daily_bin582.fits evtable="EVENTS" scfile=/scratch/kocevski/271872/ft2_4FGL_J2221.9-3504_daily_bin582.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/271872/Model_4FGL_J2221.9-3504_daily_bin582.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/271872/ft1_filtered_4FGL_J2221.9-3504_daily_bin582.fits.....................!
real 33.87
user 32.49
sys 1.30

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

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    6.2901       1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     4 'norm      '    2.6677       1.0000         .10000E-03   10000.    
     5 'Prefactor '    9.7455       1.0000         .10000E-03   10000.    
     6 'Prefactor '    .18194E-03   1.0000         .10000E-03   10000.    
     7 'norm      '    9.7538       1.0000         .10000E-03   10000.    
     8 'norm      '    1.7360       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10079E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10268E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    8.4114       1.0000         .10000E-03   10000.    
    12 'Prefactor '    4.5023       1.0000         .10000E-03   10000.    
    13 'norm      '    8.1586       1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10075E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10057E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    .10360E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    .10157E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    26.500       1.0000         .10000E-03   10000.    
    19 'Prefactor '    13.246       1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
    21 'norm      '    4.3641       1.0000         .10000E-03   10000.    
    22 'Prefactor '    18.460       1.0000         .10000E-03   10000.    
    23 'Prefactor '    18.432       1.0000         .10000E-03   10000.    
    24 'norm      '    .10192E-03   1.0000         .10000E-03   10000.    
    25 'Prefactor '    28.389       1.0000         .10000E-03   10000.    
    26 'Prefactor '    .10314E-03   1.0000         .10000E-03   10000.    
    27 'Normalizat'    1.1328       1.0000         .10000E-01   10.000    
    28 'Prefactor '    1.0157       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=   3253.264     FROM MIGRAD    STATUS=CONVERGED    677 CALLS     3513 TOTAL
                     EDM=   .39E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.4%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .10000E-03    4.5731        .11063E-06** at limit **
   2  Prefactor     6.2937        16.634        .72742E-07   -.95600E-05
   3  Prefactor     .10000E-03    8.4895        .21507E-07** at limit **
   4  norm          2.6608        13.491        .82576E-06   -.20002E-04
   5  Prefactor     9.7317        26.473       -.47233E-07   -.13477E-04
   6  Prefactor     .10000E-03    107.60        .32649E-07** at limit **
   7  norm          9.7573        8.4434        .64089E-07    .16848E-04
   8  norm          1.7359        .62033       -.46714E-08    .26229E-04
   9  Prefactor     .10000E-03    14.417        .22276E-06** at limit **
  10  Prefactor     .10000E-03    27.467       -.32672E-05** at limit **
  11  Prefactor     8.4193        13.680        .35658E-06    .20440E-04
  12  Prefactor     4.5031        7.7855        .53414E-05   -.39448E-03
  13  norm          8.0920        43.176       -.88743E-05   -.12791E-03
  14  Prefactor     .10000E-03    66.448       -.31974E-06** at limit **
  15  Prefactor     .10000E-03    25.816        .30911E-05** at limit **
  16  Prefactor     .10000E-03    70.233        .21560E-05** at limit **
  17  norm          .10000E-03    2.9445       -.13869E-06** at limit **
  18  Prefactor     26.506        62.831        .17715E-05    .21691E-04
  19  Prefactor     13.253        18.608        .12438E-06   -.93909E-05
  20  Prefactor     .10000E-03    4.6262       -.27453E-07** at limit **
  21  norm          4.3641        5.6005        .76967E-07   -.14219E-04
  22  Prefactor     18.454        23.378       -.15972E-09   -.11199E-05
  23  Prefactor     18.436        15.806        .66090E-07    .11469E-04
  24  norm          .10000E-03    .36836        .22262E-07** at limit **
  25  Prefactor     28.346        75.176       -.67273E-05   -.83506E-04
  26  Prefactor     .10000E-03    8.8791        .15837E-06** at limit **
  27  Normalizat    1.1316        .31100        .85264E-06   -.28514E-04
  28  Prefactor     1.0167        .25367       -.15838E-05    .37801E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 0.0001
  Prefactor  = 6.29373
  Prefactor  = 0.0001
  norm       = 2.66085
  Prefactor  = 9.73166
  Prefactor  = 0.0001
  norm       = 9.75734
  norm       = 1.73591
  Prefactor  = 0.0001
  Prefactor  = 0.000100001
  Prefactor  = 8.41932
  Prefactor  = 4.50308
  norm       = 8.09198
  Prefactor  = 0.0001
  Prefactor  = 0.000100001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 26.506
  Prefactor  = 13.2531
  Prefactor  = 0.0001
  norm       = 4.36411
  Prefactor  = 18.4536
  Prefactor  = 18.4362
  norm       = 0.0001
  Prefactor  = 28.3463
  Prefactor  = 0.0001
  Normalizat = 1.13157
  Prefactor  = 1.01672
 **********
 **   18 **HESSE 
 **********

 FCN=   3253.264     FROM HESSE     STATUS=OK           521 CALLS     4034 TOTAL
                     EDM=   .88E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          .10000E-03    4.5920        .11912E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     6.2937        16.642        .16005E-03   -1.5206    
   3  Prefactor     .10000E-03    8.4965        .16228E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  norm          2.6608        13.462        .24953E-03   -1.5382    
   5  Prefactor     9.7317        26.437        .12836E-03   -1.5084    
   6  Prefactor     .10000E-03    107.66        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  norm          9.7573        8.4471        .12831E-03   -1.5083    
   8  norm          1.7359        .62148        .25298E-04   -1.5444    
   9  Prefactor     .10000E-03    14.533        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .10000E-03    27.956        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     8.4193        13.733        .13822E-03   -1.5128    
  12  Prefactor     4.5031        8.0136        .94873E-03   -1.5284    
  13  norm          8.0920        46.236        .14036E-03   -1.5139    
  14  Prefactor     .10000E-03    66.508        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .10000E-03    26.092        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     .10000E-03    70.704        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          .10000E-03    2.9933        .18838E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     26.506        62.235        .77820E-04   -1.4678    
  19  Prefactor     13.253        18.669        .11006E-03   -1.4980    
  20  Prefactor     .10000E-03    4.6283        .11982E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  norm          4.3641        5.5865        .13739E-03   -1.5290    
  22  Prefactor     18.454        23.455        .93220E-04   -1.4849    
  23  Prefactor     18.436        15.785        .93289E-04   -1.4849    
  24  norm          .10000E-03    .37225        .66776E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     28.346        76.503        .75192E-04   -1.4643    
  26  Prefactor     .10000E-03    8.8861        .16593E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  Normalizat    1.1316        .37440        .28872E-03   -.88745    
  28  Prefactor     1.0167        .30240        .25742E-03   -.92174    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 8.81107e-10
Minuit parameter uncertainties:
  1  2.40387e-07
  2  16.6543
  3  4.62873e-06
  4  11.9739
  5  26.4684
  6  0.000137929
  7  8.4481
  8  0.621478
  9  4.13993e-06
  10  0.000403043
  11  13.7382
  12  8.01553
  13  38.7307
  14  0.000171863
  15  0.000379758
  16  0.000302361
  17  1.24471e-05
  18  62.3882
  19  18.6776
  20  5.32865e-06
  21  5.58718
  22  23.4667
  23  15.7886
  24  2.19946e-07
  25  76.77
  26  7.82037e-06
  27  0.375285
  28  0.302909
Done.

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

Extracting fit parameters...

4FGL J2221.9-3504
   Spectrum: PowerLaw
253    Prefactor:  8.419e+00  1.374e+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.017e+00  3.029e-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.132e+00  3.753e-01  1.000e-02  1.000e+01 ( 1.000e+00)


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

Saving results to:
/scratch/kocevski/271872/likelihoodResults_390182401_390441601_4FGL_J2221.9-3504_daily_bin582.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) = 3253.18998587
delta logL = 0.0742889434337

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 3253.18791527
delta logL = 0.0763595407684

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    8.4199       1.0000         .10000E-03   10000.    
     2 'Index     '    2.0706       1.0000          .0000       10.000    
     3 'Normalizat'    1.1571       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.0010       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.

 FCN=   3253.188     FROM MIGRAD    STATUS=CONVERGED     58 CALLS      209 TOTAL
                     EDM=   .15E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     8.4556        14.890        .34538E-02    .67064E-03
   2  Index         2.0701        .96788        .25398       -.30312E-04
   3  Normalizat    1.1571        .28924        .64625E-01   -.48438E-06
   4  Prefactor     1.0009        .24613        .45380E-01    .60460E-06
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 8.45557
  Index      = 2.07008
  Normalizat = 1.15706
  Prefactor  = 1.0009
 **********
 **   18 **HESSE 
 **********

 FCN=   3253.188     FROM HESSE     STATUS=OK            33 CALLS      242 TOTAL
                     EDM=   .45E-11    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     8.4556        15.069        .69077E-03   -1.5126    
   2  Index         2.0701        1.3440        .11953E-01   -.62609    
   3  Normalizat    1.1571        .34655        .28587E-03   -.87940    
   4  Prefactor     1.0009        .29276        .25911E-03   -.92700    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 4.46205e-12
Minuit parameter uncertainties:
  1  15.0758
  2  1.36992
  3  0.34724
  4  0.293229
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/271872': 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) = 3253.18791072
delta logL = 0.0763640894888

Extracting fit parameters...

4FGL J2221.9-3504
   Spectrum: PowerLaw
253    Prefactor:  8.456e+00  1.508e+01  1.000e-04  1.000e+04 ( 1.000e-12)
254        Index:  2.070e+00  1.370e+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.001e+00  2.932e-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.157e+00  3.472e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 0.50
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/271872/cmap_HighResolution_390182401_390441601_4FGL_J2221.9-3504_daily_bin582.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='1.61e-02', job_status='DONE', photon_flux_upper_limit='2.04e-07', time_completed='2021-09-28 10:03:22.587256', job_id='271872', GAL2='1.00', fit_tolerance='1e-08', EG2='1.16', EG='1.13', time_epoch_completed='1632848602.59', return_code2='0', ts='0.50', comment='SUCCESS', return_code='0', GAL='1.02', dlogl='7.64e-02', ts2='0.65', photon_index_error='0.00', photon_index='2.68' WHERE bin_id='582' AND source_name='4FGL J2221.9-3504' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Tue Sep 28 10:03:22 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0270>
Subject: Job 271872: <4FGL_J2221.9-3504_daily_bin582> in cluster <slac> Done

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

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J2221.9-3504_daily_bin582 335.497 -35.0712 390182401 390441601 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 :                                   559.36 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             279.93 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   753 sec.
    Turnaround time :                            756 sec.

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

