aklog: Couldn't determine realm of user:aklog: No credentials cache found  while getting realm
/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 211 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 = 73886
number of fields = 31
RA_SUN column already exists. File will not be modified.
Done.


Performing analysis on: 4FGL_J1640.3+6850_monthly_bin167
RA = 250.082, Dec = 68.8483
tmin = 669859201, tmax = 672451201
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='899436', job_status='RUN', time_executed='2022-04-24 02:34:18.949146', time_epoch_executed='1650792858.95' WHERE source_name='4FGL J1640.3+6850' and cadence='monthly' and bin_id='167'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/899436

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

Retrieving the FT1 file...

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

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

Retrieving 456 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/899436/ft1_4FGL_J1640.3+6850_monthly_bin167.fits


Retrieving the FT1 file...

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

Retrieving 456 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/899436/ft2_4FGL_J1640.3+6850_monthly_bin167.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/899436/ft1_4FGL_J1640.3+6850_monthly_bin167.fits outfile=/scratch/kocevski/899436/ft1_filteredMKT_4FGL_J1640.3+6850_monthly_bin167.fits ra=250.082 dec=68.8483 rad=12.0 tmin=669859201.0 tmax=672451201.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 38.51
user 37.61
sys 0.77

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/899436/ft2_4FGL_J1640.3+6850_monthly_bin167.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/899436/ft2_4FGL_J1640.3+6850_monthly_bin167.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/899436/ft1_filteredMKT_4FGL_J1640.3+6850_monthly_bin167.fits evtable="EVENTS" outfile="/scratch/kocevski/899436/ft1_filtered_4FGL_J1640.3+6850_monthly_bin167.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.86
user 0.67
sys 0.18

Number of photons that the gtmktime cut: 8279

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/899436/ft1_filtered_4FGL_J1640.3+6850_monthly_bin167.fits" evtable="EVENTS" scfile=/scratch/kocevski/899436/ft2_4FGL_J1640.3+6850_monthly_bin167.fits sctable="SC_DATA" outfile=/scratch/kocevski/899436/ltcube_669859201_672451201_4FGL_J1640.3+6850_monthly_bin167.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/899436/ft2_4FGL_J1640.3+6850_monthly_bin167.fits
.....................!
real 123.33
user 122.73
sys 0.36

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/899436/ft1_filtered_4FGL_J1640.3+6850_monthly_bin167.fits evtable="EVENTS" scfile=/scratch/kocevski/899436/ft2_4FGL_J1640.3+6850_monthly_bin167.fits sctable="SC_DATA" expcube=/scratch/kocevski/899436/ltcube_669859201_672451201_4FGL_J1640.3+6850_monthly_bin167.fits outfile=/scratch/kocevski/899436/expmap_669859201_672451201_4FGL_J1640.3+6850_monthly_bin167.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/899436/ltcube_669859201_672451201_4FGL_J1640.3+6850_monthly_bin167.fits
.....................!
real 192.83
user 187.47
sys 4.99

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

Setting source of interest to:
4FGL J1640.3+6850 @ 250.082 68.8483

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/899436/ft1_filtered_4FGL_J1640.3+6850_monthly_bin167.fits scfile=/scratch/kocevski/899436/ft2_4FGL_J1640.3+6850_monthly_bin167.fits outfile=/scratch/kocevski/899436/cmap_669859201_672451201_4FGL_J1640.3+6850_monthly_bin167.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=250.082 yref=68.8483 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.80
user 0.62
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/899436/ft1_filtered_4FGL_J1640.3+6850_monthly_bin167.fits scfile=/scratch/kocevski/899436/ft2_4FGL_J1640.3+6850_monthly_bin167.fits outfile=/scratch/kocevski/899436/cmap_HighResolution_669859201_672451201_4FGL_J1640.3+6850_monthly_bin167.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=250.082 yref=68.8483 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.81
user 0.62
sys 0.18

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/899436/ft1_filtered_4FGL_J1640.3+6850_monthly_bin167.fits evtable="EVENTS" scfile=/scratch/kocevski/899436/ft2_4FGL_J1640.3+6850_monthly_bin167.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/899436/Model_4FGL_J1640.3+6850_monthly_bin167.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/899436/ft1_filtered_4FGL_J1640.3+6850_monthly_bin167.fits.....................!
real 743.16
user 740.54
sys 1.25

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/899436/ft1_filtered_4FGL_J1640.3+6850_monthly_bin167.fits', '/scratch/kocevski/899436/ft2_4FGL_J1640.3+6850_monthly_bin167.fits', expMap='/scratch/kocevski/899436/expmap_669859201_672451201_4FGL_J1640.3+6850_monthly_bin167.fits', expCube='/scratch/kocevski/899436/ltcube_669859201_672451201_4FGL_J1640.3+6850_monthly_bin167.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/899436/Model_4FGL_J1640.3+6850_monthly_bin167.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1640.3+6850'

4FGL J1640.3+6850
   Spectrum: PowerLaw
350    Prefactor:  3.992e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-14)
351        Index:  2.132e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
352        Scale:  2.329e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/899436/ft1_filtered_4FGL_J1640.3+6850_monthly_bin167.fits
Spacecraft file(s): /scratch/kocevski/899436/ft2_4FGL_J1640.3+6850_monthly_bin167.fits
Exposure map: /scratch/kocevski/899436/expmap_669859201_672451201_4FGL_J1640.3+6850_monthly_bin167.fits
Exposure cube: /scratch/kocevski/899436/ltcube_669859201_672451201_4FGL_J1640.3+6850_monthly_bin167.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/899436/Model_4FGL_J1640.3+6850_monthly_bin167.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) = 87512.7103866

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    14.305       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .73249       1.0000         .10000E-03   10000.    
     4 'Prefactor '    20.326       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    10.453       1.0000         .10000E-03   10000.    
     7 'norm      '    2.2532       1.0000         .10000E-03   10000.    
     8 'Prefactor '    10.382       1.0000         .10000E-03   10000.    
     9 'Prefactor '    7.1182       1.0000         .10000E-03   10000.    
    10 'norm      '    16.476       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    5.6760       1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    3.8103       1.0000         .10000E-03   10000.    
    15 'Prefactor '    10.488       1.0000         .10000E-03   10000.    
    16 'norm      '    .54557E-01   1.0000         .10000E-03   10000.    
    17 'Prefactor '    1.7926       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    5.6976       1.0000         .10000E-03   10000.    
    20 'Prefactor '    .15333E-02   1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    1.1199       1.0000         .10000E-03   10000.    
    23 'Prefactor '    2.8385       1.0000         .10000E-03   10000.    
    24 'norm      '    3.6087       1.0000         .10000E-03   10000.    
    25 'norm      '    7.1983       1.0000         .10000E-03   10000.    
    26 'Prefactor '    .10646E-03   1.0000         .10000E-03   10000.    
    27 'norm      '    4.0781       1.0000         .10000E-03   10000.    
    28 'Prefactor '    .46399       1.0000         .10000E-03   10000.    
    29 'Prefactor '    9.2228       1.0000         .10000E-03   10000.    
    30 'Prefactor '    9.6708       1.0000         .10000E-03   10000.    
    31 'Prefactor '    .80498       1.0000         .10000E-03   10000.    
    32 'Prefactor '    16.720       1.0000         .10000E-03   10000.    
    33 'Normalizat'    1.0661       1.0000         .10000E-01   10.000    
    34 'Prefactor '    .92218       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6760E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   87512.56     FROM MIGRAD    STATUS=CONVERGED    934 CALLS     4234 TOTAL
                     EDM=   .46E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.1%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     14.306        10.373       -.13926E-06    .10170E-04
   2  Prefactor     .10000E-03    2.7160        .15705E-05** at limit **
   3  Prefactor     .73260        2.1618       -.26995E-06   -.47957E-05
   4  Prefactor     20.326        9.0646       -.61253E-07   -.11787E-04
   5  Prefactor     .10000E-03    2.2390       -.65940E-07** at limit **
   6  Prefactor     10.454        6.0793       -.54210E-06    .46194E-05
   7  norm          2.2530        .67679        .89790E-07    .33007E-03
   8  Prefactor     10.376        20.352       -.83182E-05   -.48770E-05
   9  Prefactor     7.1181        5.6546        .69259E-07   -.10333E-03
  10  norm          16.477        4.6361       -.44609E-07    .58527E-04
  11  Prefactor     .10000E-03    5.7125        .18084E-05** at limit **
  12  Prefactor     5.6759        1.7349        .60013E-07   -.22337E-02
  13  Prefactor     .10000E-03    3.5720        .15625E-05** at limit **
  14  norm          3.8103        1.2605        .44947E-07   -.31427E-02
  15  Prefactor     10.488        4.9057       -.10212E-06    .68006E-05
  16  norm          .54587E-01    .11398        .38786E-07   -.19753E-02
  17  Prefactor     1.7927        2.3680       -.53353E-06   -.40139E-03
  18  Prefactor     .10000E-03    .11845       -.19470E-08** at limit **
  19  Prefactor     5.6975        3.8099       -.17039E-06   -.21576E-04
  20  Prefactor     .10001E-03    .41333        .73472E-07** at limit **
  21  Prefactor     .10000E-03    5.1855       -.24826E-05** at limit **
  22  Prefactor     1.1202        1.2505        .63347E-08   -.19357E-03
  23  Prefactor     2.8405        6.9788       -.17736E-05   -.20395E-04
  24  norm          3.6088        .72363       -.11137E-07    .11444E-03
  25  norm          7.1983        .36041       -.42867E-08    .17939E-02
  26  Prefactor     .10001E-03    .66258       -.56497E-06** at limit **
  27  norm          4.0783        1.2501       -.12623E-07   -.29413E-04
  28  Prefactor     .46850        1.6021       -.14189E-06    .97444E-04
  29  Prefactor     9.2233        17.025        .26008E-06    .11993E-04
  30  Prefactor     9.6688        2.2431       -.42746E-07    .39873E-03
  31  Prefactor     .82708        1.8038       -.48540E-07   -.64254E-04
  32  Prefactor     16.722        14.148       -.53130E-07   -.26931E-06
  33  Normalizat    1.0661        .51642E-01    .44396E-06    .58701E-03
  34  Prefactor     .92212        .40602E-01   -.27920E-07    .10438E-02
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 14.3056
  Prefactor  = 0.0001
  Prefactor  = 0.732603
  Prefactor  = 20.3264
  Prefactor  = 0.0001
  Prefactor  = 10.4537
  norm       = 2.25305
  Prefactor  = 10.3757
  Prefactor  = 7.11807
  norm       = 16.4767
  Prefactor  = 0.0001
  Prefactor  = 5.67586
  Prefactor  = 0.0001
  norm       = 3.8103
  Prefactor  = 10.4882
  norm       = 0.0545873
  Prefactor  = 1.79267
  Prefactor  = 0.0001
  Prefactor  = 5.6975
  Prefactor  = 0.000100008
  Prefactor  = 0.0001
  Prefactor  = 1.12019
  Prefactor  = 2.84047
  norm       = 3.60876
  norm       = 7.19829
  Prefactor  = 0.000100011
  norm       = 4.07826
  Prefactor  = 0.468502
  Prefactor  = 9.22325
  Prefactor  = 9.66885
  Prefactor  = 0.827079
  Prefactor  = 16.7215
  Normalizat = 1.06614
  Prefactor  = 0.922123
 **********
 **   18 **HESSE 
 **********

 FCN=   87512.56     FROM HESSE     STATUS=OK           770 CALLS     5004 TOTAL
                     EDM=   .12E-05    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     14.306        10.372        .10590E-03   -1.4951    
   2  Prefactor     .10000E-03    2.7499        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .73260        10.576        .71779E-02   -1.5537    
   4  Prefactor     20.326        9.0740        .44420E-03   -1.4806    
   5  Prefactor     .10000E-03    2.3136        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     10.454        6.0744        .12393E-03   -1.5061    
   7  norm          2.2530        .67572        .12775E-03   -1.5408    
   8  Prefactor     10.376        20.422        .12435E-03   -1.5064    
   9  Prefactor     7.1181        5.6648        .75176E-03   -1.5174    
  10  norm          16.477        4.6234        .98670E-04   -1.4896    
  11  Prefactor     .10000E-03    5.7154        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     5.6759        1.9485        .84303E-03   -1.5231    
  13  Prefactor     .10000E-03    3.6130        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          3.8103        1.8725        .10339E-02   -1.5318    
  15  Prefactor     10.488        4.9128        .12372E-03   -1.5060    
  16  norm          .54587E-01    .11066        .13288E-03   -1.5661    
  17  Prefactor     1.7927        2.2835        .31236E-03   -1.5440    
  18  Prefactor     .10000E-03    .25640        .19561E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     5.6975        3.6686        .16828E-03   -1.5231    
  20  Prefactor     .10001E-03    .43443        .54788E-01   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .10000E-03    5.3252        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     1.1202        1.2346        .33904E-03   -1.5496    
  23  Prefactor     2.8405        6.9533        .24136E-03   -1.5371    
  24  norm          3.6088        .72199        .10625E-03   -1.5328    
  25  norm          7.1983        .35945        .38161E-04   -1.5171    
  26  Prefactor     .10001E-03    2.9390        .44828E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  norm          4.0783        1.2444        .16668E-03   -1.5304    
  28  Prefactor     .46850        8.7983        .67043E-02   -1.5571    
  29  Prefactor     9.2233        17.019        .13197E-03   -1.5100    
  30  Prefactor     9.6688        2.1968        .12886E-03   -1.5086    
  31  Prefactor     .82708        6.1223        .52367E-02   -1.5526    
  32  Prefactor     16.722        14.164        .48974E-03   -1.4890    
  33  Normalizat    1.0661        .60796E-01    .26508E-03   -.90846    
  34  Prefactor     .92212        .47878E-01    .23028E-03   -.95372    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.24695e-06
Minuit parameter uncertainties:
  1  10.3736
  2  4.35604e-06
  3  5.56783
  4  9.07466
  5  6.76631e-06
  6  6.07471
  7  0.675718
  8  20.4361
  9  5.66518
  10  4.6235
  11  2.50445e-07
  12  1.94856
  13  4.24698e-06
  14  1.87253
  15  4.91303
  16  0.110663
  17  2.2836
  18  1.03486e-06
  19  3.66873
  20  0.000119805
  21  7.48692e-06
  22  1.23461
  23  6.95525
  24  0.721995
  25  0.359455
  26  0.000351613
  27  1.24444
  28  4.06081
  29  17.0278
  30  2.19681
  31  4.50088
  32  14.1664
  33  0.0607996
  34  0.0478802
Done.

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

Extracting fit parameters...

4FGL J1640.3+6850
   Spectrum: PowerLaw
350    Prefactor:  1.000e-04  4.247e-06  1.000e-04  1.000e+04 ( 1.000e-14)
351        Index:  2.132e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
352        Scale:  2.329e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
673    Prefactor:  9.221e-01  4.788e-02  0.000e+00  1.000e+01 ( 1.000e+00)
674        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
675        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
672   Normalization:  1.066e+00  6.080e-02  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 250.082 68.848
Photon Flux Upper Limit: 8.21e-09 ph cm-2 s-1
Energy Flux Upper Limit: 6.23e-04 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/899436/likelihoodResults_669859201_672451201_4FGL_J1640.3+6850_monthly_bin167.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) = 87512.5597074
delta logL = -0.0013196948712

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 87512.5583894
delta logL = -1.69932900462e-06

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10678E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.0992       1.0000          .0000       10.000    
     3 'Normalizat'    1.0662       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .92205       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6760E+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=   87512.56     FROM MIGRAD    STATUS=CONVERGED     91 CALLS      246 TOTAL
                     EDM=   .13E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10131E-03    21.474        .18142E-02** at limit **
   2  Index         2.0442        7.6651        .50000        .58829E-04
   3  Normalizat    1.0661        .29207E-02    .26508E-03   -.73286E-03
   4  Prefactor     .92212        .23910E-02    .23028E-03   -.86811E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000101313
  Index      = 2.0442
  Normalizat = 1.06614
  Prefactor  = 0.922122
 **********
 **   18 **HESSE 
 **********

 FCN=   87512.56     FROM HESSE     STATUS=NOT POSDEF    29 CALLS      275 TOTAL
                     EDM=   .61E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10131E-03    100.89        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.0442        5.1077        .50000       -.63250    
   3  Normalizat    1.0661        .64747E-02    .10603E-04   -.90846    
   4  Prefactor     .92212        .53004E-02    .92112E-05   -.95372    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 6.06874e-08
Minuit parameter uncertainties:
  1  0.0230539
  2  210.057
  3  0.00647474
  4  0.00530037
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/899436': 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) = 87512.5583864
delta logL = 1.26619124785e-06

Extracting fit parameters...

4FGL J1640.3+6850
   Spectrum: PowerLaw
350    Prefactor:  1.013e-04  2.305e-02  1.000e-04  1.000e+04 ( 1.000e-14)
351        Index:  2.044e+00  2.101e+02  0.000e+00  1.000e+01 (-1.000e+00)
352        Scale:  2.329e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
673    Prefactor:  9.221e-01  5.300e-03  0.000e+00  1.000e+01 ( 1.000e+00)
674        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
675        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
672   Normalization:  1.066e+00  6.475e-03  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 250.082 68.848

Creating a high resolution counts map...
INFO: Auto-setting vmin to -2.000e-01 [aplpy.core]
INFO: Auto-setting vmax to  2.220e+00 [aplpy.core]
Saving /scratch/kocevski/899436/cmap_HighResolution_669859201_672451201_4FGL_J1640.3+6850_monthly_bin167.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='6.23e-04', job_status='DONE', photon_flux_upper_limit='8.21e-09', time_completed='2022-04-24 05:47:12.364789', job_id='899436', GAL2='0.92', fit_tolerance='1e-08', EG2='1.07', EG='1.07', time_epoch_completed='1650804432.36', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.92', dlogl='1.27e-06', ts2='-0.00', photon_index_error='0.00', photon_index='2.13' WHERE bin_id='167' AND source_name='4FGL J1640.3+6850' AND cadence='monthly';

Database successfully updated.


Analysis Complete.


Sun Apr 24 05:47:12 PDT 2022


------------------------------------------------------------
Sender: LSF System <lsf@bullet0211>
Subject: Job 899436: <4FGL_J1640.3+6850_monthly_bin167> in cluster <slac> Done

Job <4FGL_J1640.3+6850_monthly_bin167> was submitted from host <rhel6-64k> by user <kocevski> in cluster <slac> at Sun Apr 24 02:00:52 2022
Job was executed on host(s) <bullet0211>, in queue <medium>, as user <kocevski> in cluster <slac> at Sun Apr 24 02:30:37 2022
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sun Apr 24 02:30:37 2022
Terminated at Sun Apr 24 05:47:13 2022
Results reported at Sun Apr 24 05:47:13 2022

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1640.3+6850_monthly_bin167 250.082 68.8483 669859201 672451201 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1640.3+6850 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   11551.00 sec.
    Max Memory :                                 865 MB
    Average Memory :                             433.95 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   11796 sec.
    Turnaround time :                            13581 sec.

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

