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


Performing analysis on: 4FGL_J1421.1+3859_daily_bin248
RA = 215.292, Dec = 38.9966
tmin = 303609601, tmax = 303868801
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='363939', job_status='RUN', time_executed='2021-09-09 10:36:59.430880', time_epoch_executed='1631209019.43' WHERE source_name='4FGL J1421.1+3859' and cadence='daily' and bin_id='248'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/363939

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/363939/ft1_4FGL_J1421.1+3859_daily_bin248.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/363939/ft2_4FGL_J1421.1+3859_daily_bin248.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/363939/ft1_4FGL_J1421.1+3859_daily_bin248.fits outfile=/scratch/kocevski/363939/ft1_filteredMKT_4FGL_J1421.1+3859_daily_bin248.fits ra=215.292 dec=38.9966 rad=12.0 tmin=303609601.0 tmax=303868801.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.47
user 3.20
sys 0.20

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/363939/ft2_4FGL_J1421.1+3859_daily_bin248.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/363939/ft2_4FGL_J1421.1+3859_daily_bin248.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/363939/ft1_filteredMKT_4FGL_J1421.1+3859_daily_bin248.fits evtable="EVENTS" outfile="/scratch/kocevski/363939/ft1_filtered_4FGL_J1421.1+3859_daily_bin248.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.73
user 0.32
sys 0.16

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/363939/ft1_filtered_4FGL_J1421.1+3859_daily_bin248.fits" evtable="EVENTS" scfile=/scratch/kocevski/363939/ft2_4FGL_J1421.1+3859_daily_bin248.fits sctable="SC_DATA" outfile=/scratch/kocevski/363939/ltcube_303609601_303868801_4FGL_J1421.1+3859_daily_bin248.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/363939/ft2_4FGL_J1421.1+3859_daily_bin248.fits
.....................!
real 11.94
user 11.47
sys 0.32

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/363939/ft1_filtered_4FGL_J1421.1+3859_daily_bin248.fits evtable="EVENTS" scfile=/scratch/kocevski/363939/ft2_4FGL_J1421.1+3859_daily_bin248.fits sctable="SC_DATA" expcube=/scratch/kocevski/363939/ltcube_303609601_303868801_4FGL_J1421.1+3859_daily_bin248.fits outfile=/scratch/kocevski/363939/expmap_303609601_303868801_4FGL_J1421.1+3859_daily_bin248.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/363939/ltcube_303609601_303868801_4FGL_J1421.1+3859_daily_bin248.fits
.....................!
real 193.16
user 187.64
sys 4.72

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

Setting source of interest to:
4FGL J1421.1+3859 @ 215.292 38.9966

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/363939/ft1_filtered_4FGL_J1421.1+3859_daily_bin248.fits scfile=/scratch/kocevski/363939/ft2_4FGL_J1421.1+3859_daily_bin248.fits outfile=/scratch/kocevski/363939/cmap_303609601_303868801_4FGL_J1421.1+3859_daily_bin248.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=215.292 yref=38.9966 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/363939/ft1_filtered_4FGL_J1421.1+3859_daily_bin248.fits scfile=/scratch/kocevski/363939/ft2_4FGL_J1421.1+3859_daily_bin248.fits outfile=/scratch/kocevski/363939/cmap_HighResolution_303609601_303868801_4FGL_J1421.1+3859_daily_bin248.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=215.292 yref=38.9966 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.56
user 0.37
sys 0.16

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/363939/ft1_filtered_4FGL_J1421.1+3859_daily_bin248.fits evtable="EVENTS" scfile=/scratch/kocevski/363939/ft2_4FGL_J1421.1+3859_daily_bin248.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/363939/Model_4FGL_J1421.1+3859_daily_bin248.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/363939/ft1_filtered_4FGL_J1421.1+3859_daily_bin248.fits.....................!
real 45.57
user 44.23
sys 1.20

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/363939/ft1_filtered_4FGL_J1421.1+3859_daily_bin248.fits', '/scratch/kocevski/363939/ft2_4FGL_J1421.1+3859_daily_bin248.fits', expMap='/scratch/kocevski/363939/expmap_303609601_303868801_4FGL_J1421.1+3859_daily_bin248.fits', expCube='/scratch/kocevski/363939/ltcube_303609601_303868801_4FGL_J1421.1+3859_daily_bin248.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/363939/Model_4FGL_J1421.1+3859_daily_bin248.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1421.1+3859'

4FGL J1421.1+3859
   Spectrum: PowerLaw
291    Prefactor:  1.965e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
292        Index:  2.670e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
293        Scale:  9.266e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/363939/ft1_filtered_4FGL_J1421.1+3859_daily_bin248.fits
Spacecraft file(s): /scratch/kocevski/363939/ft2_4FGL_J1421.1+3859_daily_bin248.fits
Exposure map: /scratch/kocevski/363939/expmap_303609601_303868801_4FGL_J1421.1+3859_daily_bin248.fits
Exposure cube: /scratch/kocevski/363939/ltcube_303609601_303868801_4FGL_J1421.1+3859_daily_bin248.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/363939/Model_4FGL_J1421.1+3859_daily_bin248.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) = 5688.92013789

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .11431E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    .17793E-03   1.0000         .10000E-03   10000.    
     3 'norm      '    1.1249       1.0000         .10000E-03   10000.    
     4 'Prefactor '    4.1321       1.0000         .10000E-03   10000.    
     5 'norm      '    31.703       1.0000         .10000E-03   10000.    
     6 'Prefactor '    19.720       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .11758E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10438E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    2.2153       1.0000         .10000E-03   10000.    
    10 'norm      '    3.8459       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10754E-02   1.0000         .10000E-03   10000.    
    12 'Prefactor '    .11422E-03   1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10031E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    .10421E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    33.406       1.0000         .10000E-03   10000.    
    16 'norm      '    2.9572       1.0000         .10000E-03   10000.    
    17 'Prefactor '    .33543E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    .23237E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .13697E-03   1.0000         .10000E-03   10000.    
    20 'norm      '    .10242E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10006E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    .52525E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10497E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    .11543E-03   1.0000         .10000E-03   10000.    
    25 'norm      '    1.3035       1.0000         .10000E-03   10000.    
    26 'norm      '    8.1809       1.0000         .10000E-03   10000.    
    27 'Prefactor '    .21699E-03   1.0000         .10000E-03   10000.    
    28 'Prefactor '    .10457E-03   1.0000         .10000E-03   10000.    
    29 'Prefactor '    .25240E-03   1.0000         .10000E-03   10000.    
    30 'Normalizat'    1.1334       1.0000         .10000E-01   10.000    
    31 'Prefactor '    .71312       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5840E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   5688.912     FROM MIGRAD    STATUS=CONVERGED    785 CALLS     4076 TOTAL
                     EDM=   .79E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  3.7%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    20.888       -.30777E-06** at limit **
   2  Prefactor     .10000E-03    18.763       -.17360E-06** at limit **
   3  norm          1.1252        1.1507        .30839E-07    .20366E-03
   4  Prefactor     4.1217        4.5552        .52137E-06    .44577E-03
   5  norm          31.650        17.661        .69191E-07   -.13641E-03
   6  Prefactor     19.755        16.700        .27629E-07   -.17518E-03
   7  Prefactor     .10000E-03    26.299       -.26636E-06** at limit **
   8  Prefactor     .10000E-03    1.9206       -.11648E-06** at limit **
   9  Prefactor     2.1200        35.233        .39335E-05    .89359E-04
  10  norm          3.8453        3.3170        .20463E-07   -.19031E-03
  11  Prefactor     .10030E-03    14.035        .39118E-05** at limit **
  12  Prefactor     .10000E-03    6.2415        .14656E-06** at limit **
  13  Prefactor     .10000E-03    1.4807       -.10636E-06** at limit **
  14  norm          .10000E-03    7.8324        .10806E-06** at limit **
  15  Prefactor     33.447        26.911        .68439E-06    .20322E-03
  16  norm          2.9619        5.1364        .73945E-06    .26478E-03
  17  Prefactor     .10000E-03    17.188        .23008E-06** at limit **
  18  Prefactor     .10000E-03    9.4501       -.28111E-06** at limit **
  19  Prefactor     .10000E-03    9.7306       -.24735E-06** at limit **
  20  norm          .10000E-03    2.3935       -.45904E-07** at limit **
  21  Prefactor     .10000E-03    8.4840       -.29022E-06** at limit **
  22  Prefactor     .10000E-03    8.8897        .50485E-07** at limit **
  23  Prefactor     .10000E-03    2.3527       -.69928E-07** at limit **
  24  Prefactor     .10000E-03    11.881        .61813E-06** at limit **
  25  norm          1.3025        1.4488        .21078E-06    .58540E-03
  26  norm          8.1988        4.3355        .16542E-07    .15673E-03
  27  Prefactor     .10000E-03    5.9975        .26534E-06** at limit **
  28  Prefactor     .10000E-03    28.819        .17060E-06** at limit **
  29  Prefactor     .10000E-03    14.398       -.87093E-07** at limit **
  30  Normalizat    1.1337        .19437       -.44275E-05    .12796E-03
  31  Prefactor     .71290        .21599        .64849E-05    .23477E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 1.12522
  Prefactor  = 4.12165
  norm       = 31.6497
  Prefactor  = 19.7551
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 2.11995
  norm       = 3.84529
  Prefactor  = 0.0001003
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 33.4468
  norm       = 2.96194
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 1.30253
  norm       = 8.19875
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Normalizat = 1.13374
  Prefactor  = 0.712899
 **********
 **   18 **HESSE 
 **********

 FCN=   5688.912     FROM HESSE     STATUS=OK           614 CALLS     4690 TOTAL
                     EDM=   .66E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    20.914        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     .10000E-03    18.782        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm          1.1252        1.0734        .78375E-03   -1.5496    
   4  Prefactor     4.1217        4.5658        .16079E-03   -1.5302    
   5  norm          31.650        17.673        .71163E-04   -1.4582    
   6  Prefactor     19.755        16.529        .90194E-04   -1.4819    
   7  Prefactor     .10000E-03    26.394        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .10000E-03    1.9442        .10210E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     2.1200        35.479        .27633E-03   -1.5417    
  10  norm          3.8453        3.3113        .12278E-03   -1.5316    
  11  Prefactor     .10030E-03    48.958        .39593E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10000E-03    6.2567        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     .10000E-03    1.4973        .89591E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          .10000E-03    7.8586        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     33.447        27.058        .69331E-04   -1.4551    
  16  norm          2.9619        5.1505        .21702E-03   -1.5364    
  17  Prefactor     .10000E-03    17.211        .21342E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .10000E-03    9.5059        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10000E-03    9.7467        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  norm          .10000E-03    2.3945        .11397E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .10000E-03    8.5421        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     .10000E-03    8.9043        .21133E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .10000E-03    2.3606        .11296E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     .10000E-03    12.267        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  norm          1.3025        1.4299        .91252E-04   -1.5480    
  26  norm          8.1988        4.3252        .11063E-03   -1.5135    
  27  Prefactor     .10000E-03    6.0415        .18003E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  28  Prefactor     .10000E-03    28.841        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  29  Prefactor     .10000E-03    14.607        .21461E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  30  Normalizat    1.1337        .20318        .20121E-03   -.88676    
  31  Prefactor     .71290        .22496        .14475E-02   -1.0302    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 6.57175e-09
Minuit parameter uncertainties:
  1  0.000126159
  2  4.78559e-05
  3  1.07341
  4  4.56623
  5  17.6757
  6  16.5327
  7  8.16565e-05
  8  9.34678e-06
  9  17.3568
  10  3.31148
  11  0.00767205
  12  2.88189e-06
  13  5.40258e-06
  14  1.27175e-05
  15  27.068
  16  5.1513
  17  4.20708e-05
  18  6.41462e-05
  19  5.69469e-05
  20  3.63384e-06
  21  4.28597e-05
  22  9.007e-06
  23  6.73402e-06
  24  0.0001415
  25  1.42996
  26  4.32535
  27  2.36014e-05
  28  0.000109009
  29  1.74603e-05
  30  0.203321
  31  0.225248
Done.

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

Extracting fit parameters...

4FGL J1421.1+3859
   Spectrum: PowerLaw
291    Prefactor:  1.000e-04  2.882e-06  1.000e-04  1.000e+04 ( 1.000e-13)
292        Index:  2.670e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
293        Scale:  9.266e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
581    Prefactor:  7.129e-01  2.252e-01  0.000e+00  1.000e+01 ( 1.000e+00)
582        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
583        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
580   Normalization:  1.134e+00  2.033e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 215.292 38.997
Photon Flux Upper Limit: 5.58e-08 ph cm-2 s-1
Energy Flux Upper Limit: 4.39e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/363939/likelihoodResults_303609601_303868801_4FGL_J1421.1+3859_daily_bin248.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): 102
logL (Free Index) = 5688.9130564
delta logL = -0.000760920040193

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 5688.91229546
delta logL = 2.1674168238e-08

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10182E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.6452       1.0000          .0000       10.000    
     3 'Normalizat'    1.1337       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .71295       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5840E+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=   5688.912     FROM MIGRAD    STATUS=CONVERGED     91 CALLS      243 TOTAL
                     EDM=   .73E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10300E-03    4.6195        .18142E-01** at limit **
   2  Index         2.5548        6.1707        .50000        .27854E-04
   3  Normalizat    1.1337        .31593E-02    .20121E-03    .39495E-04
   4  Prefactor     .71290        .36999E-02    .28950E-03    .26861E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000102999
  Index      = 2.5548
  Normalizat = 1.13374
  Prefactor  = 0.712896
 **********
 **   18 **HESSE 
 **********

 FCN=   5688.912     FROM HESSE     STATUS=NOT POSDEF    29 CALLS      272 TOTAL
                     EDM=   .96E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10300E-03    66.320        .19315E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.5548        8.3135        .50000       -.51099    
   3  Normalizat    1.1337        .12010E-01    .80483E-05   -.88676    
   4  Prefactor     .71290        .14065E-01    .11580E-04   -1.0302    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 9.58888e-09
Minuit parameter uncertainties:
  1  0.028236
  2  322.286
  3  0.01201
  4  0.0140653
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/363939': 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) = 5688.91229488
delta logL = 6.01550709689e-07

Extracting fit parameters...

4FGL J1421.1+3859
   Spectrum: PowerLaw
291    Prefactor:  1.030e-04  2.824e-02  1.000e-04  1.000e+04 ( 1.000e-13)
292        Index:  2.555e+00  3.223e+02  0.000e+00  1.000e+01 (-1.000e+00)
293        Scale:  9.266e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
581    Prefactor:  7.129e-01  1.407e-02  0.000e+00  1.000e+01 ( 1.000e+00)
582        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
583        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
580   Normalization:  1.134e+00  1.201e-02  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 215.292 38.997

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/363939/cmap_HighResolution_303609601_303868801_4FGL_J1421.1+3859_daily_bin248.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='4.39e-03', job_status='DONE', photon_flux_upper_limit='5.58e-08', time_completed='2021-09-09 10:50:52.986812', job_id='363939', GAL2='0.71', fit_tolerance='1e-08', EG2='1.13', EG='1.13', time_epoch_completed='1631209852.99', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.71', dlogl='6.02e-07', ts2='-0.00', photon_index_error='0.00', photon_index='2.67' WHERE bin_id='248' AND source_name='4FGL J1421.1+3859' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Sep  9 10:50:53 PDT 2021


------------------------------------------------------------
Sender: LSF System <scs@bullet0119>
Subject: Job 363939: <4FGL_J1421.1+3859_daily_bin248> in cluster <slac> Done

Job <4FGL_J1421.1+3859_daily_bin248> was submitted from host <rhel6-64o> by user <kocevski> in cluster <slac> at Thu Sep  9 10:36:42 2021
Job was executed on host(s) <bullet0119>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Sep  9 10:36:43 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Thu Sep  9 10:36:43 2021
Terminated at Thu Sep  9 10:50:53 2021
Results reported at Thu Sep  9 10:50:53 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1421.1+3859_daily_bin248 215.292 38.9966 303609601 303868801 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1421.1+3859 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   831.00 sec.
    Max Memory :                                 1040 MB
    Average Memory :                             323.11 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   850 sec.
    Turnaround time :                            851 sec.

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

