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


Performing analysis on: 4FGL_J1221.3+3010_daily_bin763
RA = 185.345, Dec = 30.1677
tmin = 437097601, tmax = 437356801
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='519700', job_status='RUN', time_executed='2021-09-05 09:20:51.804576', time_epoch_executed='1630858851.8' WHERE source_name='4FGL J1221.3+3010' and cadence='daily' and bin_id='763'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/519700

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/519700/ft1_4FGL_J1221.3+3010_daily_bin763.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/519700/ft2_4FGL_J1221.3+3010_daily_bin763.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/519700/ft1_4FGL_J1221.3+3010_daily_bin763.fits outfile=/scratch/kocevski/519700/ft1_filteredMKT_4FGL_J1221.3+3010_daily_bin763.fits ra=185.345 dec=30.1677 rad=12.0 tmin=437097601.0 tmax=437356801.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.23
user 4.91
sys 0.24

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/519700/ft2_4FGL_J1221.3+3010_daily_bin763.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/519700/ft2_4FGL_J1221.3+3010_daily_bin763.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/519700/ft1_filteredMKT_4FGL_J1221.3+3010_daily_bin763.fits evtable="EVENTS" outfile="/scratch/kocevski/519700/ft1_filtered_4FGL_J1221.3+3010_daily_bin763.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.50
user 0.35
sys 0.14

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/519700/ft1_filtered_4FGL_J1221.3+3010_daily_bin763.fits" evtable="EVENTS" scfile=/scratch/kocevski/519700/ft2_4FGL_J1221.3+3010_daily_bin763.fits sctable="SC_DATA" outfile=/scratch/kocevski/519700/ltcube_437097601_437356801_4FGL_J1221.3+3010_daily_bin763.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/519700/ft2_4FGL_J1221.3+3010_daily_bin763.fits
.....................!
real 12.48
user 12.12
sys 0.32

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/519700/ft1_filtered_4FGL_J1221.3+3010_daily_bin763.fits evtable="EVENTS" scfile=/scratch/kocevski/519700/ft2_4FGL_J1221.3+3010_daily_bin763.fits sctable="SC_DATA" expcube=/scratch/kocevski/519700/ltcube_437097601_437356801_4FGL_J1221.3+3010_daily_bin763.fits outfile=/scratch/kocevski/519700/expmap_437097601_437356801_4FGL_J1221.3+3010_daily_bin763.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/519700/ltcube_437097601_437356801_4FGL_J1221.3+3010_daily_bin763.fits
.....................!
real 191.75
user 186.91
sys 4.44

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 199 point sources and 0 extended sources

Setting source of interest to:
4FGL J1221.3+3010 @ 185.345 30.1677

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/519700/ft1_filtered_4FGL_J1221.3+3010_daily_bin763.fits scfile=/scratch/kocevski/519700/ft2_4FGL_J1221.3+3010_daily_bin763.fits outfile=/scratch/kocevski/519700/cmap_437097601_437356801_4FGL_J1221.3+3010_daily_bin763.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=185.345 yref=30.1677 axisrot=0.0 rafield="RA" decfield="DEC" proj="AIT" hpx_ordering_scheme="RING" hpx_order=3 hpx_ebin=yes hpx_region="" evtable="EVENTS" sctable="SC_DATA" efield="ENERGY" tfield="TIME" chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

This is gtbin version HEAD
real 0.54
user 0.38
sys 0.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/519700/ft1_filtered_4FGL_J1221.3+3010_daily_bin763.fits scfile=/scratch/kocevski/519700/ft2_4FGL_J1221.3+3010_daily_bin763.fits outfile=/scratch/kocevski/519700/cmap_HighResolution_437097601_437356801_4FGL_J1221.3+3010_daily_bin763.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=185.345 yref=30.1677 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.38
sys 0.16

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/519700/ft1_filtered_4FGL_J1221.3+3010_daily_bin763.fits evtable="EVENTS" scfile=/scratch/kocevski/519700/ft2_4FGL_J1221.3+3010_daily_bin763.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/519700/Model_4FGL_J1221.3+3010_daily_bin763.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/519700/ft1_filtered_4FGL_J1221.3+3010_daily_bin763.fits.....................!
real 58.14
user 56.74
sys 1.22

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/519700/ft1_filtered_4FGL_J1221.3+3010_daily_bin763.fits', '/scratch/kocevski/519700/ft2_4FGL_J1221.3+3010_daily_bin763.fits', expMap='/scratch/kocevski/519700/expmap_437097601_437356801_4FGL_J1221.3+3010_daily_bin763.fits', expCube='/scratch/kocevski/519700/ltcube_437097601_437356801_4FGL_J1221.3+3010_daily_bin763.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/519700/Model_4FGL_J1221.3+3010_daily_bin763.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1221.3+3010'

4FGL J1221.3+3010
   Spectrum: PowerLaw
317    Prefactor:  1.833e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
318        Index:  1.707e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
319        Scale:  4.501e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/519700/ft1_filtered_4FGL_J1221.3+3010_daily_bin763.fits
Spacecraft file(s): /scratch/kocevski/519700/ft2_4FGL_J1221.3+3010_daily_bin763.fits
Exposure map: /scratch/kocevski/519700/expmap_437097601_437356801_4FGL_J1221.3+3010_daily_bin763.fits
Exposure cube: /scratch/kocevski/519700/ltcube_437097601_437356801_4FGL_J1221.3+3010_daily_bin763.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/519700/Model_4FGL_J1221.3+3010_daily_bin763.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) = 6151.58684472

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10006E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    27.502       1.0000         .10000E-03   10000.    
     3 'Prefactor '    1.5144       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     8 'norm      '    1.4473       1.0000         .10000E-03   10000.    
     9 'Prefactor '    1.6914       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    11 'norm      '    11.156       1.0000         .10000E-03   10000.    
    12 'Prefactor '    11.764       1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10004E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    3.8228       1.0000         .10000E-03   10000.    
    15 'Prefactor '    5.2741       1.0000         .10000E-03   10000.    
    16 'norm      '    8.0120       1.0000         .10000E-03   10000.    
    17 'norm      '    4.6223       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .68462       1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10007E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    8.9625       1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    23 'norm      '    .10031E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    26.374       1.0000         .10000E-03   10000.    
    25 'norm      '    .10004E-03   1.0000         .10000E-03   10000.    
    26 'Prefactor '    10.093       1.0000         .10000E-03   10000.    
    27 'norm      '    4.1419       1.0000         .10000E-03   10000.    
    28 'norm      '    2.6417       1.0000         .10000E-03   10000.    
    29 'norm      '    14.618       1.0000         .10000E-03   10000.    
    30 'Normalizat'    1.1804       1.0000         .10000E-01   10.000    
    31 'Prefactor '    .73615       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6280E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   6151.576     FROM MIGRAD    STATUS=CONVERGED    774 CALLS     4081 TOTAL
                     EDM=   .20E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.8%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    11.029       -.92720E-06** at limit **
   2  Prefactor     27.503        15.694        .19206E-06    .34368E-04
   3  Prefactor     1.5148        5.9211       -.60123E-06   -.28718E-04
   4  Prefactor     .10000E-03    6.8245       -.59028E-06** at limit **
   5  Prefactor     .10000E-03    .62627       -.61792E-07** at limit **
   6  Prefactor     .10000E-03    8.2314        .16977E-05** at limit **
   7  Prefactor     .10000E-03    33.524       -.99071E-06** at limit **
   8  norm          1.4473        .96500       -.26100E-07   -.67517E-05
   9  Prefactor     1.6913        3.1787       -.75083E-07   -.13509E-04
  10  Prefactor     .10000E-03    11.311        .78687E-06** at limit **
  11  norm          11.156        4.0317       -.16105E-06    .25116E-04
  12  Prefactor     11.763        8.8733       -.65155E-07   -.13543E-05
  13  Prefactor     .10000E-03    1.0929        .10044E-07** at limit **
  14  Prefactor     3.8224        2.3801       -.19787E-07    .29170E-04
  15  Prefactor     5.2739        5.2274       -.68018E-07    .66275E-04
  16  norm          8.0119        .74611       -.41194E-08    .21112E-03
  17  norm          4.6218        5.0972       -.15709E-06    .59107E-05
  18  Prefactor     .67938        1.3021       -.23897E-06   -.35209E-03
  19  Prefactor     .10000E-03    8.9886       -.17111E-05** at limit **
  20  Prefactor     .10000E-03    33.425        .52901E-06** at limit **
  21  Prefactor     8.9630        7.6086       -.66001E-07    .63828E-05
  22  Prefactor     .10000E-03    3.9833       -.84781E-07** at limit **
  23  norm          .10000E-03    2.3437        .40017E-06** at limit **
  24  Prefactor     26.363        31.105       -.13418E-04   -.10106E-04
  25  norm          .10000E-03    2.8657       -.30701E-09** at limit **
  26  Prefactor     10.092        17.964        .98475E-06    .20626E-04
  27  norm          4.1415        6.1492        .94879E-06   -.55484E-04
  28  norm          2.6366        8.0454        .24068E-06    .13429E-03
  29  norm          14.625        14.435        .16904E-05    .12269E-04
  30  Normalizat    1.1806        .20334        .23152E-05   -.98029E-04
  31  Prefactor     .73593        .22477       -.14358E-05    .89066E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 27.5034
  Prefactor  = 1.51483
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 1.44726
  Prefactor  = 1.69128
  Prefactor  = 0.0001
  norm       = 11.1558
  Prefactor  = 11.7635
  Prefactor  = 0.0001
  Prefactor  = 3.82238
  Prefactor  = 5.27395
  norm       = 8.01193
  norm       = 4.62176
  Prefactor  = 0.679378
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 8.963
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 26.3626
  norm       = 0.0001
  Prefactor  = 10.0918
  norm       = 4.14148
  norm       = 2.63661
  norm       = 14.6249
  Normalizat = 1.18065
  Prefactor  = 0.735933
 **********
 **   18 **HESSE 
 **********

 FCN=   6151.576     FROM HESSE     STATUS=OK           634 CALLS     4715 TOTAL
                     EDM=   .64E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    11.059        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     27.503        15.689        .76392E-04   -1.4659    
   3  Prefactor     1.5148        5.9551        .34743E-03   -1.5462    
   4  Prefactor     .10000E-03    6.8370        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10000E-03    .63442        .60597E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    8.2356        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10000E-03    33.541        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          1.4473        .96545        .30443E-03   -1.5467    
   9  Prefactor     1.6913        3.1515        .18595E-03   -1.5448    
  10  Prefactor     .10000E-03    11.325        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  norm          11.156        4.0265        .90480E-04   -1.5040    
  12  Prefactor     11.763        8.8909        .58399E-03   -1.5022    
  13  Prefactor     .10000E-03    1.0993        .79925E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     3.8224        2.3915        .91297E-04   -1.5317    
  15  Prefactor     5.2739        5.2361        .86362E-03   -1.5249    
  16  norm          8.0119        .74721        .19736E-04   -1.5142    
  17  norm          4.6218        5.0915        .17828E-03   -1.5278    
  18  Prefactor     .67938        7.5231        .70878E-01   -1.5543    
  19  Prefactor     .10000E-03    8.9947        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .10000E-03    33.440        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     8.9630        7.6080        .13388E-03   -1.5109    
  22  Prefactor     .10000E-03    4.0037        .15268E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  norm          .10000E-03    2.3804        .11750E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     26.363        31.098        .78005E-04   -1.4681    
  25  norm          .10000E-03    2.9158        .12962E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  Prefactor     10.092        17.928        .12613E-03   -1.5073    
  27  norm          4.1415        6.1777        .99028E-03   -1.5301    
  28  norm          2.6366        7.9713        .22284E-03   -1.5383    
  29  norm          14.625        14.321        .10476E-03   -1.4943    
  30  Normalizat    1.1806        .24164        .26163E-03   -.87203    
  31  Prefactor     .73593        .26476        .37336E-03   -1.0213    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 6.40964e-10
Minuit parameter uncertainties:
  1  9.31312e-06
  2  15.6913
  3  5.95743
  4  6.4641e-06
  5  1.22743e-06
  6  4.73894e-06
  7  1.02365e-05
  8  0.965462
  9  3.15179
  10  5.69898e-06
  11  4.02658
  12  8.89187
  13  1.29174e-06
  14  2.39154
  15  5.23655
  16  0.747207
  17  5.09193
  18  4.52191
  19  6.22978e-06
  20  3.89942e-05
  21  7.6088
  22  1.62726e-05
  23  5.12117e-05
  24  31.117
  25  3.45733e-06
  26  17.9378
  27  6.17869
  28  7.97448
  29  14.3242
  30  0.241873
  31  0.265214
Done.

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

Extracting fit parameters...

4FGL J1221.3+3010
   Spectrum: PowerLaw
317    Prefactor:  1.000e-04  1.292e-06  1.000e-04  1.000e+04 ( 1.000e-13)
318        Index:  1.707e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
319        Scale:  4.501e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
625    Prefactor:  7.359e-01  2.652e-01  0.000e+00  1.000e+01 ( 1.000e+00)
626        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
627        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
624   Normalization:  1.181e+00  2.419e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 185.345 30.168
Photon Flux Upper Limit: 4.79e-08 ph cm-2 s-1
Energy Flux Upper Limit: 3.50e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/519700/likelihoodResults_437097601_437356801_4FGL_J1221.3+3010_daily_bin763.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) = 6151.57967004
delta logL = -0.00398911474076

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 6151.57568355
delta logL = -2.6192938094e-06

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10664E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    1.6927       1.0000          .0000       10.000    
     3 'Normalizat'    1.1807       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .73587       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6280E+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=   6151.576     FROM MIGRAD    STATUS=CONVERGED     86 CALLS      236 TOTAL
                     EDM=   .33E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10017E-03    9.9033        .80726E-03** at limit **
   2  Index         1.6709        5.2563        .50000        .94866E-04
   3  Normalizat    1.1807        .14677E-01    .26163E-03    .11627E-03
   4  Prefactor     .73593        .16988E-01    .37336E-03    .63914E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000100171
  Index      = 1.67089
  Normalizat = 1.18065
  Prefactor  = 0.735929
 **********
 **   18 **HESSE 
 **********

 FCN=   6151.576     FROM HESSE     STATUS=NOT POSDEF    29 CALLS      265 TOTAL
                     EDM=   .16E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10017E-03    45.836        .16145E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         1.6709        5.0861        .50000       -.72860    
   3  Normalizat    1.1807        .32818E-01    .52326E-04   -.87203    
   4  Prefactor     .73593        .37945E-01    .14934E-04   -1.0214    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 1.60406e-08
Minuit parameter uncertainties:
  1  0.00560233
  2  99.8668
  3  0.0328186
  4  0.0379464
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/519700': 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): 102
logL (Free Index) = 6151.57568
delta logL = 9.26498614717e-07

Extracting fit parameters...

4FGL J1221.3+3010
   Spectrum: PowerLaw
317    Prefactor:  1.002e-04  5.602e-03  1.000e-04  1.000e+04 ( 1.000e-13)
318        Index:  1.671e+00  9.987e+01  0.000e+00  1.000e+01 (-1.000e+00)
319        Scale:  4.501e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
625    Prefactor:  7.359e-01  3.795e-02  0.000e+00  1.000e+01 ( 1.000e+00)
626        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
627        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
624   Normalization:  1.181e+00  3.282e-02  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 185.345 30.168

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/519700/cmap_HighResolution_437097601_437356801_4FGL_J1221.3+3010_daily_bin763.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='3.50e-03', job_status='DONE', photon_flux_upper_limit='4.79e-08', time_completed='2021-09-05 09:37:14.558406', job_id='519700', GAL2='0.74', fit_tolerance='1e-08', EG2='1.18', EG='1.18', time_epoch_completed='1630859834.56', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.74', dlogl='9.26e-07', ts2='-0.00', photon_index_error='0.00', photon_index='1.71' WHERE bin_id='763' AND source_name='4FGL J1221.3+3010' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sun Sep  5 09:37:14 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0207>
Subject: Job 519700: <4FGL_J1221.3+3010_daily_bin763> in cluster <slac> Done

Job <4FGL_J1221.3+3010_daily_bin763> was submitted from host <rhel6-64m> by user <kocevski> in cluster <slac> at Sun Sep  5 09:20:36 2021
Job was executed on host(s) <bullet0207>, in queue <medium>, as user <kocevski> in cluster <slac> at Sun Sep  5 09:20:37 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sun Sep  5 09:20:37 2021
Terminated at Sun Sep  5 09:37:15 2021
Results reported at Sun Sep  5 09:37:15 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1221.3+3010_daily_bin763 185.345 30.1677 437097601 437356801 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1221.3+3010 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   978.14 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             358.34 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   997 sec.
    Turnaround time :                            999 sec.

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

