/nfs/farm/g/glast/g/LCRepository/bin/miniconda2/envs/fermitools_v1.0.5/lib/python2.7/site-packages/pyfits/__init__.py:22: PyFITSDeprecationWarning: PyFITS is deprecated, please use astropy.io.fits
  PyFITSDeprecationWarning)  # noqa

Likelihood Analysis Tool
Support Contact: Daniel Kocevski (daniel.kocevski@nasa.gov)


Waiting 3 seconds before starting...
Proceeding.

Importing modules...
This is make3FGLxml version 01r0.
The default diffuse model files and names are for pass 8 and assume you have v10r00p05 of the Fermi Science Tools or higher.
This is make4FGLxml version 01r04.
The default diffuse model files and names are for pass 8 and 4FGL and assume you have v11r5p3 of the Fermi Science Tools or higher.

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

/nfs/farm/g/glast/g/LCRepository/bin/miniconda2/envs/fermitools_v1.0.5/lib/python2.7/site-packages/matplotlib/cbook/deprecation.py:106: MatplotlibDeprecationWarning: The mpl_toolkits.axes_grid module was deprecated in version 2.1. Use mpl_toolkits.axes_grid1 and mpl_toolkits.axisartist provies the same functionality instead.
  warnings.warn(message, mplDeprecation, stacklevel=1)

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

number of points = 7427
number of fields = 27
No RA_SUN column yet. Adding RA_SUN/DEC_SUN columns.
Done.


Performing analysis on: 4FGL_J1221.3+3010_daily_bin389
RA = 185.345, Dec = 30.1677
tmin = 340156801, tmax = 340416001
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='516452', job_status='RUN', time_executed='2021-09-05 09:10:58.777541', time_epoch_executed='1630858258.78' WHERE source_name='4FGL J1221.3+3010' and cadence='daily' and bin_id='389'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/516452

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/516452/ft1_4FGL_J1221.3+3010_daily_bin389.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/516452/ft2_4FGL_J1221.3+3010_daily_bin389.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/516452/ft1_4FGL_J1221.3+3010_daily_bin389.fits outfile=/scratch/kocevski/516452/ft1_filteredMKT_4FGL_J1221.3+3010_daily_bin389.fits ra=185.345 dec=30.1677 rad=12.0 tmin=340156801.0 tmax=340416001.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 3.58
user 3.08
sys 0.22

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/516452/ft2_4FGL_J1221.3+3010_daily_bin389.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/516452/ft1_filteredMKT_4FGL_J1221.3+3010_daily_bin389.fits evtable="EVENTS" outfile="/scratch/kocevski/516452/ft1_filtered_4FGL_J1221.3+3010_daily_bin389.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.79
user 0.34
sys 0.17

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/516452/ft1_filtered_4FGL_J1221.3+3010_daily_bin389.fits" evtable="EVENTS" scfile=/scratch/kocevski/516452/ft2_4FGL_J1221.3+3010_daily_bin389.fits sctable="SC_DATA" outfile=/scratch/kocevski/516452/ltcube_340156801_340416001_4FGL_J1221.3+3010_daily_bin389.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/516452/ft2_4FGL_J1221.3+3010_daily_bin389.fits
.....................!
real 12.10
user 11.54
sys 0.30

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/516452/ft1_filtered_4FGL_J1221.3+3010_daily_bin389.fits evtable="EVENTS" scfile=/scratch/kocevski/516452/ft2_4FGL_J1221.3+3010_daily_bin389.fits sctable="SC_DATA" expcube=/scratch/kocevski/516452/ltcube_340156801_340416001_4FGL_J1221.3+3010_daily_bin389.fits outfile=/scratch/kocevski/516452/expmap_340156801_340416001_4FGL_J1221.3+3010_daily_bin389.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/516452/ltcube_340156801_340416001_4FGL_J1221.3+3010_daily_bin389.fits
.....................!
real 191.63
user 185.76
sys 4.04

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/516452/ft1_filtered_4FGL_J1221.3+3010_daily_bin389.fits scfile=/scratch/kocevski/516452/ft2_4FGL_J1221.3+3010_daily_bin389.fits outfile=/scratch/kocevski/516452/cmap_340156801_340416001_4FGL_J1221.3+3010_daily_bin389.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.57
user 0.38
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/516452/ft1_filtered_4FGL_J1221.3+3010_daily_bin389.fits scfile=/scratch/kocevski/516452/ft2_4FGL_J1221.3+3010_daily_bin389.fits outfile=/scratch/kocevski/516452/cmap_HighResolution_340156801_340416001_4FGL_J1221.3+3010_daily_bin389.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.59
user 0.40
sys 0.14

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

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/516452/ft1_filtered_4FGL_J1221.3+3010_daily_bin389.fits', '/scratch/kocevski/516452/ft2_4FGL_J1221.3+3010_daily_bin389.fits', expMap='/scratch/kocevski/516452/expmap_340156801_340416001_4FGL_J1221.3+3010_daily_bin389.fits', expCube='/scratch/kocevski/516452/ltcube_340156801_340416001_4FGL_J1221.3+3010_daily_bin389.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/516452/Model_4FGL_J1221.3+3010_daily_bin389.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/516452/ft1_filtered_4FGL_J1221.3+3010_daily_bin389.fits
Spacecraft file(s): /scratch/kocevski/516452/ft2_4FGL_J1221.3+3010_daily_bin389.fits
Exposure map: /scratch/kocevski/516452/expmap_340156801_340416001_4FGL_J1221.3+3010_daily_bin389.fits
Exposure cube: /scratch/kocevski/516452/ltcube_340156801_340416001_4FGL_J1221.3+3010_daily_bin389.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/516452/Model_4FGL_J1221.3+3010_daily_bin389.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) = 6983.65925804

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10476E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    4.7392       1.0000         .10000E-03   10000.    
     3 'Prefactor '    3.0798       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10109E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    1.6399       1.0000         .10000E-03   10000.    
     6 'Prefactor '    32.086       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     8 'norm      '    13.468       1.0000         .10000E-03   10000.    
     9 'Prefactor '    3.6445       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10008E-03   1.0000         .10000E-03   10000.    
    11 'norm      '    2.7962       1.0000         .10000E-03   10000.    
    12 'Prefactor '    2.8667       1.0000         .10000E-03   10000.    
    13 'Prefactor '    3.6426       1.0000         .10000E-03   10000.    
    14 'Prefactor '    4.0521       1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    1.3245       1.0000         .10000E-03   10000.    
    17 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10769E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10015E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    23 'norm      '    5.1497       1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    25 'norm      '    4.1923       1.0000         .10000E-03   10000.    
    26 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    27 'norm      '    .10012E-03   1.0000         .10000E-03   10000.    
    28 'norm      '    2.9529       1.0000         .10000E-03   10000.    
    29 'norm      '    .10019E-03   1.0000         .10000E-03   10000.    
    30 'Normalizat'    .97661       1.0000         .10000E-01   10.000    
    31 'Prefactor '    1.0434       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=   6983.655     FROM MIGRAD    STATUS=CONVERGED    810 CALLS     4086 TOTAL
                     EDM=   .47E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .5%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    9.5861        .14755E-05** at limit **
   2  Prefactor     4.7361        12.757       -.26138E-06   -.93045E-04
   3  Prefactor     3.0800        4.9407       -.87745E-06   -.53316E-03
   4  Prefactor     .10000E-03    22.225       -.90306E-05** at limit **
   5  Prefactor     1.6399        1.3497        .25643E-08    .20673E-03
   6  Prefactor     32.085        24.961        .10587E-06    .29758E-04
   7  Prefactor     .10000E-03    31.634        .62458E-05** at limit **
   8  norm          13.468        2.1622        .36121E-07    .43319E-03
   9  Prefactor     3.6449        4.0807        .16481E-05   -.41595E-03
  10  Prefactor     .10000E-03    11.235       -.56952E-05** at limit **
  11  norm          2.7962        2.1418        .21422E-07    .83649E-04
  12  Prefactor     2.8671        5.5398       -.62871E-06   -.42749E-03
  13  Prefactor     3.6425        2.2197        .24781E-07    .10556E-03
  14  Prefactor     4.0524        2.5794       -.38072E-08   -.20672E-03
  15  Prefactor     .10000E-03    1.8618       -.60560E-08** at limit **
  16  norm          1.3246        .32325       -.92237E-08   -.33208E-03
  17  norm          .10000E-03    2.2134        .74426E-08** at limit **
  18  Prefactor     .10000E-03    10.124       -.21145E-05** at limit **
  19  Prefactor     .10000E-03    6.6423       -.43454E-05** at limit **
  20  Prefactor     .10000E-03    134.44       -.45727E-05** at limit **
  21  Prefactor     .10000E-03    8.3333        .43599E-05** at limit **
  22  Prefactor     .10000E-03    2.3487        .73529E-08** at limit **
  23  norm          5.1457        4.4953        .97247E-06   -.25508E-03
  24  Prefactor     .10000E-03    15.124        .80589E-05** at limit **
  25  norm          4.1924        3.3400        .36739E-06   -.15382E-03
  26  Prefactor     .10000E-03    4.9066       -.47351E-06** at limit **
  27  norm          .10000E-03    3.2519        .17033E-07** at limit **
  28  norm          2.9554        3.0963       -.45284E-06   -.99041E-03
  29  norm          .10000E-03    5.8378        .29373E-05** at limit **
  30  Normalizat    .97657        .18131       -.75266E-07   -.35109E-04
  31  Prefactor     1.0434        .20390       -.41653E-06   -.21263E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 4.73606
  Prefactor  = 3.08
  Prefactor  = 0.0001
  Prefactor  = 1.63988
  Prefactor  = 32.0853
  Prefactor  = 0.0001
  norm       = 13.4679
  Prefactor  = 3.6449
  Prefactor  = 0.0001
  norm       = 2.79623
  Prefactor  = 2.8671
  Prefactor  = 3.64253
  Prefactor  = 4.05239
  Prefactor  = 0.0001
  norm       = 1.32455
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 5.14568
  Prefactor  = 0.0001
  norm       = 4.19242
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 2.95543
  norm       = 0.0001
  Normalizat = 0.976568
  Prefactor  = 1.04341
 **********
 **   18 **HESSE 
 **********

 FCN=   6983.655     FROM HESSE     STATUS=OK           620 CALLS     4706 TOTAL
                     EDM=   .93E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    9.6009        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     4.7361        12.742        .18483E-03   -1.5273    
   3  Prefactor     3.0800        4.9648        .22398E-03   -1.5357    
   4  Prefactor     .10000E-03    22.333        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     1.6399        1.3556        .85269E-04   -1.5452    
   6  Prefactor     32.085        24.973        .70738E-04   -1.4574    
   7  Prefactor     .10000E-03    31.629        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          13.468        2.1626        .46843E-04   -1.4974    
   9  Prefactor     3.6449        4.0231        .16961E-03   -1.5326    
  10  Prefactor     .10000E-03    11.231        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  norm          2.7962        2.1428        .10149E-03   -1.5374    
  12  Prefactor     2.8671        5.5594        .24009E-03   -1.5369    
  13  Prefactor     3.6425        2.2223        .91543E-04   -1.5326    
  14  Prefactor     4.0524        2.5716        .10059E-03   -1.5305    
  15  Prefactor     .10000E-03    1.8666        .11134E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          1.3246        .32322        .22447E-04   -1.5478    
  17  norm          .10000E-03    2.2310        .12137E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .10000E-03    10.232        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10000E-03    6.6330        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .10000E-03    134.96        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .10000E-03    8.4373        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     .10000E-03    2.3598        .12506E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  norm          5.1457        4.4799        .15729E-03   -1.5254    
  24  Prefactor     .10000E-03    15.078        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  norm          4.1924        3.3347        .13220E-03   -1.5298    
  26  Prefactor     .10000E-03    4.9114        .18078E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  norm          .10000E-03    3.3520        .29429E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  norm          2.9554        3.0859        .14443E-03   -1.5364    
  29  norm          .10000E-03    5.9451        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  30  Normalizat    .97657        .21433        .26818E-03   -.93820    
  31  Prefactor     1.0434        .24097        .30234E-03   -.91296    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 9.29452e-10
Minuit parameter uncertainties:
  1  1.18655e-05
  2  12.7497
  3  4.96542
  4  4.12936e-05
  5  1.35567
  6  24.9808
  7  3.01445e-06
  8  2.16263
  9  4.02337
  10  9.73497e-06
  11  2.14285
  12  5.56045
  13  2.22239
  14  2.57166
  15  2.31661e-07
  16  0.323223
  17  1.00368e-06
  18  1.08973e-05
  19  5.29264e-07
  20  0.000191304
  21  2.15681e-05
  22  1.2498e-07
  23  4.48018
  24  3.56461e-05
  25  3.33487
  26  3.15429e-07
  27  7.42527e-07
  28  3.08611
  29  1.30782e-05
  30  0.21452
  31  0.241219
Done.

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

Extracting fit parameters...

4FGL J1221.3+3010
   Spectrum: PowerLaw
317    Prefactor:  3.643e+00  2.222e+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

GAL_V02
   Spectrum: PowerLaw
625    Prefactor:  1.043e+00  2.412e-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:  9.766e-01  2.145e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 23.39
Ra Dec: 185.345 30.168
Photon Index (Fixed Index): 1.71 +/- 0.00
Photon Flux (Fixed Index): 3.40e-08 +/- 2.07e-08
Energy Flux (Fixed Index): 5.42e-05 +/- 3.31e-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) = 6983.43498269
delta logL = 0.220128206774

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 6983.41753366
delta logL = 0.237577241975

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    4.0722       1.0000         .10000E-03   10000.    
     2 'Index     '    1.3893       1.0000          .0000       10.000    
     3 'Normalizat'    .98543       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.0430       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=   6983.418     FROM MIGRAD    STATUS=CONVERGED     99 CALLS      291 TOTAL
                     EDM=   .17E-10    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     4.0751        2.6742        .10732E-03    .62076E-04
   2  Index         1.3901        .50089        .90868E-02    .25488E-04
   3  Normalizat    .98524        .20541        .26731E-03    .44699E-04
   4  Prefactor     1.0434        .23942        .30265E-03    .23628E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 4.07513
  Index      = 1.3901
  Normalizat = 0.985236
  Prefactor  = 1.04338
 **********
 **   18 **HESSE 
 **********

 FCN=   6983.418     FROM HESSE     STATUS=OK            25 CALLS      316 TOTAL
                     EDM=   .10E-10    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     4.0751        2.6853        .42928E-05   -1.5304    
   2  Index         1.3901        .50308        .36347E-03   -.80666    
   3  Normalizat    .98524        .20562        .10692E-04   -.93527    
   4  Prefactor     1.0434        .23969        .12106E-04   -.91297    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.03963e-11
Minuit parameter uncertainties:
  1  2.68534
  2  0.504875
  3  0.205783
  4  0.239934
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/516452': 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) = 6983.4175293
delta logL = 0.237581597095

Extracting fit parameters...

4FGL J1221.3+3010
   Spectrum: PowerLaw
317    Prefactor:  4.075e+00  2.685e+00  1.000e-04  1.000e+04 ( 1.000e-13)
318        Index:  1.390e+00  5.049e-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:  1.043e+00  2.399e-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:  9.852e-01  2.058e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 23.87
Ra Dec: 185.345 30.168
Photon Index (Free Index): 1.39 +/- 0.50
Photon Flux (Free Index): 1.94e-08 +/- 2.26e-08
Energy Flux (Free Index): 8.84e-05 +/- 8.49e-05

Creating a high resolution counts map...
INFO: Auto-setting vmin to -1.000e-01 [aplpy.core]
INFO: Auto-setting vmax to  1.110e+00 [aplpy.core]
Saving /scratch/kocevski/516452/cmap_HighResolution_340156801_340416001_4FGL_J1221.3+3010_daily_bin389.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET comment='SUCCESS', photon_flux='3.40e-08', energy_flux2='8.84e-05', photon_flux_error='2.07e-08', dlogl='2.38e-01', energy_flux='5.42e-05', photon_flux2='1.94e-08', job_status='DONE', time_completed='2021-09-05 09:25:46.791598', photon_index_error2='0.50', photon_index2='1.39', ts='23.39', fit_tolerance='1e-08', GAL='1.04', photon_index_error='0.00', energy_flux_error2='8.49e-05', EG='0.98', time_epoch_completed='1630859146.79', return_code='0', job_id='516452', GAL2='1.04', EG2='0.99', return_code2='0', energy_flux_error='3.31e-05', photon_flux_error2='2.26e-08', ts2='23.87', photon_index='1.71' WHERE bin_id='389' AND source_name='4FGL J1221.3+3010' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sun Sep  5 09:25:46 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0206>
Subject: Job 516452: <4FGL_J1221.3+3010_daily_bin389> in cluster <slac> Done

Job <4FGL_J1221.3+3010_daily_bin389> was submitted from host <rhel6-64q> by user <kocevski> in cluster <slac> at Sun Sep  5 09:10:42 2021
Job was executed on host(s) <bullet0206>, in queue <medium>, as user <kocevski> in cluster <slac> at Sun Sep  5 09:10:43 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:10:43 2021
Terminated at Sun Sep  5 09:25:47 2021
Results reported at Sun Sep  5 09:25:47 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1221.3+3010_daily_bin389 185.345 30.1677 340156801 340416001 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 :                                   881.01 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             334.03 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   904 sec.
    Turnaround time :                            905 sec.

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

