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


Performing analysis on: 4FGL_J0638.6+7320_daily_bin1229
RA = 99.6711, Dec = 73.3438
tmin = 557884801, tmax = 558144001
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='591589', job_status='RUN', time_executed='2021-08-25 13:59:41.118456', time_epoch_executed='1629925181.12' WHERE source_name='4FGL J0638.6+7320' and cadence='daily' and bin_id='1229'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/591589

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/591589/ft1_4FGL_J0638.6+7320_daily_bin1229.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/591589/ft2_4FGL_J0638.6+7320_daily_bin1229.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/591589/ft1_4FGL_J0638.6+7320_daily_bin1229.fits outfile=/scratch/kocevski/591589/ft1_filteredMKT_4FGL_J0638.6+7320_daily_bin1229.fits ra=99.6711 dec=73.3438 rad=12.0 tmin=557884801.0 tmax=558144001.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.38
user 3.79
sys 0.53

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/591589/ft2_4FGL_J0638.6+7320_daily_bin1229.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/591589/ft2_4FGL_J0638.6+7320_daily_bin1229.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/591589/ft1_filteredMKT_4FGL_J0638.6+7320_daily_bin1229.fits evtable="EVENTS" outfile="/scratch/kocevski/591589/ft1_filtered_4FGL_J0638.6+7320_daily_bin1229.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 1.09
user 0.35
sys 0.50

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/591589/ft1_filtered_4FGL_J0638.6+7320_daily_bin1229.fits" evtable="EVENTS" scfile=/scratch/kocevski/591589/ft2_4FGL_J0638.6+7320_daily_bin1229.fits sctable="SC_DATA" outfile=/scratch/kocevski/591589/ltcube_557884801_558144001_4FGL_J0638.6+7320_daily_bin1229.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/591589/ft2_4FGL_J0638.6+7320_daily_bin1229.fits
.....................!
real 12.76
user 11.75
sys 0.68

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/591589/ft1_filtered_4FGL_J0638.6+7320_daily_bin1229.fits evtable="EVENTS" scfile=/scratch/kocevski/591589/ft2_4FGL_J0638.6+7320_daily_bin1229.fits sctable="SC_DATA" expcube=/scratch/kocevski/591589/ltcube_557884801_558144001_4FGL_J0638.6+7320_daily_bin1229.fits outfile=/scratch/kocevski/591589/expmap_557884801_558144001_4FGL_J0638.6+7320_daily_bin1229.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/591589/ltcube_557884801_558144001_4FGL_J0638.6+7320_daily_bin1229.fits
.....................!
real 191.98
user 185.50
sys 4.82

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

Setting source of interest to:
4FGL J0638.6+7320 @ 99.6711 73.3438

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/591589/ft1_filtered_4FGL_J0638.6+7320_daily_bin1229.fits scfile=/scratch/kocevski/591589/ft2_4FGL_J0638.6+7320_daily_bin1229.fits outfile=/scratch/kocevski/591589/cmap_557884801_558144001_4FGL_J0638.6+7320_daily_bin1229.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=99.6711 yref=73.3438 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.92
user 0.38
sys 0.47

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/591589/ft1_filtered_4FGL_J0638.6+7320_daily_bin1229.fits scfile=/scratch/kocevski/591589/ft2_4FGL_J0638.6+7320_daily_bin1229.fits outfile=/scratch/kocevski/591589/cmap_HighResolution_557884801_558144001_4FGL_J0638.6+7320_daily_bin1229.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=99.6711 yref=73.3438 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.96
user 0.38
sys 0.50

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/591589/ft1_filtered_4FGL_J0638.6+7320_daily_bin1229.fits evtable="EVENTS" scfile=/scratch/kocevski/591589/ft2_4FGL_J0638.6+7320_daily_bin1229.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/591589/Model_4FGL_J0638.6+7320_daily_bin1229.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/591589/ft1_filtered_4FGL_J0638.6+7320_daily_bin1229.fits...........................!
real 19.06
user 15.47
sys 1.72

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/591589/ft1_filtered_4FGL_J0638.6+7320_daily_bin1229.fits', '/scratch/kocevski/591589/ft2_4FGL_J0638.6+7320_daily_bin1229.fits', expMap='/scratch/kocevski/591589/expmap_557884801_558144001_4FGL_J0638.6+7320_daily_bin1229.fits', expCube='/scratch/kocevski/591589/ltcube_557884801_558144001_4FGL_J0638.6+7320_daily_bin1229.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/591589/Model_4FGL_J0638.6+7320_daily_bin1229.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J0638.6+7320'

4FGL J0638.6+7320
   Spectrum: PowerLaw
267    Prefactor:  9.247e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-12)
268        Index:  3.027e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
269        Scale:  3.246e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/591589/ft1_filtered_4FGL_J0638.6+7320_daily_bin1229.fits
Spacecraft file(s): /scratch/kocevski/591589/ft2_4FGL_J0638.6+7320_daily_bin1229.fits
Exposure map: /scratch/kocevski/591589/expmap_557884801_558144001_4FGL_J0638.6+7320_daily_bin1229.fits
Exposure cube: /scratch/kocevski/591589/ltcube_557884801_558144001_4FGL_J0638.6+7320_daily_bin1229.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/591589/Model_4FGL_J0638.6+7320_daily_bin1229.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) = 266.981981455

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10216E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    134.06       1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10152E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10130E-03   1.0000         .10000E-03   10000.    
     5 'norm      '    .11590E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10318E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    429.53       1.0000         .10000E-03   10000.    
     8 'Prefactor '    .12086E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    195.97       1.0000         .10000E-03   10000.    
    10 'norm      '    .11949E-03   1.0000         .10000E-03   10000.    
    11 'norm      '    17.748       1.0000         .10000E-03   10000.    
    12 'Prefactor '    .48005E-03   1.0000         .10000E-03   10000.    
    13 'Prefactor '    .13250E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    .10132E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '   10000.0       1.0000         .10000E-03   10000.    
    16 'Prefactor '    .28832E-03   1.0000         .10000E-03   10000.    
    17 'Prefactor '    .10534E-03   1.0000         .10000E-03   10000.    
    18 'norm      '    .10022E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    1363.5       1.0000         .10000E-03   10000.    
    20 'Normalizat'    .10000E-01   1.0000         .10000E-01   10.000    
    21 'Prefactor '    1.0898       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6810E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   266.3904     FROM MIGRAD    STATUS=CONVERGED    408 CALLS     2799 TOTAL
                     EDM=   .12E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .0%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    42.957       -.19217E-04** at limit **
   2  Prefactor     134.04        94.771       -.88732E-05    .51576E-05
   3  Prefactor     .10000E-03    135.41       -.15276E-04** at limit **
   4  Prefactor     .10000E-03    73.051        .43574E-04** at limit **
   5  norm          .10000E-03    1320.3       -.11888E-02** at limit **
   6  Prefactor     .10000E-03    337.66       -.69221E-04** at limit **
   7  Prefactor     429.61        526.70        .40559E-04    .58842E-05
   8  Prefactor     .10000E-03    145.63        .13632E-04** at limit **
   9  Prefactor     195.95        228.06       -.13681E-04   -.17435E-05
  10  norm          .10000E-03    224.39        .95362E-04** at limit **
  11  norm          17.746        10.106       -.45798E-08   -.22905E-05
  12  Prefactor     .10000E-03    512.52       -.29616E-04** at limit **
  13  Prefactor     .10000E-03    259.07        .64092E-04** at limit **
  14  norm          .10000E-03    294.22        .11227E-04** at limit **
  15  Prefactor    10000.0        8222.0        .23023E-03** at limit **
  16  Prefactor     .10000E-03    657.50       -.47904E-04** at limit **
  17  Prefactor     .10000E-03    89.813       -.66051E-04** at limit **
  18  norm          .10000E-03    41.736        .15273E-04** at limit **
  19  Prefactor     1363.9        1317.8        .13401E-03    .65605E-05
  20  Normalizat    .10000E-01    .54513       -.51814E-05** at limit **
  21  Prefactor     1.0897        .37413       -.73874E-05    .75768E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 134.041
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 429.612
  Prefactor  = 0.0001
  Prefactor  = 195.947
  norm       = 0.0001
  norm       = 17.7458
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 10000
  Prefactor  = 0.000100001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 1363.94
  Normalizat = 0.01
  Prefactor  = 1.0897
 **********
 **   18 **HESSE 
 **********

 FCN=   266.3904     FROM HESSE     STATUS=OK           301 CALLS     3100 TOTAL
                     EDM=   .21E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    42.957        .10464E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     134.04        94.843        .17391E-03   -1.3387    
   3  Prefactor     .10000E-03    135.41        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    73.051        .13652E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  norm          .10000E-03    1319.8        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    337.81        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     429.61        530.05        .98643E-04   -1.1532    
   8  Prefactor     .10000E-03    145.65        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     195.95        228.02        .14429E-03   -1.2899    
  10  norm          .10000E-03    224.40        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  norm          17.746        10.107        .38032E-04   -1.4865    
  12  Prefactor     .10000E-03    512.52        .21177E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     .10000E-03    259.08        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          .10000E-03    294.21        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor    10000.0        8222.0        .21444E-02    1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     .10000E-03    657.59        .21406E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  Prefactor     .10000E-03    89.880        .15145E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  norm          .10000E-03    41.732        .10313E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     1363.9        1318.2        .58282E-04   -.81425    
  20  Normalizat    .10000E-01    .55596        .73935E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     1.0897        .37332        .17164E-03   -.89797    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.13021e-10
Minuit parameter uncertainties:
  1  6.35726e-07
  2  94.9507
  3  4.54193e-05
  4  1.2111e-05
  5  3.85178e-05
  6  0.000313486
  7  536.284
  8  0.000235028
  9  229.058
  10  1.62834e-05
  11  10.1079
  12  4.60368e-06
  13  3.85865e-05
  14  0.000141143
  15  0.000809472
  16  0.00128432
  17  0.000349859
  18  7.6602e-05
  19  1353.01
  20  1.29253e-05
  21  0.374221
Done.

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

Extracting fit parameters...

4FGL J0638.6+7320
   Spectrum: PowerLaw
267    Prefactor:  1.959e+02  2.291e+02  1.000e-04  1.000e+04 ( 1.000e-12)
268        Index:  3.027e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
269        Scale:  3.246e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
678    Prefactor:  1.090e+00  3.742e-01  0.000e+00  1.000e+01 ( 1.000e+00)
679        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
680        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
677   Normalization:  1.000e-02  1.293e-05  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 1.78
Ra Dec: 99.671 73.344
Photon Index (Fixed Index): 3.03 +/- 0.00
Photon Flux (Fixed Index): 3.42e-07 +/- 3.99e-07
Energy Flux (Fixed Index): 6.73e-05 +/- 7.87e-05

TS (Fixed Index): 1.78
Ra Dec: 99.671 73.344
Photon Flux Upper Limit: 1.61e-06 ph cm-2 s-1
Energy Flux Upper Limit: 1.29e-01 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/591589/likelihoodResults_557884801_558144001_4FGL_J0638.6+7320_daily_bin1229.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) = 266.316463437
delta logL = 0.0738971080066

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 266.31423772
delta logL = 0.0761228254584

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    126.64       1.0000         .10000E-03   10000.    
     2 'Index     '    3.7551       1.0000          .0000       10.000    
     3 'Normalizat'    .10000E-01   1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.0873       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6810E+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=   266.3142     FROM MIGRAD    STATUS=CONVERGED     71 CALLS      265 TOTAL
                     EDM=   .15E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     126.62        239.49        .17886E-03    .28540E-03
   2  Index         3.7553        2.0044        .39924E-03    .14526E-03
   3  Normalizat    .10000E-01    .54582        .73323E-02** at limit **
   4  Prefactor     1.0872        .33662        .17155E-03   -.14190E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 126.624
  Index      = 3.75533
  Normalizat = 0.01
  Prefactor  = 1.08725
 **********
 **   18 **HESSE 
 **********

 FCN=   266.3142     FROM HESSE     STATUS=OK            23 CALLS      288 TOTAL
                     EDM=   .15E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     126.62        238.71        .35772E-04   -1.3453    
   2  Index         3.7553        1.9982        .79848E-04   -.25158    
   3  Normalizat    .10000E-01    .54583        .14665E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     1.0872        .33661        .34310E-04   -.89875    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.52593e-09
Minuit parameter uncertainties:
  1  240.563
  2  2.05977
  3  3.5545e-07
  4  0.337272
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/591589': 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) = 266.314237685
delta logL = 0.0761228602152

Extracting fit parameters...

4FGL J0638.6+7320
   Spectrum: PowerLaw
267    Prefactor:  1.266e+02  2.406e+02  1.000e-04  1.000e+04 ( 1.000e-12)
268        Index:  3.755e+00  2.060e+00  0.000e+00  1.000e+01 (-1.000e+00)
269        Scale:  3.246e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
678    Prefactor:  1.087e+00  3.373e-01  0.000e+00  1.000e+01 ( 1.000e+00)
679        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
680        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
677   Normalization:  1.000e-02  3.555e-07  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 1.98
Ra Dec: 99.671 73.344
Photon Index (Free Index): 3.76 +/- 2.06
Photon Flux (Free Index): 3.84e-07 +/- 4.39e-07
Energy Flux (Free Index): 6.01e-05 +/- 7.02e-05

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/591589/cmap_HighResolution_557884801_558144001_4FGL_J0638.6+7320_daily_bin1229.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='1.29e-01', comment='SUCCESS', photon_flux='3.42e-07', energy_flux2='6.01e-05', photon_flux_error='3.99e-07', dlogl='7.61e-02', energy_flux='6.73e-05', photon_flux2='3.84e-07', job_status='DONE', time_completed='2021-08-25 14:05:46.221560', photon_index_error2='2.06', photon_index2='3.76', ts='1.78', fit_tolerance='1e-08', GAL='1.09', photon_index_error='0.00', photon_flux_upper_limit='1.61e-06', energy_flux_error2='7.02e-05', EG='0.01', time_epoch_completed='1629925546.22', return_code='0', job_id='591589', GAL2='1.09', EG2='0.01', return_code2='0', energy_flux_error='7.87e-05', photon_flux_error2='4.39e-07', ts2='1.98', photon_index='3.03' WHERE bin_id='1229' AND source_name='4FGL J0638.6+7320' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Wed Aug 25 14:05:46 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0040>
Subject: Job 591589: <4FGL_J0638.6+7320_daily_bin1229> in cluster <slac> Done

Job <4FGL_J0638.6+7320_daily_bin1229> was submitted from host <rhel6-64j> by user <kocevski> in cluster <slac> at Wed Aug 25 13:55:20 2021
Job was executed on host(s) <bullet0040>, in queue <medium>, as user <kocevski> in cluster <slac> at Wed Aug 25 13:55:22 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Wed Aug 25 13:55:22 2021
Terminated at Wed Aug 25 14:05:47 2021
Results reported at Wed Aug 25 14:05:47 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J0638.6+7320_daily_bin1229 99.6711 73.3438 557884801 558144001 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J0638.6+7320 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   365.00 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             226.83 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   624 sec.
    Turnaround time :                            627 sec.

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

