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 80 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 make4FGLDR3xml version 01r09.
The default diffuse model files and names are for P8R3, 4FGL DRs, and the default fermitools directory locations.

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 = 7488
number of fields = 31
RA_SUN column already exists. File will not be modified.
Done.


Performing analysis on: 4FGL_J1640.4+3945_daily_bin1746
RA = 250.119, Dec = 39.7626
tmin = 691891201, tmax = 692150401
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='732562', job_status='RUN', time_executed='2022-12-08 01:16:56.188489', time_epoch_executed='1670491016.19' WHERE source_name='4FGL J1640.4+3945' and cadence='daily' and bin_id='1746'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/732562

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/732562/ft1_4FGL_J1640.4+3945_daily_bin1746.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/732562/ft2_4FGL_J1640.4+3945_daily_bin1746.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/732562/ft1_4FGL_J1640.4+3945_daily_bin1746.fits outfile=/scratch/kocevski/732562/ft1_filteredMKT_4FGL_J1640.4+3945_daily_bin1746.fits ra=250.119 dec=39.7626 rad=12.0 tmin=691891201.0 tmax=692150401.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 4.73
user 4.50
sys 0.21

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/732562/ft2_4FGL_J1640.4+3945_daily_bin1746.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/732562/ft2_4FGL_J1640.4+3945_daily_bin1746.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/732562/ft1_filteredMKT_4FGL_J1640.4+3945_daily_bin1746.fits evtable="EVENTS" outfile="/scratch/kocevski/732562/ft1_filtered_4FGL_J1640.4+3945_daily_bin1746.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.32
sys 0.16

Number of photons that the gtmktime cut: 780

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/732562/ft1_filtered_4FGL_J1640.4+3945_daily_bin1746.fits" evtable="EVENTS" scfile=/scratch/kocevski/732562/ft2_4FGL_J1640.4+3945_daily_bin1746.fits sctable="SC_DATA" outfile=/scratch/kocevski/732562/ltcube_691891201_692150401_4FGL_J1640.4+3945_daily_bin1746.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/732562/ft2_4FGL_J1640.4+3945_daily_bin1746.fits
.....................!
real 12.08
user 11.70
sys 0.32

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/732562/ft1_filtered_4FGL_J1640.4+3945_daily_bin1746.fits evtable="EVENTS" scfile=/scratch/kocevski/732562/ft2_4FGL_J1640.4+3945_daily_bin1746.fits sctable="SC_DATA" expcube=/scratch/kocevski/732562/ltcube_691891201_692150401_4FGL_J1640.4+3945_daily_bin1746.fits outfile=/scratch/kocevski/732562/expmap_691891201_692150401_4FGL_J1640.4+3945_daily_bin1746.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/732562/ltcube_691891201_692150401_4FGL_J1640.4+3945_daily_bin1746.fits
.....................!
real 191.25
user 185.84
sys 5.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 205 point sources and 0 extended sources

Setting source of interest to:
4FGL J1640.4+3945 @ 250.119 39.7626

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/732562/ft1_filtered_4FGL_J1640.4+3945_daily_bin1746.fits scfile=/scratch/kocevski/732562/ft2_4FGL_J1640.4+3945_daily_bin1746.fits outfile=/scratch/kocevski/732562/cmap_691891201_692150401_4FGL_J1640.4+3945_daily_bin1746.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.119 yref=39.7626 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/732562/ft1_filtered_4FGL_J1640.4+3945_daily_bin1746.fits scfile=/scratch/kocevski/732562/ft2_4FGL_J1640.4+3945_daily_bin1746.fits outfile=/scratch/kocevski/732562/cmap_HighResolution_691891201_692150401_4FGL_J1640.4+3945_daily_bin1746.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.119 yref=39.7626 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.37
sys 0.16

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/732562/ft1_filtered_4FGL_J1640.4+3945_daily_bin1746.fits evtable="EVENTS" scfile=/scratch/kocevski/732562/ft2_4FGL_J1640.4+3945_daily_bin1746.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/732562/Model_4FGL_J1640.4+3945_daily_bin1746.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/732562/ft1_filtered_4FGL_J1640.4+3945_daily_bin1746.fits....................!
real 67.12
user 65.62
sys 1.25

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/732562/ft1_filtered_4FGL_J1640.4+3945_daily_bin1746.fits', '/scratch/kocevski/732562/ft2_4FGL_J1640.4+3945_daily_bin1746.fits', expMap='/scratch/kocevski/732562/expmap_691891201_692150401_4FGL_J1640.4+3945_daily_bin1746.fits', expCube='/scratch/kocevski/732562/ltcube_691891201_692150401_4FGL_J1640.4+3945_daily_bin1746.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/732562/Model_4FGL_J1640.4+3945_daily_bin1746.xml', optimizer='MINUIT')

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

4FGL J1640.4+3945
   Spectrum: PowerLaw
308    Prefactor:  1.345e+00  0.000e+00  0.000e+00  1.000e+06 ( 1.000e-12)
309        Index:  2.421e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
310        Scale:  1.366e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/732562/ft1_filtered_4FGL_J1640.4+3945_daily_bin1746.fits
Spacecraft file(s): /scratch/kocevski/732562/ft2_4FGL_J1640.4+3945_daily_bin1746.fits
Exposure map: /scratch/kocevski/732562/expmap_691891201_692150401_4FGL_J1640.4+3945_daily_bin1746.fits
Exposure cube: /scratch/kocevski/732562/ltcube_691891201_692150401_4FGL_J1640.4+3945_daily_bin1746.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/732562/Model_4FGL_J1640.4+3945_daily_bin1746.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) = 8308.04634644

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    28.536       1.0000          .0000       .10000E+07
     2 'Prefactor '    45.591       1.0000          .0000       .10000E+07
     3 'Prefactor '    .42305E-06   1.0000          .0000       .10000E+07
     4 'Prefactor '    .43300E-04   1.0000          .0000       .10000E+07
     5 'Prefactor '    23.556       1.0000          .0000       .10000E+07
     6 'Prefactor '    .13410E-04   1.0000          .0000       .10000E+07
     7 'norm      '    .24575       1.0000          .0000       .10000E+07
     8 'norm      '    12.999       1.0000          .0000       .10000E+07
     9 'Prefactor '    22.261       1.0000          .0000       .10000E+07
    10 'Prefactor '    .17580E-03   1.0000          .0000       .10000E+07
    11 'norm      '    71.596       1.0000          .0000       .10000E+07
    12 'Prefactor '    .83978       1.0000          .0000       .10000E+07
    13 'Prefactor '    1.6107       1.0000          .0000       .10000E+07
    14 'Prefactor '    3.4980       1.0000          .0000       .10000E+07
    15 'Prefactor '    .11317E-02   1.0000          .0000       .10000E+07
    16 'norm      '    4.6615       1.0000          .0000       .10000E+07
    17 'norm      '    .67496       1.0000          .0000       .10000E+07
    18 'Prefactor '    1.5511       1.0000          .0000       .10000E+07
    19 'norm      '    .30253       1.0000          .0000       .10000E+07
    20 'norm      '    12.053       1.0000          .0000       .10000E+07
    21 'norm      '    2.9113       1.0000          .0000       .10000E+07
    22 'norm      '    .33906E-03   1.0000          .0000       .10000E+07
    23 'Prefactor '    124.62       1.0000          .0000       .10000E+07
    24 'Normalizat'    1.1712       1.0000         .10000E-01   10.000    
    25 'Prefactor '    .69666       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6620E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   8308.025     FROM MIGRAD    STATUS=CONVERGED    176 CALLS     2208 TOTAL
                     EDM=   .17E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .7%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     28.584        9.6134       -.95769E-08   -.33963E-01
   2  Prefactor     43.843        68.219       -.77158E-07    .37191E-01
   3  Prefactor      .0000        1.7883       -.47822E-07** at limit **
   4  Prefactor      .0000        3.3560        .71934E-08** at limit **
   5  Prefactor     23.737        20.056        .40616E-07   -.17446E-01
   6  Prefactor      .0000        2.3056        .82880E-08** at limit **
   7  norm          .24565        .13506        .28949E-08** at limit **
   8  norm          12.914        11.249       -.26283E-07   -.12540E-03
   9  Prefactor     22.347        16.365       -.20871E-07   -.41869E-02
  10  Prefactor      .0000        3.6917       -.59472E-07** at limit **
  11  norm          73.278        50.823        .62386E-07   -.11022E-01
  12  Prefactor     .83087        1.5282        .83709E-08   -.66736E-03
  13  Prefactor     1.6079        1.3917       -.13365E-07   -.17051E-02
  14  Prefactor     3.4996        2.3923        .52574E-08   -.10519E-03
  15  Prefactor     .17819E-07    40.598        .60281E-06** at limit **
  16  norm          4.6608        1.6385        .62568E-08    .55175E-04
  17  norm          .67518        .64455       -.30615E-10   -.85880E-03
  18  Prefactor     1.5549        3.9237       -.35242E-08   -.25083E-03
  19  norm          .30232        .46932        .30591E-08    .15538E-03
  20  norm          12.002        7.5175        .25371E-07   -.88277E-03
  21  norm          2.9112        1.3876        .82883E-09    .95445E-05
  22  norm          .11491E-07    35.576        .36989E-06** at limit **
  23  Prefactor     125.29        26.483        .32088E-07    .16693    
  24  Normalizat    1.1710        .19731       -.16470E-05   -.79506E-04
  25  Prefactor     .69670        .15423        .10126E-05   -.48454E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 28.5836
  Prefactor  = 43.8425
  Prefactor  = 0
  Prefactor  = 0
  Prefactor  = 23.7374
  Prefactor  = 0
  norm       = 0.245647
  norm       = 12.9137
  Prefactor  = 22.3474
  Prefactor  = 0
  norm       = 73.278
  Prefactor  = 0.830872
  Prefactor  = 1.60785
  Prefactor  = 3.49964
  Prefactor  = 1.78191e-08
  norm       = 4.66083
  norm       = 0.67518
  Prefactor  = 1.55486
  norm       = 0.302321
  norm       = 12.0016
  norm       = 2.9112
  norm       = 1.14908e-08
  Prefactor  = 125.292
  Normalizat = 1.17097
  Prefactor  = 0.696697
 **********
 **   18 **HESSE 
 **********

 FCN=   8308.025     FROM HESSE     STATUS=OK           499 CALLS     2707 TOTAL
                     EDM=   .12E-05    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     28.584        22.893        .18723E-03   -1.5601    
   2  Prefactor     43.843        75.184        .14811E-03   -1.5576    
   3  Prefactor      .0000        1.8038        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor      .0000        3.3666        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     23.737        21.974        .20609E-03   -1.5611    
   6  Prefactor      .0000        2.2895        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  norm          .24565        .14101        .48195E-03   -1.5698    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          12.914        11.250        .27756E-03   -1.5636    
   9  Prefactor     22.347        16.489        .21200E-03   -1.5613    
  10  Prefactor      .0000        3.6282        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  norm          73.278        52.188        .11819E-03   -1.5537    
  12  Prefactor     .83087        1.6096        .50015E-03   -1.5690    
  13  Prefactor     1.6079        1.4387        .83428E-03   -1.5683    
  14  Prefactor     3.4996        2.4094        .54035E-03   -1.5671    
  15  Prefactor     .17819E-07    1.4458        .42118E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          4.6608        1.6414        .46589E-03   -1.5665    
  17  norm          .67518        .65729        .62765E-03   -1.5692    
  18  Prefactor     1.5549        4.0005        .85487E-03   -1.5683    
  19  norm          .30232        .52387        .17826E-02   -1.5697    
  20  norm          12.002        7.6177        .28829E-03   -1.5639    
  21  norm          2.9112        1.3924        .59521E-03   -1.5674    
  22  norm          .11491E-07    2.7895        .54571E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     125.29        67.462        .89585E-04   -1.5484    
  24  Normalizat    1.1710        .16975        .55461E-01   -.87505    
  25  Prefactor     .69670        .13056        .42357E-01   -1.0366    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.23617e-06
Minuit parameter uncertainties:
  1  22.8928
  2  75.1859
  3  7.11562e-07
  4  1.29686e-05
  5  21.9742
  6  7.393e-06
  7  0.141014
  8  11.25
  9  16.4886
  10  7.95007e-06
  11  52.1879
  12  1.60959
  13  1.43874
  14  2.4094
  15  0.000320984
  16  1.64142
  17  0.657287
  18  4.00048
  19  0.523872
  20  7.6177
  21  1.39244
  22  0.000358461
  23  67.4625
  24  0.169825
  25  0.130616
Done.

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

Extracting fit parameters...

4FGL J1640.4+3945
   Spectrum: PowerLaw
308    Prefactor:  8.309e-01  1.610e+00  0.000e+00  1.000e+06 ( 1.000e-12)
309        Index:  2.421e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
310        Scale:  1.366e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
659    Prefactor:  6.967e-01  1.306e-01  0.000e+00  1.000e+01 ( 1.000e+00)
660        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
661        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
658   Normalization:  1.171e+00  1.698e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.74
Ra Dec: 250.119 39.763
Photon Flux Upper Limit: 1.17e-07 ph cm-2 s-1
Energy Flux Upper Limit: 9.06e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/732562/likelihoodResults_691891201_692150401_4FGL_J1640.4+3945_daily_bin1746.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) = 8307.73882683
delta logL = 0.285973527874

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 8307.7339595
delta logL = 0.290840851434

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .40940       1.0000          .0000       .10000E+07
     2 'Index     '    3.0451       1.0000          .0000       10.000    
     3 'Normalizat'    1.1440       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .71073       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6620E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   8307.734     FROM MIGRAD    STATUS=CONVERGED     53 CALLS      246 TOTAL
                     EDM=   .53E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .40936        5.5794        .88406E-03    .23336E-01
   2  Index         3.0452        2.5951        .10506        .22125E-03
   3  Normalizat    1.1440        .35583E-01    .55963E-01    .98936E-05
   4  Prefactor     .71075        .29042E-01    .42544E-01    .23609E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.409359
  Index      = 3.04515
  Normalizat = 1.144
  Prefactor  = 0.710754
 **********
 **   18 **HESSE 
 **********

 FCN=   8307.734     FROM HESSE     STATUS=OK            33 CALLS      279 TOTAL
                     EDM=   .15E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .40936        1.4099        .50909E-05   -1.5695    
   2  Index         3.0452        1.5904        .64552E-02   -.40168    
   3  Normalizat    1.1440        .19306        .24747E-03   -.88351    
   4  Prefactor     .71075        .15457        .24994E-03   -1.0311    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.51518e-10
Minuit parameter uncertainties:
  1  1.40993
  2  1.62386
  3  0.193184
  4  0.154662
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/732562': 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) = 8307.7339594
delta logL = 0.290840954744

Extracting fit parameters...

4FGL J1640.4+3945
   Spectrum: PowerLaw
308    Prefactor:  4.094e-01  1.410e+00  0.000e+00  1.000e+06 ( 1.000e-12)
309        Index:  3.045e+00  1.624e+00  0.000e+00  1.000e+01 (-1.000e+00)
310        Scale:  1.366e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
659    Prefactor:  7.108e-01  1.547e-01  0.000e+00  1.000e+01 ( 1.000e+00)
660        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
661        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
658   Normalization:  1.144e+00  1.932e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 1.40
Ra Dec: 250.119 39.763
Photon Index (Free Index): 3.05 +/- 1.62
Photon Flux (Free Index): 5.74e-08 +/- 5.39e-08
Energy Flux (Free Index): 1.12e-05 +/- 1.25e-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/732562/cmap_HighResolution_691891201_692150401_4FGL_J1640.4+3945_daily_bin1746.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='9.06e-03', comment='SUCCESS', energy_flux2='1.12e-05', dlogl='2.91e-01', photon_flux2='5.74e-08', job_status='DONE', time_completed='2022-12-08 01:30:31.502343', photon_index_error2='1.62', photon_index2='3.05', ts='0.74', fit_tolerance='1e-08', GAL='0.70', photon_index_error='0.00', photon_flux_upper_limit='1.17e-07', energy_flux_error2='1.25e-05', EG='1.17', time_epoch_completed='1670491831.5', return_code='0', job_id='732562', GAL2='0.71', EG2='1.14', return_code2='0', photon_flux_error2='5.39e-08', ts2='1.40', photon_index='2.42' WHERE bin_id='1746' AND source_name='4FGL J1640.4+3945' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Dec  8 01:30:31 PST 2022


------------------------------------------------------------
Sender: LSF System <lsf@bullet0152>
Subject: Job 732562: <4FGL_J1640.4+3945_daily_bin1746> in cluster <slac> Done

Job <4FGL_J1640.4+3945_daily_bin1746> was submitted from host <rhel6-64o> by user <kocevski> in cluster <slac> at Thu Dec  8 01:15:26 2022
Job was executed on host(s) <bullet0152>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Dec  8 01:15:27 2022
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Thu Dec  8 01:15:27 2022
Terminated at Thu Dec  8 01:30:32 2022
Results reported at Thu Dec  8 01:30:32 2022

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1640.4+3945_daily_bin1746 250.119 39.7626 691891201 692150401 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1640.4+3945 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   817.00 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             275.67 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   904 sec.
    Turnaround time :                            906 sec.

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

