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


Performing analysis on: 4FGL_J1321.1+2216_daily_bin1301
RA = 200.296, Dec = 22.2808
tmin = 576547201, tmax = 576806401
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='500063', job_status='RUN', time_executed='2021-09-07 13:29:46.045891', time_epoch_executed='1631046586.05' WHERE source_name='4FGL J1321.1+2216' and cadence='daily' and bin_id='1301'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/500063

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/500063/ft1_4FGL_J1321.1+2216_daily_bin1301.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/500063/ft2_4FGL_J1321.1+2216_daily_bin1301.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/500063/ft1_4FGL_J1321.1+2216_daily_bin1301.fits outfile=/scratch/kocevski/500063/ft1_filteredMKT_4FGL_J1321.1+2216_daily_bin1301.fits ra=200.296 dec=22.2808 rad=12.0 tmin=576547201.0 tmax=576806401.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.06
user 4.78
sys 0.24

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/500063/ft2_4FGL_J1321.1+2216_daily_bin1301.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/500063/ft2_4FGL_J1321.1+2216_daily_bin1301.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/500063/ft1_filteredMKT_4FGL_J1321.1+2216_daily_bin1301.fits evtable="EVENTS" outfile="/scratch/kocevski/500063/ft1_filtered_4FGL_J1321.1+2216_daily_bin1301.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.54
user 0.35
sys 0.16

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/500063/ft1_filtered_4FGL_J1321.1+2216_daily_bin1301.fits" evtable="EVENTS" scfile=/scratch/kocevski/500063/ft2_4FGL_J1321.1+2216_daily_bin1301.fits sctable="SC_DATA" outfile=/scratch/kocevski/500063/ltcube_576547201_576806401_4FGL_J1321.1+2216_daily_bin1301.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/500063/ft2_4FGL_J1321.1+2216_daily_bin1301.fits
.....................!
real 17.81
user 17.34
sys 0.34

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/500063/ft1_filtered_4FGL_J1321.1+2216_daily_bin1301.fits evtable="EVENTS" scfile=/scratch/kocevski/500063/ft2_4FGL_J1321.1+2216_daily_bin1301.fits sctable="SC_DATA" expcube=/scratch/kocevski/500063/ltcube_576547201_576806401_4FGL_J1321.1+2216_daily_bin1301.fits outfile=/scratch/kocevski/500063/expmap_576547201_576806401_4FGL_J1321.1+2216_daily_bin1301.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/500063/ltcube_576547201_576806401_4FGL_J1321.1+2216_daily_bin1301.fits
.....................!
real 193.24
user 187.73
sys 4.87

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 J1321.1+2216 @ 200.296 22.2808

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/500063/ft1_filtered_4FGL_J1321.1+2216_daily_bin1301.fits scfile=/scratch/kocevski/500063/ft2_4FGL_J1321.1+2216_daily_bin1301.fits outfile=/scratch/kocevski/500063/cmap_576547201_576806401_4FGL_J1321.1+2216_daily_bin1301.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=200.296 yref=22.2808 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.16

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/500063/ft1_filtered_4FGL_J1321.1+2216_daily_bin1301.fits scfile=/scratch/kocevski/500063/ft2_4FGL_J1321.1+2216_daily_bin1301.fits outfile=/scratch/kocevski/500063/cmap_HighResolution_576547201_576806401_4FGL_J1321.1+2216_daily_bin1301.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=200.296 yref=22.2808 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.58
user 0.42
sys 0.14

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/500063/ft1_filtered_4FGL_J1321.1+2216_daily_bin1301.fits evtable="EVENTS" scfile=/scratch/kocevski/500063/ft2_4FGL_J1321.1+2216_daily_bin1301.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/500063/Model_4FGL_J1321.1+2216_daily_bin1301.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/500063/ft1_filtered_4FGL_J1321.1+2216_daily_bin1301.fits.....................!
real 45.48
user 44.06
sys 1.25

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/500063/ft1_filtered_4FGL_J1321.1+2216_daily_bin1301.fits', '/scratch/kocevski/500063/ft2_4FGL_J1321.1+2216_daily_bin1301.fits', expMap='/scratch/kocevski/500063/expmap_576547201_576806401_4FGL_J1321.1+2216_daily_bin1301.fits', expCube='/scratch/kocevski/500063/ltcube_576547201_576806401_4FGL_J1321.1+2216_daily_bin1301.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/500063/Model_4FGL_J1321.1+2216_daily_bin1301.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1321.1+2216'

4FGL J1321.1+2216
   Spectrum: LogParabola
324         norm:  7.564e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-12)
325        alpha:  2.281e+00  0.000e+00  0.000e+00  5.000e+00 ( 1.000e+00) fixed
326         beta:  7.755e-02  0.000e+00  0.000e+00  1.000e+01 ( 1.000e+00) fixed
327           Eb:  6.546e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/500063/ft1_filtered_4FGL_J1321.1+2216_daily_bin1301.fits
Spacecraft file(s): /scratch/kocevski/500063/ft2_4FGL_J1321.1+2216_daily_bin1301.fits
Exposure map: /scratch/kocevski/500063/expmap_576547201_576806401_4FGL_J1321.1+2216_daily_bin1301.fits
Exposure cube: /scratch/kocevski/500063/ltcube_576547201_576806401_4FGL_J1321.1+2216_daily_bin1301.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/500063/Model_4FGL_J1321.1+2216_daily_bin1301.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) = 5101.49443194

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     3 'norm      '    1.4315       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     5 'norm      '    .13407E-03   1.0000         .10000E-03   10000.    
     6 'norm      '    6.1716       1.0000         .10000E-03   10000.    
     7 'norm      '    .10073E-03   1.0000         .10000E-03   10000.    
     8 'norm      '    15.892       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    10 'norm      '    36.471       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    12 'norm      '    .10005E-03   1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10036E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    .10025E-03   1.0000         .10000E-03   10000.    
    17 'Prefactor '    4.0991       1.0000         .10000E-03   10000.    
    18 'Prefactor '    7.9361       1.0000         .10000E-03   10000.    
    19 'Normalizat'    .99529       1.0000         .10000E-01   10.000    
    20 'Prefactor '    1.0078       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5610E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   5101.411     FROM MIGRAD    STATUS=CONVERGED    412 CALLS     1725 TOTAL
                     EDM=   .19E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  2.5%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    31.535       -.30953E-05** at limit **
   2  Prefactor     .10000E-03    7.9192       -.22758E-05** at limit **
   3  norm          1.4319        4.3369       -.17444E-05   -.50584E-03
   4  Prefactor     .10000E-03    5.9246        .17459E-05** at limit **
   5  norm          .10000E-03    3.5334        .61517E-06** at limit **
   6  norm          6.1715        3.9140        .25940E-06   -.18004E-03
   7  norm          .10000E-03    4.3144        .14676E-06** at limit **
   8  norm          15.890        15.242        .22675E-06    .16799E-03
   9  Prefactor     .10000E-03    5.6145       -.15399E-05** at limit **
  10  norm          36.470        11.145       -.57706E-07   -.61477E-04
  11  Prefactor     .10000E-03    17.942       -.82851E-07** at limit **
  12  norm          .10000E-03    4.0518       -.23050E-06** at limit **
  13  Prefactor     .10000E-03    8.1729        .41252E-06** at limit **
  14  Prefactor     .10001E-03    41.977        .88946E-05** at limit **
  15  Prefactor     .10001E-03    49.480       -.65669E-05** at limit **
  16  Prefactor     .10000E-03    4.2349        .84581E-07** at limit **
  17  Prefactor     4.0986        11.225       -.19836E-06   -.67477E-04
  18  Prefactor     7.9356        10.011       -.20668E-05   -.11688E-02
  19  Normalizat    .99521        .19300        .13978E-06   -.73237E-04
  20  Prefactor     1.0079        .18440        .29618E-06   -.61458E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000100001
  Prefactor  = 0.000100001
  norm       = 1.43188
  Prefactor  = 0.0001
  norm       = 0.000100004
  norm       = 6.17147
  norm       = 0.0001
  norm       = 15.8904
  Prefactor  = 0.0001
  norm       = 36.4698
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.000100013
  Prefactor  = 0.000100006
  Prefactor  = 0.0001
  Prefactor  = 4.09863
  Prefactor  = 7.93562
  Normalizat = 0.995212
  Prefactor  = 1.00788
 **********
 **   18 **HESSE 
 **********

 FCN=   5101.411     FROM HESSE     STATUS=OK           289 CALLS     2014 TOTAL
                     EDM=   .41E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    31.190        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     .10000E-03    7.8467        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm          1.4319        4.5225        .25951E-03   -1.5469    
   4  Prefactor     .10000E-03    5.8239        .16819E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  norm          .10000E-03    8.2427        .25704E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  norm          6.1715        3.8957        .10685E-03   -1.5211    
   7  norm          .10000E-03    4.3290        .14442E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          15.890        15.266        .50234E-03   -1.4910    
   9  Prefactor     .10000E-03    5.5468        .16408E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  norm          36.470        11.165        .66362E-04   -1.4499    
  11  Prefactor     .10000E-03    17.956        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  norm          .10000E-03    4.0598        .14031E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     .10000E-03    8.1838        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     .10001E-03    39.379        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     .10001E-03    48.052        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     .10000E-03    4.3425        .28682E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  Prefactor     4.0986        11.220        .19912E-03   -1.5303    
  18  Prefactor     7.9356        11.874        .71165E-03   -1.5144    
  19  Normalizat    .99521        .22211        .25484E-03   -.93191    
  20  Prefactor     1.0079        .21331        .24522E-03   -.92467    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 4.1089e-09
Minuit parameter uncertainties:
  1  0.000429774
  2  0.000152651
  3  4.52362
  4  0.000104244
  5  0.000382456
  6  3.89587
  7  1.54679e-05
  8  15.2702
  9  8.61162e-05
  10  11.1657
  11  5.72856e-06
  12  1.08416e-05
  13  3.46166e-05
  14  0.00143765
  15  0.00110127
  16  1.01058e-05
  17  11.226
  18  11.8772
  19  0.222321
  20  0.213485
Done.

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

Extracting fit parameters...

4FGL J1321.1+2216
   Spectrum: LogParabola
324         norm:  3.647e+01  1.117e+01  1.000e-04  1.000e+04 ( 1.000e-12)
325        alpha:  2.281e+00  0.000e+00  0.000e+00  5.000e+00 ( 1.000e+00) fixed
326         beta:  7.755e-02  0.000e+00  0.000e+00  1.000e+01 ( 1.000e+00) fixed
327           Eb:  6.546e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
558    Prefactor:  1.008e+00  2.135e-01  0.000e+00  1.000e+01 ( 1.000e+00)
559        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
560        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
557   Normalization:  9.952e-01  2.223e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 37.07
Ra Dec: 200.296 22.281
Photon Index (Fixed Index): 2.28 +/- 0.00
Photon Flux (Fixed Index): 1.81e-07 +/- 5.53e-08
Energy Flux (Fixed Index): 6.51e-05 +/- 1.99e-05

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) = 5101.24845713
delta logL = 0.162967203909

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 5101.24607651
delta logL = 0.165347827092

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    37.196       1.0000         .10000E-03   10000.    
     2 'alpha     '    2.0789       1.0000          .0000       5.0000    
     3 'Normalizat'    1.0289       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .98804       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5610E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   5101.246     FROM MIGRAD    STATUS=CONVERGED     46 CALLS      199 TOTAL
                     EDM=   .97E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          37.196        13.900        .16429E-02   -.43414E-02
   2  alpha         2.0789        .38465        .21531       -.24379E-04
   3  Normalizat    1.0288        .19533        .42278E-01   -.17213E-03
   4  Prefactor     .98813        .18500        .46117E-01    .64267E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 37.1963
  alpha      = 2.07887
  Normalizat = 1.0288
  Prefactor  = 0.988128
 **********
 **   18 **HESSE 
 **********

 FCN=   5101.246     FROM HESSE     STATUS=OK            29 CALLS      228 TOTAL
                     EDM=   .71E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          37.196        11.832        .65714E-04   -1.4487    
   2  alpha         2.0789        .35126        .88477E-02   -.16926    
   3  Normalizat    1.0288        .22679        .25140E-03   -.92072    
   4  Prefactor     .98813        .21365        .24746E-03   -.93126    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 7.08369e-09
Minuit parameter uncertainties:
  1  11.8324
  2  0.352459
  3  0.227001
  4  0.213834
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/500063': 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) = 5101.24607643
delta logL = 0.165347909357

Extracting fit parameters...

4FGL J1321.1+2216
   Spectrum: LogParabola
324         norm:  3.720e+01  1.183e+01  1.000e-04  1.000e+04 ( 1.000e-12)
325        alpha:  2.079e+00  3.525e-01  0.000e+00  5.000e+00 ( 1.000e+00)
326         beta:  7.755e-02  0.000e+00  0.000e+00  1.000e+01 ( 1.000e+00) fixed
327           Eb:  6.546e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
558    Prefactor:  9.881e-01  2.138e-01  0.000e+00  1.000e+01 ( 1.000e+00)
559        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
560        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
557   Normalization:  1.029e+00  2.270e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 37.36
Ra Dec: 200.296 22.281
Photon Index (Free Index): 2.08 +/- 0.35
Photon Flux (Free Index): 1.50e-07 +/- 7.04e-08
Energy Flux (Free Index): 7.15e-05 +/- 2.70e-05

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/500063/cmap_HighResolution_576547201_576806401_4FGL_J1321.1+2216_daily_bin1301.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET comment='SUCCESS', photon_flux='1.81e-07', energy_flux2='7.15e-05', photon_flux_error='5.53e-08', dlogl='1.65e-01', energy_flux='6.51e-05', photon_flux2='1.50e-07', job_status='DONE', time_completed='2021-09-07 13:38:00.918427', photon_index_error2='0.35', photon_index2='2.08', ts='37.07', fit_tolerance='1e-08', GAL='1.01', photon_index_error='0.00', energy_flux_error2='2.70e-05', EG='1.00', time_epoch_completed='1631047080.92', return_code='0', job_id='500063', GAL2='0.99', EG2='1.03', return_code2='0', energy_flux_error='1.99e-05', photon_flux_error2='7.04e-08', ts2='37.36', photon_index='2.28' WHERE bin_id='1301' AND source_name='4FGL J1321.1+2216' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Tue Sep  7 13:38:00 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0293>
Subject: Job 500063: <4FGL_J1321.1+2216_daily_bin1301> in cluster <slac> Done

Job <4FGL_J1321.1+2216_daily_bin1301> was submitted from host <rhel6-64k> by user <kocevski> in cluster <slac> at Tue Sep  7 13:25:45 2021
Job was executed on host(s) <bullet0293>, in queue <medium>, as user <kocevski> in cluster <slac> at Tue Sep  7 13:26:20 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Tue Sep  7 13:26:20 2021
Terminated at Tue Sep  7 13:38:01 2021
Results reported at Tue Sep  7 13:38:01 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1321.1+2216_daily_bin1301 200.296 22.2808 576547201 576806401 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1321.1+2216 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   492.27 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             281.59 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   701 sec.
    Turnaround time :                            736 sec.

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

